[jit] Fix the saving of the 'cfg->ret_var_set' flag when inlining, it was set to...
[mono.git] / mcs / tests / test-480.cs
1 using System;
2
3 class A : IDisposable
4 {
5         public A (int v)
6         {
7         }
8         
9         public void Dispose ()
10         {
11         }
12 }
13
14 class C
15 {
16         int b;
17         
18         delegate void D (int i);
19         
20         static void Test (object arg)
21         {
22                 const int a2= 9, a3 = a2, a4 = a3, a5 = a4;
23                 Console.WriteLine (a5);
24                 
25                 if (a2 > 0) {
26                         bool a = false;
27                 } else {
28                         const bool a = false;
29                 }
30
31                 for (int i = 0; i < 10; ++i) {
32                         Console.WriteLine (i);
33                 }
34                 
35                 for (int i = 0; i < 10; ++i) {
36                         Console.WriteLine (i);
37                 }
38                 
39                 foreach (var i in new int[] { 9, 8 }) {
40                         Console.WriteLine (i);
41                 }
42
43                 using (A i = new A (1), i2 = new A (2), i3 = new A (3)) {
44                 }
45                 
46                 using (A i = new A (3)) {
47                 }
48
49                 try {
50                 }
51                 catch (Exception o) {
52                         o = null;
53                 }
54
55                 D action = delegate (int i) {
56                 };
57         }
58
59         public static int Main ()
60         {
61                 Test (1);
62                 return 0;
63         }
64 }