类的初始化深层剖析案例
引自:http://topic.csdn.net/u/20120531/17/286c78d8-77f6-4498-88ab-3c35d88a1f5e.html?96609
public class Test02 { private int i = getValue();//第2行 private int j = 10; public int getValue(){ return j; } public static void main(String[] args) { System.out.print(new Test02().i);//第9行 }}/*输出:A 第二行编译错误B 第九行编译错误C 输出:10D 输出:0*/