package test;
public class Untitled21 {
public Untitled21 () {
System.out.println("constructor");
}
protected void finalize() {
System.out.println("finalizing Untitled21"); // add breakpoint here!!
}
public static void main(String args[]) {
new Untitled21 ();
System.out.println("bye");
System.runFinalizersOnExit(true);
}
}
public class Untitled21 {
public Untitled21 () {
System.out.println("constructor");
}
protected void finalize() {
System.out.println("finalizing Untitled21"); // add breakpoint here!!
}
public static void main(String args[]) {
new Untitled21 ();
System.out.println("bye");
System.runFinalizersOnExit(true);
}
}
- relates to
-
JDK-4392010 Regression test com/sun/jdi/FinalizerTest.java Failing
- Closed
-
JDK-4031945 (refs) java.lang.Runtime.runFinalizersOnExit only has effect when exit code is 0
- Closed
-
JDK-4215023 Fix RunFinalizersOnExit and put it back in the language
- Closed