[Dlang-internal] DIP1000 discussion and testing

Mathias Lang via Dlang-internal dlang-internal at puremagic.com
Sun Dec 18 03:09:04 PST 2016


On Sunday, 18 December 2016 at 10:04:57 UTC, Walter Bright wrote:
> On 12/17/2016 11:47 PM, Walter Bright wrote:
>> So the trouble here is dmd not recognizing that f.foo() is the 
>> same as foo(f).
>
> https://github.com/dlang/dmd/pull/6331

With the two last P.R. you submitted merged, the following 
compiles

```
void escape () @safe
{
     Foo f;
     bar(f);
}

void bar (scope ref Foo f) @safe
{
     int[10] i;
     f.v = i;
}

struct Foo
{
     int[] v;
}
```


More information about the Dlang-internal mailing list