Bug 8943 – Cannot get parent of an overload

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2012-11-02T09:08:00Z
Last change time
2012-11-07T19:43:44Z
Keywords
pull, wrong-code
Assigned to
nobody
Creator
samukha

Comments

Comment #0 by samukha — 2012-11-02T09:08:42Z
struct S { void foo(); } // Just to be able to alias __traits template AliasTuple(A...) { alias A AliasTuple; } alias AliasTuple!(__traits(getOverloads, S, "foo")) Overloads; alias AliasTuple!(__traits(parent, Overloads[0])) P; // fail static assert(is(P[0] == S)); Error: argument foo has no parent
Comment #1 by k.hara.pg — 2012-11-02T21:20:30Z
Comment #2 by github-bugzilla — 2012-11-07T19:41:06Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/9e45da96f9322ec087e1f25ba02f3626a81a2a7d fix Issue 8943 - Cannot get parent of an overload https://github.com/D-Programming-Language/dmd/commit/e99f0ce910fd44a5ac8b4301c31732dc0b9504e2 Merge pull request #1251 from 9rnsr/fix8943 Issue 8943 - Cannot get parent of an overload