Merge pull request #495 from nicolas-raoul/fix-for-issue2907-with-no-formatting-changes
[mono.git] / mcs / tests / test-539.cs
1 // Compiler options: -optimize
2 using System;
3
4 class Test
5 {
6         public static int Main ()
7         {
8                 //switching to a constant fixes the problem
9                 double thisIsCausingTheProblem = 5.0;
10
11                 double[,] m1 = new double[4, 4] {
12                         { 1.0, 0.0, 0.0, thisIsCausingTheProblem },
13                         { 0.0, 1.0, 0.0, thisIsCausingTheProblem },
14                         { 0.0, 0.0, 1.0, thisIsCausingTheProblem },
15                         { 0.0, 0.0, 0.0, 1.0 }
16                 };
17
18                 var r = m1[0, 3];
19                 if (r != 5)
20                         return 1;
21
22                 return 0;
23         }
24 }