[Issue 1323] Implement opIn_r for arrays
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Jul 9 13:28:58 PDT 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1323
------- Comment #7 from shro8822 at uidaho.edu 2007-07-09 15:28 -------
as to in returning null, that is what 'in' does with AA's; if the key is in the
AA return a pointer to the value, otherwise, return null.
In fact, the code I wrote works the same as 'in' for AA's
The usual way to use the return from 'in' where it might give null is this:
if(auto v = i in j)
{
use(*v);
}
else
{
// i not in j
}
--
More information about the Digitalmars-d-bugs
mailing list