String to boolean inconsistency
spir
denis.spir at gmail.com
Sun Dec 12 01:45:31 PST 2010
On Sun, 12 Dec 2010 04:00:36 +0100
"Simen kjaeraas" <simen.kjaras at gmail.com> wrote:
> So likely, idup on an empty string returns an array with null ptr and
> 0 length, while "" is 'allocated' in the data segment, and thus given a
> ptr value.
.dup & .idup should not change a string's truth value. For sure, _this_ is a bug.
I think explicite empty strings/arrays should not have null pointers, as opposed to uninitialised strings/arrays.
Denis
-- -- -- -- -- -- --
vit esse estrany ☣
spir.wikidot.com
More information about the Digitalmars-d
mailing list