diff options
author | Rawi01 <Rawi01@users.noreply.github.com> | 2020-11-25 09:25:57 +0100 |
---|---|---|
committer | Roel Spilker <r.spilker@gmail.com> | 2020-12-03 23:40:44 +0100 |
commit | 965f2367e0e57744c51b10ac341400b8ec57287a (patch) | |
tree | 576aefcf9b19488d9499c785e056a72907471221 /test/transform/resource/before/BuilderWithToBuilder.java | |
parent | e1f82ac4d132769cfc272dccfc916aeba7181718 (diff) | |
download | lombok-965f2367e0e57744c51b10ac341400b8ec57287a.tar.gz lombok-965f2367e0e57744c51b10ac341400b8ec57287a.tar.bz2 lombok-965f2367e0e57744c51b10ac341400b8ec57287a.zip |
[fixes #2657] Use the correct field to query parent type parameters
Diffstat (limited to 'test/transform/resource/before/BuilderWithToBuilder.java')
-rw-r--r-- | test/transform/resource/before/BuilderWithToBuilder.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/transform/resource/before/BuilderWithToBuilder.java b/test/transform/resource/before/BuilderWithToBuilder.java index 50938ab2..5b87a18f 100644 --- a/test/transform/resource/before/BuilderWithToBuilder.java +++ b/test/transform/resource/before/BuilderWithToBuilder.java @@ -18,3 +18,16 @@ class ConstructorWithToBuilder<T> { public ConstructorWithToBuilder(String mOne, @Builder.ObtainVia(field = "foo") T baz, com.google.common.collect.ImmutableList<T> bars) { } } + +class StaticMethodWithToBuilder<T> { + private T foo; + + public StaticMethodWithToBuilder(T foo) { + this.foo = foo; + } + + @Builder(toBuilder = true) + public static <T> StaticMethodWithToBuilder<T> of(T foo) { + return new StaticMethodWithToBuilder<T>(foo); + } +}
\ No newline at end of file |