[Issue 15191] DIP25: Taking address of ref return is not type checked soundly

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Wed Jun 29 22:48:41 PDT 2016


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

--- Comment #2 from Walter Bright <bugzilla at digitalmars.com> ---
The trouble here is the following:


int[N]* bar(return ref int[N] s) @safe
{
    return &foo(s);  // <== taking the address of a reference should be an
error
}

--


More information about the Digitalmars-d-bugs mailing list