struct A { int i; } struct B { A a; alias a this; } B b; static assert(is(typeof({ with (b) i=0; })));
*** Issue 5887 has been marked as a duplicate of this issue. ***
(In reply to comment #1) > *** Issue 5887 has been marked as a duplicate of this issue. *** Marked older as dup since you have a simpler test-case.
*** Issue 7609 has been marked as a duplicate of this issue. ***
*** Issue 9807 has been marked as a duplicate of this issue. ***
https://github.com/D-Programming-Language/dmd/pull/2380
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/771b1ac53e94016e23483f99ce172cb464cf6594 fix issue 6711 - "with" doesn't work with "alias this" https://github.com/D-Programming-Language/dmd/commit/dfc7624ccb106b775bbd8df3120bc128ad46fd79 Merge pull request #2380 from hpohl/6711 fix issue 6711 - "with" doesn't work with "alias this"
The test-case in Issue 9807 still doesn't work, so I've reopened this.
https://github.com/D-Programming-Language/dmd/pull/2386
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/efba4e047b4d2a1da522d418a0491aebe0e68f36 additional fix for issue 6711 https://github.com/D-Programming-Language/dmd/commit/e96ff4d28950603b8a5bd3e8c35511bd3072e7fa Merge pull request #2386 from hpohl/6711 additional fix for issue 6711