Treating the abusive unsigned syndrome
bearophile
bearophileHUGS at lycos.com
Tue Nov 25 13:56:17 PST 2008
Andrei Alexandrescu:
> The problem is, it's much more annoying than one might imagine. Even
> array.length - 1 is up for scrutiny. Technically, even array.length + 1
> is a problem because 1 is really a signed int. We could provide
> exceptions for constants, but exceptions are generally not solving the
> core issue.
That can be solved making array.length signed.
Can you list few other annoying situations?
Bye,
bearophile
More information about the Digitalmars-d
mailing list