Mercurial > projects > dstress
annotate run/super_01.d @ 1597:8b9d4d2f925a
Fix typos in complex tests. See D bug 614.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Tue, 09 Sep 2008 16:53:58 +0200 |
parents | f87ba6507260 |
children |
rev | line source |
---|---|
374 | 1 // $HeadURL$ |
2 // $Date$ | |
3 // $Author$ | |
4 | |
5 module dstress.run.super_01; | |
0 | 6 |
7 int status; | |
8 | |
9 class Parent{ | |
10 void test(){ | |
11 status++; | |
12 } | |
13 } | |
14 | |
15 class Child : Parent { | |
16 void test(){ | |
17 assert(status==0); | |
18 super.test(); | |
19 assert(status==1); | |
20 } | |
21 } | |
22 | |
23 int main(){ | |
24 Child c = new Child(); | |
25 c.test(); | |
26 assert(status==1); | |
27 return 0; | |
28 } | |
29 |