[Issue 19754] cast() sometimes yields lvalue, sometimes yields rvalue

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Jun 30 22:30:07 UTC 2019


https://issues.dlang.org/show_bug.cgi?id=19754

--- Comment #15 from kinke <kinke at gmx.net> ---
More to the point:

void main()
{
    const x = 0;
    assert(&x == &(cast() x)); // fails; lowered to `assert(& x is &0)`
}

--


More information about the Digitalmars-d-bugs mailing list