Files
lombok/test/pretty/resource/before/PatternInstanceOf.java
T
Reinier Zwitserloot 229cde2bf0 [Fixes #2349] Support for JDK 14
Added the ability to parse and pretty-print the new 'x instanceof String y' pattern concept.
Added a test to the pretty printer to confirm that it works.
2020-01-29 03:07:21 +01:00

9 lines
143 B
Java

// version 14:
public class PatternInstanceOf {
public void foo(Object o) {
if (o instanceof String y) {
System.out.println(y);
}
}
}