digitalmars.D.bugs - [Issue 17223] New: Inconsistency between opDispatch
- via Digitalmars-d-bugs (29/29) Feb 24 2017 https://issues.dlang.org/show_bug.cgi?id=17223
https://issues.dlang.org/show_bug.cgi?id=17223 Issue ID: 17223 Summary: Inconsistency between opDispatch explicit/implicit usage Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: major Priority: P1 Component: dmd Assignee: nobody puremagic.com Reporter: john.loughran.colvin gmail.com alias AliasSeq(TL ...) = TL; int n; struct S { alias A = AliasSeq!(n, int); template opDispatch(string name) { alias this_ = this; alias opDispatch = AliasSeq!(__traits(getMember, this_, "A")); } } alias b = S.opDispatch!"B"; // OK alias a = S.B; // Error: alias test.a cannot alias an expression tuple(n, (int)) --
Feb 24 2017