RFR: 8200145: Conditional expression mistakenly treated as standalone [v2]
Guoxiong Li
github.com+13688759+lgxbslgx at openjdk.java.net
Sat Apr 17 07:27:57 UTC 2021
On Fri, 16 Apr 2021 15:54:05 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
>> Guoxiong Li has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Use method isErroneous
>
> src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Attr.java line 1959:
>
>> 1957: //where
>> 1958: boolean primitiveOrBoxed(Type t) {
>> 1959: return (!t.hasTag(TYPEVAR) && !t.hasTag(ERROR) && types.unboxedTypeOrType(t).isPrimitive());
>
> Good catch - you can also use `!t.isErroneous()` here.
Fixed.
-------------
PR: https://git.openjdk.java.net/jdk/pull/2324
More information about the compiler-dev
mailing list