From 7012578234389728119
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,bf65828a2bbbc32e
X-Google-Attributes: gidf78e5,public
X-Google-ArrivalTime: 1993-12-13 04:37:06 PST
Path: gmd.de!newsserver.jvnc.net!howland.reston.ans.net!cs.utexas.edu!uunet!pipex!sunic!news.lth.se!dag
From: dag@control.lth.se (Dag Bruck)
Newsgroups: comp.std.c++
Subject: Re: bool run-time performance impact
Date: 13 Dec 1993 07:22:51 GMT
Organization: Department of Automatic Control, Lund, Sweden
Lines: 9
Message-ID: <2eh58b$fg6@nic.lth.se>
References: <trickr.11.000B9FAA@uh2372p03.daytonoh.ncr.com> <9334701.20716@mulga.cs.mu.OZ.AU>
NNTP-Posting-Host: control.lth.se
Keywords: bool

In <comp.std.c++> fjh@munta.cs.mu.OZ.AU (Fergus Henderson) writes:
>It would be quite reasonable for compilers to use a non-canonical
>representation where anything non-zero is true.  In this case,
>conversion from int to bool would be a no-op.

Not quite; the proposal explicitly says that a bool, when promoted to
int, yields the values 0 or 1.

					-- Dag


