Community
Participate
Working Groups
I200409281200 public class A { A(Integer i) { } A takeInt(Integer i) { return new A(i); } void foo(){ A a1= new A(varConstructor); // no binding A a2= takeInt(varMethod); // has binding } } The ClassInstanceCreation 'new A(varConstructor)' has no binding, but the method invocation takeInt(..) has one. Would be nice if a constructor with invalid arguments could still guess a binding in this situation. The missing binding makes quick fixes 'Create local variable / field / parameter / constant' fail to infer the correct type for the variable varConstructor.
Deferring post 3.1
Reopen to close as WORKSFORME since this is working in 3.4.
Closing as WORKSFORME.