Integer conversions too pedantic in 64-bit
bearophile
bearophileHUGS at lycos.com
Thu Feb 17 10:08:08 PST 2011
Steven Schveighoffer:
> Yes, David has proposed a corrected version on the Phobos mailing list:
>
> http://lists.puremagic.com/pipermail/phobos/2011-February/004493.html
I suggest it to return a signed value, like an int. But a signed long is OK too.
I suggest a name as "len" (or "slen") because I often write "length" wrongly.
Does it support code like:
auto l = arr.len;
arr.len = 10;
arr.len++;
A big problem: it's limited to arrays, so aa.len or rbtree.len, set.len, etc, don't work. So I'd like something more standard... So I am not sure this is a good idea.
Bye,
bearophile
More information about the Digitalmars-d
mailing list