annotate run/mini/bug30.d @ 1628:c6ef09dfba4d

add mini test set from ldc project
author Moritz Warning <moritzwarning@web.de>
date Mon, 10 Jan 2011 19:47:18 +0100
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1628
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
1 module bug30;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
2
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
3 void main()
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
4 {
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
5 int[] a = new int[4];
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
6 {a[0] = 1;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
7 a[1] = 2;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
8 a[2] = 3;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
9 a[3] = 4;}
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
10 int[] b = new int[4];
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
11 {b[0] = 1;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
12 b[1] = 2;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
13 b[2] = 3;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
14 b[3] = 4;}
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
15 int[] c = new int[4];
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
16 {c[0] = 1;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
17 c[1] = 2;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
18 c[2] = 4;
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
19 c[3] = 3;}
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
20 {assert(a == b);}
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
21 {assert(a != c);}
c6ef09dfba4d add mini test set from ldc project
Moritz Warning <moritzwarning@web.de>
parents:
diff changeset
22 }