changeset 52679 | c6df6671267e |
parent 52455 | bbbc110cdffe |
child 52697 | 605878cd4009 |
--- a/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java Mon Nov 26 08:27:49 2018 +0800 +++ b/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java Mon Nov 26 09:24:08 2018 +0100 @@ -1778,9 +1778,6 @@ if (condTypes.isEmpty()) { return syms.objectType; //TODO: how to handle? } - if (condTypes.size() == 1) { - return condTypes.head; - } Type first = condTypes.head; // If same type, that is the result if (condTypes.tail.stream().allMatch(t -> types.isSameType(first, t)))