Mercurial > projects > dstress
comparison run/opPos_02.d @ 0:3269e4627918
init dstress
author | svnowner |
---|---|
date | Sat, 25 Sep 2004 22:33:30 +0000 |
parents | |
children | 3414705c41ac |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:3269e4627918 |
---|---|
1 // $Header: /home/th/Dokumente/Entwicklung/MEIN_CVS/MiniD/src/run/opPos_02.d,v 1.1 2004/09/21 21:04:48 th Exp $ | |
2 | |
3 struct MyStruct{ | |
4 int status; | |
5 void opPos(){ | |
6 status+=3; | |
7 } | |
8 } | |
9 | |
10 int main(){ | |
11 MyStruct s; | |
12 assert(s.status==0); | |
13 +s; | |
14 assert(s.status==3); | |
15 +s; | |
16 assert(s.status==6); | |
17 return 0; | |
18 } |