comparison test/staticvars.d @ 26:99737f94abfb trunk

[svn r30] * Fixed static function-local variables. * Fixed CondExp - bool ? true : false
author lindquist
date Thu, 04 Oct 2007 10:57:26 +0200
parents
children
comparison
equal deleted inserted replaced
25:12fd8ce55d9c 26:99737f94abfb
1 module staticvars;
2
3 int func()
4 {
5 static int i;
6 return i++;
7 }
8
9 void main()
10 {
11 assert(func() == 0);
12 assert(func() == 1);
13 }