blob: 78fe9a0a8e88a6c3353249d648907d93d0d04d68 [file] [log] [blame]
Søren Gjessef1e2fc92017-08-29 14:13:12 +02001// Copyright (c) 2017, the R8 project authors. Please see the AUTHORS file
2// for details. All rights reserved. Use of this source code is governed by a
3// BSD-style license that can be found in the LICENSE file.
4
5public class ClassInitializerStaticBlockInitialization {
6
7 static boolean b;
8 static int x;
9 static int y;
10
11 static {
12 x = 1;
13 x = 2;
14 if (b) {
15 y = 1;
16 } else {
17 y = 2;
18 }
19 x = 3;
20 }
21
22 public static void main(String[] args) {
23 System.out.println("x=" + x);
24 System.out.println("y=" + y);
25 }
26}