From a8f9b1dd359dbbcd63bffe891c5f00a9a2ac1f60 Mon Sep 17 00:00:00 2001 From: Rawi01 Date: Wed, 12 May 2021 09:03:57 +0200 Subject: [fixes #2420] Copy vartype.type --- .../resource/before/ValAnonymousSubclassSelfReference.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 test/transform/resource/before/ValAnonymousSubclassSelfReference.java (limited to 'test/transform/resource/before') diff --git a/test/transform/resource/before/ValAnonymousSubclassSelfReference.java b/test/transform/resource/before/ValAnonymousSubclassSelfReference.java new file mode 100644 index 00000000..6ca05b3c --- /dev/null +++ b/test/transform/resource/before/ValAnonymousSubclassSelfReference.java @@ -0,0 +1,12 @@ +// issue 2420: to trigger the problem 2 var/val, one normal variable and a anonymous self reference is required +import lombok.val; + +public class ValAnonymousSubclassSelfReference { + public void test() { + int i = 0; + val j = 1; + val k = 2; + + new ValAnonymousSubclassSelfReference() { }; + } +} \ No newline at end of file -- cgit