Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mono / tests / static-ctor.cs
1 using System;
2
3 class X {
4         static X ()
5         {
6                 test.global = 1;
7         }
8 }
9
10 class Y : X {
11 }
12
13 class Z : Y {
14         public Z ()
15         {
16         }
17 }
18
19 class test {
20         static public int global;
21         
22         static int Main ()
23         {
24                 Z z = new Z ();
25                 
26                 if (global != 1){
27                         Console.WriteLine ("Error");
28                         return 1;
29                 }
30                 Console.WriteLine ("Ok");
31                 return 0;
32         }
33 }