You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.
Another related but different problem: if the destination is already generic, the correct type variable is not used.
Before quickfix:
public class Bug {
private static class Class1<T> {
T t;
Class2<T> c2;
void method() {
c2.useT(t); // Quickfix "Create method 'useT(T)' in Class2"
}
}
private static class Class2<U> {
}
}
After quickfix:
public class Bug {
private static class Class1<T> {
T t;
Class2<T> c2;
void method() {
c2.useT(t);
}
}
private static class Class2<U> {
public void useT(T t) { // Should be (U t), not (T t)
}
}
}
The text was updated successfully, but these errors were encountered:
- refine type parameter logic to handle substitution of class
type parameters when appropriate
- also handle adding type parameters when needed that may come from
either the enclosing method or from a type
- add new tests to UnresolvedMethodsQuickFixTest1d8
- fixeseclipse-jdt#330
- refine type parameter logic to handle substitution of class
type parameters when appropriate
- also handle adding type parameters when needed that may come from
either the enclosing method or from a type
- add new tests to UnresolvedMethodsQuickFixTest1d8
- fixes#330
From: https://bugs.eclipse.org/bugs/show_bug.cgi?id=539067
Another related but different problem: if the destination is already generic, the correct type variable is not used.
Before quickfix:
After quickfix:
The text was updated successfully, but these errors were encountered: