Merge from mainline (gomp-merge-2005-02-26).
[official-gcc.git] / libjava / testsuite / libjava.lang / StaticConstructor.java
blob54c0f5376df3051c4b078aae5d516a10111f4b99
1 // Test to make sure static initializers are called
3 class bar
5 public static int zog;
6 public static int zag;
8 static
10 zog = 12;
11 zag = 2;
14 public bar() { }
17 public class StaticConstructor
19 static int foo ()
21 return new bar().zog;
24 public static void main(String args[])
26 System.out.println ("" + (foo() + bar.zag));