Article View: comp.sys.sgi.apps
Article #85Re: SGI's C++ compiler and the boolean type
From: Chung-chieh Shan
Date: Wed, 10 Apr 1996 23:04
Date: Wed, 10 Apr 1996 23:04
14 lines
1073 bytes
1073 bytes
> And some argue that true should be -1, because then bitwise not works: > ~(true = -1) == (false = 0) > ~(false = 0) == (true = -1) According to the proposed standard, true is implicitly casted from bool to the integer 1. Nonzero integers are implicitly casted from int to the bool true. Funny nobody has written an implementation of bool. (AFAIK) -- blue | Chung-chieh Shan (Ken) | Life is a sexually transmitted () | ccshan@fas.harvard.edu | math too is a terminal representation /\ | Finger for PGP key | game. disease. of Quality.
Technical Details
Message-ID:
<4khepk$8k1@decaxp.HARVARD.EDU>Path:
arc1-ca.pugleaf.net!fas-news.harvard.edu!scws44!ccshanReferences:
<4kefm7$oao@ncar.ucar.edu> <4kg6fv$h7k@nic.ftns.no>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!fas-news.harvard.edu!scws44!ccshan From: ccshan@scws44.harvard.edu (Chung-chieh Shan) Newsgroups: comp.sys.sgi.apps,comp.lang.c++ Subject: Re: SGI's C++ compiler and the boolean type Followup-To: comp.sys.sgi.apps,comp.lang.c++ Date: 10 Apr 1996 23:04:20 GMT Organization: Harvard University Message-ID: <4khepk$8k1@decaxp.HARVARD.EDU> References: <4kefm7$oao@ncar.ucar.edu> <4kg6fv$h7k@nic.ftns.no> NNTP-Posting-Host: scws44.harvard.edu X-Newsreader: TIN [version 1.2 PL2]