diff options
Diffstat (limited to 'test/transform/resource/after-ecj/DelegateOnGetter.java')
-rw-r--r-- | test/transform/resource/after-ecj/DelegateOnGetter.java | 45 |
1 files changed, 44 insertions, 1 deletions
diff --git a/test/transform/resource/after-ecj/DelegateOnGetter.java b/test/transform/resource/after-ecj/DelegateOnGetter.java index cb06d3c1..4b10bf7f 100644 --- a/test/transform/resource/after-ecj/DelegateOnGetter.java +++ b/test/transform/resource/after-ecj/DelegateOnGetter.java @@ -1 +1,44 @@ -//ignore
\ No newline at end of file +import lombok.Delegate; +import lombok.Getter; +class DelegateOnGetter { + private interface Bar { + void setList(java.util.ArrayList<java.lang.String> list); + int getInt(); + } + private final @Delegate @Getter(lazy = true) java.util.concurrent.atomic.AtomicReference<java.util.concurrent.atomic.AtomicReference<Bar>> bar = new java.util.concurrent.atomic.AtomicReference<java.util.concurrent.atomic.AtomicReference<Bar>>(); + public @Delegate @java.lang.SuppressWarnings("all") Bar getBar() { + java.util.concurrent.atomic.AtomicReference<Bar> value = this.bar.get(); + if ((value == null)) + { + synchronized (this.bar) + { + value = this.bar.get(); + if ((value == null)) + { + final Bar actualValue = new Bar() { + x() { + super(); + } + public void setList(java.util.ArrayList<String> list) { + } + public int getInt() { + return 42; + } + }; + value = new java.util.concurrent.atomic.AtomicReference<Bar>(actualValue); + this.bar.set(value); + } + } + } + return value.get(); + } + public @java.lang.SuppressWarnings("all") int getInt() { + return this.getBar().getInt(); + } + public @java.lang.SuppressWarnings("all") void setList(final java.util.ArrayList<java.lang.String> list) { + this.getBar().setList(list); + } + DelegateOnGetter() { + super(); + } +}
\ No newline at end of file |