mirror of
https://github.com/tiennm99/lombok.git
synced 2026-10-14 18:18:48 +00:00
[fixes #1997] try-with-resources where the thing you’re guarding is just a variable ref instead of a full decl (legal since JDK9) would break delombok
This commit is contained in:
3 files changed
+33
-5
No files matched your search
@@ -0,0 +1,10 @@
|
||||
//version 9:
|
||||
import java.io.PrintWriter;
|
||||
public class TryWithResourcesVarRef {
|
||||
{
|
||||
PrintWriter pw = new PrintWriter(System.out);
|
||||
try (pw) {
|
||||
pw.println();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user