Mercurial > projects > dstress
annotate nocompile/offsetof_08.d @ 172:e5bbb877feb9
extended offsetof / offset tests
author | thomask |
---|---|
date | Wed, 01 Dec 2004 13:53:23 +0000 |
parents | |
children | f87ba6507260 |
rev | line source |
---|---|
172 | 1 // $HeadURL$ |
2 // $Date$ | |
3 // $Author$ | |
4 | |
5 module dstress.nocompile.offsetof_08; | |
6 | |
7 class MyClass{ | |
8 int a; | |
9 int b; | |
10 } | |
11 | |
12 int main(){ | |
13 MyClass c = new MyClass(); | |
14 | |
15 assert(MyClass.a.offsetof == c.a.offsetof); | |
16 assert(MyClass.b.offsetof == c.a.offsetof); | |
17 | |
18 return 0; | |
19 } |