https://issues.dlang.org/show_bug.cgi?id=21804
--- Comment #1 from Vladimir Panteleev <[email protected]> --- Found a really weird workaround: fun ((result) { }); // OK fun ((result) { result.m(); }); // OK ????? Looks like we can trick the compiler into doing the right thing by first making a dummy instantiation which does not access `result`. --
