Shouldn't the following code produce a warning?
Jonathan M Davis via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sun Apr 3 23:55:59 PDT 2016
On Monday, April 04, 2016 13:23:16 ric maicle via Digitalmars-d-learn wrote:
> The values of the variables here can be determined during compilation.
> Should there be some kind of warning like, unsigned integer may not be
> compared to a value less than zero; or there shouldn't be since the
> programmer should have known what he's doing?
Agruably, it should generate a warning, but it doesn't currently. There are
these two related bug reports / enhancement requests though:
https://issues.dlang.org/show_bug.cgi?id=6949
https://issues.dlang.org/show_bug.cgi?id=259
- Jonathan M Davis
More information about the Digitalmars-d-learn
mailing list