-
Bug
-
Resolution: Fixed
-
P3
-
None
-
b07
test cases:
class Box<T> {
static <U> Box<U> make(U val) {
interface Checker {
void check(U val); // compile-time error
}
return null;
}
}
class LocalEnum {
static <U> U getAndSet(U u) {
enum X {
A;
U u;
}
U old = X.A.u;
X.A.u = u;
return old;
}
}
class LocalRecord {
static <U> void test() {
record R() {
U get() {return null;}
}
}
}
reported in amber-dev by Tagir: https://mail.openjdk.java.net/pipermail/amber-dev/2020-June/006235.html
class Box<T> {
static <U> Box<U> make(U val) {
interface Checker {
void check(U val); // compile-time error
}
return null;
}
}
class LocalEnum {
static <U> U getAndSet(U u) {
enum X {
A;
U u;
}
U old = X.A.u;
X.A.u = u;
return old;
}
}
class LocalRecord {
static <U> void test() {
record R() {
U get() {return null;}
}
}
}
reported in amber-dev by Tagir: https://mail.openjdk.java.net/pipermail/amber-dev/2020-June/006235.html