Ver Fonte

Force test-34 to fail and exhibit the bug

svn path=/trunk/mcs/; revision=1355
Miguel de Icaza há 24 anos atrás
pai
commit
b623f18d20
3 ficheiros alterados com 22 adições e 3 exclusões
  1. 1 1
      mcs/tests/makefile
  2. 1 1
      mcs/tests/test-34.cs
  3. 20 1
      mcs/tests/test-42.cs

+ 1 - 1
mcs/tests/makefile

@@ -6,7 +6,7 @@ VERIFY=../tools/verifier.exe
 
 TEST_SOURCES = \
 	test-1  test-2  test-3  test-4  test-5  test-6  test-7  test-8  test-9  test-10 \
-	test-11 test-12 test-13 test-14 test-15 test-16 test-17 test-18 	test-20  \
+	test-11 test-12 test-13 test-14 test-15 test-16 test-17 test-18 test-19 test-20  \
 	test-21 	test-23 test-24 test-25 test-26 test-27 test-28 		 \
 	test-31 test-32 		test-35 test-37 test-39 test-40 test-42
 

+ 1 - 1
mcs/tests/test-34.cs

@@ -22,7 +22,7 @@ public class Blah {
 		Foo (i, j);
 		Foo (ref i, ref j);
 
-		Bar (i, j);
+		Bar (i, j, 5, 4, 3, 3, 2);
 
 		return  0;
 	}

+ 20 - 1
mcs/tests/test-42.cs

@@ -110,7 +110,7 @@ class Y {
 	static int arrays ()
 	{
 		int [] a = new int [10];
-		int i;
+		int i, j;
 		
 		for (i = 0; i < 10; i++)
 			a [i]++;
@@ -118,6 +118,25 @@ class Y {
 		for (i = 0; i < 10; i++)
 			if (a [i] != 1)
 				return 100;
+
+		int [,] b = new int [10,10];
+		for (i = 0; i < 10; i++){
+			for (j = 0; j < 10; j++){
+				b [i,j] = i * 10 + j;
+				if (i < 5)
+					b [i,j]++;
+				else
+					++b [i,j];
+			}
+		}
+
+		for (i = 0; i < 10; i++){
+			for (j = 0; j < 10; j++){
+				if (b [i,j] != i * 10 + (j + 1))
+					return 101;
+			}
+		}
+		
 		return 0;
 	}