Community
Participate
Working Groups
N20090215-2000. public class A { public A(String s) { B.test(); } private static class B extends A { public B() { super(""); } private static void test() { }; } } ==> reports that B's constructor is unused. While this might be technically true it is required in order to correctly compile.
Caused by fix for bug 201912.
Maybe all constructors with explicit super constructor call being non trivial (the default super constructor) should be marked as used to avoid being complained against.
We are incorrectly flagging some constructors as being unused. We need to recognize the cases where the super class has no no-arg constructor and not complain about "seemingly useless" constructors in these cases. Looking at delivering an interim fix for the next integration build, and the full and final fix subsequent to that.
Created attachment 125879 [details] Interim patch Suppress unused constructor warning on inner class constructors for the time being. Restored original behavior from ConstructorDeclaration.java version 1.100 Other warnings introduced by fix for bug#201912 are still in effect.
(In reply to comment #4) > Created an attachment (id=125879) [details] > Interim patch > Released for 3.5M6 in HEAD stream.
Verified for 3.5M6 using I20090309-0100