Mercurial > projects > ldc
annotate test/interface7.d @ 128:e5fe8521bbfa trunk
[svn r132] Added some tests. some will fail at the moment.
author | lindquist |
---|---|
date | Fri, 30 Nov 2007 17:12:08 +0100 |
parents | 5880c12dba83 |
children | 44a95ac7368a |
rev | line source |
---|---|
114 | 1 module interface7; |
2 | |
3 interface I | |
4 { | |
5 } | |
6 | |
7 class C : I | |
8 { | |
9 } | |
10 | |
11 void main() | |
12 { | |
13 I i = new C; | |
14 ClassInfo ci = i.classinfo; | |
15 char[] name = ci.name; | |
16 printf("ci.name = %.*s\n", name.length, name.ptr); | |
17 ClassInfo cI = I.classinfo; | |
18 name = cI.name; | |
19 printf("cI.name = %.*s\n", name.length, name.ptr); | |
20 assert(ci is cI); | |
21 } |