DMD 0.148 release

Oskar Linde oskar.lindeREM at OVEgmail.com
Tue Feb 28 00:03:32 PST 2006


Tom skrev:
> In article <du002m$2pnp$1 at digitaldaemon.com>, Ivan Senji says...
>> Walter Bright wrote:
>>> "Ivan Senji" <ivan.senji_REMOVE_ at _THIS__gmail.com> wrote in message 
>>>> Walter Bright wrote:
> 
>> The problem in all these bool wars so far is I never saw an argument 
>> that would be against true booleans (while(BooleanExpression) and all 
>> that...).
> 
> Yes, PLEASE, WHY?? Just ONE argument against pure bools, only one and I shut my
> mouth forever!
> 
> Tom;

Does pure booleans necessarily mean that other types could not be 
implicitly convertible to bool? I would love "pure" booleans (not a 
numeric type, not allowed in arithmetic operations), but I would hate to 
have to write:

if (a !is null || b !is null)

instead of:

if (a || b)

What is wrong with the second case? (apart from being more readable).

With such "pure" booleans, you could still write:

while(1)

With the classic definition of !0 !null implies true...

/Oskar



More information about the Digitalmars-d-announce mailing list