Consider a record like:
---
public record R(String s1, String s2) implements I {}
interface I {}
---
When this is attributed when j.l.Record does not exist, an error about the missing Record class is reported (correct), but the first `String` will be attributed as erroneous, which is not correct. The erroneous part is the supertype, not the component type.
---
public record R(String s1, String s2) implements I {}
interface I {}
---
When this is attributed when j.l.Record does not exist, an error about the missing Record class is reported (correct), but the first `String` will be attributed as erroneous, which is not correct. The erroneous part is the supertype, not the component type.
- relates to
-
JDK-8273584 TypeElement.getSuperclass crashes for a record TypeElement when j.l.Record is not available
-
- Resolved
-