record Record<Short>(Short s) {}
public class X {
public static <Short> short foo(Record<Short> s) {
return switch (s) {
case Record(short s1) -> s1; // error here
default -> 0;
};
}
public static void main(String[] args) {}
}
Javac accepts this, but ecj rejects with Record component with type Short is not compatible with type short
Here's the test case:
Javac accepts this, but ecj rejects with
Record component with type Short is not compatible with type short