Bug 5622 – [qtd] Static members imported with "alias this" are inaccessible

Status
RESOLVED
Resolution
WORKSFORME
Severity
normal
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2011-02-20T08:49:00Z
Last change time
2013-01-13T10:06:31Z
Assigned to
nobody
Creator
samukha

Comments

Comment #0 by samukha — 2011-02-20T08:49:26Z
class A { enum E { value } alias E.value value; static void foo() { } } class B { A a; alias a this; } void main() { enum v = B.E.value; enum v2 = B.value; B.foo(); } Error: 'this' is only defined in non-static member functions, not main
Comment #1 by andrej.mitrovich — 2012-12-18T09:02:25Z
This is fixed in 2.061 git-head. Can anyone tell which pull fixed it?