Is it true that the assigned final object field may still be null inside a constructor?
class MyClass {
private final Object obj = new Object();
public MyClass() {
System.out.println(obj); // may print null?
}
}
if yes, isn’t this a bug?
As discussed by other answers, no, that can not happen. With an assigned final static field, however, it can.