diff options
Diffstat (limited to 'test/transform/resource/before/ExtensionMethodSuppress.java')
-rw-r--r-- | test/transform/resource/before/ExtensionMethodSuppress.java | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/test/transform/resource/before/ExtensionMethodSuppress.java b/test/transform/resource/before/ExtensionMethodSuppress.java new file mode 100644 index 00000000..d30652d3 --- /dev/null +++ b/test/transform/resource/before/ExtensionMethodSuppress.java @@ -0,0 +1,43 @@ +import lombok.experimental.ExtensionMethod; + +@ExtensionMethod(Extensions.class) +class ExtensionMethodSuppress { + public void test() { + Test.staticMethod(); + + Test test = new Test(); + test.instanceMethod(); + test.staticMethod(); + } +} + +@ExtensionMethod(value = Extensions.class, suppressBaseMethods = false) +class ExtensionMethodKeep { + public void test() { + Test.staticMethod(); + + Test test = new Test(); + test.instanceMethod(); + test.staticMethod(); + } +} + +class Test { + public static void staticMethod() { + + } + + public void instanceMethod() { + + } +} + +class Extensions { + public static void staticMethod(Test test) { + + } + + public static void instanceMethod(Test test) { + + } +}
\ No newline at end of file |