[Dlang-internal] -dip1000 discussion
Walter Bright via Dlang-internal
dlang-internal at puremagic.com
Sun Jan 29 03:45:30 PST 2017
On 1/29/2017 3:24 AM, Olivier FAURE wrote:
> Whoops. That is a typo. I meant
It's best to post compilable code fragments. This code compiles with -dip1000:
struct Container
{
int* ptr;
}
ref Container store(ref return scope Container c, return scope int* ptr)
{
c.ptr = ptr;
return c;
}
void foobar()
{
Container c;
scope int* ptr;
scope Container c2 = store(c, ptr);
}
More information about the Dlang-internal
mailing list