dereferencing null

Timon Gehr timon.gehr at gmx.ch
Fri Mar 9 06:54:21 PST 2012


On 03/09/2012 01:43 AM, bearophile wrote:
> Adam D. Ruppe:
>
>> D rox the web (and has for a while).
>
> (Oh, you are starting to copy Andrei talk style now :-) The birth of community words, idioms and sub-languages is a very common thing, sociology studies such things a lot).
>
> But there's always some space for improvements :-)
>
> In D.learn there is a thread titled "0<  negative loop condition bug or misunderstanding on my part":
>
> http://forum.dlang.org/thread/tbsvfbotcupussmeticq@forum.dlang.org
>
> Web coders are not going to appreciate such traps. I think integral bound tests at run-time are able to catch part of those problems.
>
> Bye,
> bearophile

Comparing signed/unsigned is perfectly reasonable. This is what causes 
the problem discussed in D.learn:

assert(-1<0U); // fail.


More information about the Digitalmars-d mailing list