1 /* 2 TEST_OUTPUT: 3 --- 4 fail_compilation/fail61.d(22): Error: no property 'B' for type 'fail61.A.B' 5 fail_compilation/fail61.d(23): Error: no property 'B' for type 'fail61.A.B' 6 fail_compilation/fail61.d(32): Error: no property 'A2' for type 'fail61.B2' 7 fail_compilation/fail61.d(41): Error: this for foo needs to be type B3 not type fail61.C3 8 --- 9 */ 10 11 class A 12 { 13 class B : A 14 { 15 static const int C = 5; 16 } 17 } 18 main()19void main() 20 { 21 int n1 = A.B.C; 22 int n2 = A.B.B.C; // Line22 23 int n3 = A.B.B.B.C; // Line23 24 } 25 foo()26class A2 { void foo(){ assert(0);} } foo()27class B2 : A2 { override void foo(){} } 28 class C2 : B2 29 { bar()30 void bar() 31 { 32 B2.A2.foo(); // Line32 33 } 34 } 35 foo()36class B3 { void foo(){ assert(0); } } 37 class C3 38 { bar()39 void bar() 40 { 41 B3.foo(); // Line41 42 } 43 } 44