Why does using raw type variables affect signatures without reference to type-parameters? [duplicate]
This question already has an answer here: Why does javac complain about generics unrelated to the class' type arguments? [duplicate] 1 answer Looking into another question I bumped into this intriguing behavior of the 1.8.0_112 Sun-Oracle compiler (I have not tested with others): import java.util.List; interface Alpha<T> { List<Integer> intList(); } interface Beta { List<Integer> intList(); } class Main { public static void main(String[] args) { Alpha rawAlpha = null; Alpha<Character> charAlpha = null; Alpha<?> qmAlpha = null; Beta beta = null; for (Integer i : charAlpha.intList()) {} for