aboutsummaryrefslogtreecommitdiff
path: root/test/transform/resource/after-delombok/AccessorsInAnonymousClass.java
diff options
context:
space:
mode:
authorRawi01 <Rawi01@users.noreply.github.com>2021-05-29 18:49:05 +0200
committerRawi01 <Rawi01@users.noreply.github.com>2021-06-03 19:23:19 +0200
commit60f575496b3184c2279e9dba470097ed164d5adf (patch)
tree61493259ec561b5d01a7a6e5361b4a7b16b5b106 /test/transform/resource/after-delombok/AccessorsInAnonymousClass.java
parent6758714ed564d72236564889157c4812eacb96fb (diff)
downloadlombok-60f575496b3184c2279e9dba470097ed164d5adf.tar.gz
lombok-60f575496b3184c2279e9dba470097ed164d5adf.tar.bz2
lombok-60f575496b3184c2279e9dba470097ed164d5adf.zip
[fixes #2838] Handle anonymous classes properly
Generated qualified names (e.g. Outer.Inner) now stop at anonymous classes instead of adding an empty part. All handlers that add static fields/methods/types now add error messages instead of generating invalid code.
Diffstat (limited to 'test/transform/resource/after-delombok/AccessorsInAnonymousClass.java')
-rw-r--r--test/transform/resource/after-delombok/AccessorsInAnonymousClass.java22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/transform/resource/after-delombok/AccessorsInAnonymousClass.java b/test/transform/resource/after-delombok/AccessorsInAnonymousClass.java
new file mode 100644
index 00000000..27fab509
--- /dev/null
+++ b/test/transform/resource/after-delombok/AccessorsInAnonymousClass.java
@@ -0,0 +1,22 @@
+public class AccessorsInAnonymousClass {
+ Object annonymous = new Object() {
+
+ class Inner {
+ private String string;
+
+ @java.lang.SuppressWarnings("all")
+ public String string() {
+ return this.string;
+ }
+
+ /**
+ * @return {@code this}.
+ */
+ @java.lang.SuppressWarnings("all")
+ public Inner string(final String string) {
+ this.string = string;
+ return this;
+ }
+ }
+ };
+}