From 3f0fec18726fb9c9f4dce614dbcfa650c1c04bf7 Mon Sep 17 00:00:00 2001 From: Reinier Zwitserloot Date: Fri, 31 Jan 2020 15:58:19 +0100 Subject: [issue #788] Add more nullity annotations where relevant (chainable setters, static constructors, builder stuff) --- test/transform/resource/before/StaticConstructor.java | 6 ++++++ .../transform/resource/before/ValueStaticConstructorOf.java | 13 ++++++------- test/transform/resource/before/WithPlain.java | 1 + 3 files changed, 13 insertions(+), 7 deletions(-) create mode 100644 test/transform/resource/before/StaticConstructor.java (limited to 'test/transform/resource/before') diff --git a/test/transform/resource/before/StaticConstructor.java b/test/transform/resource/before/StaticConstructor.java new file mode 100644 index 00000000..eff1fa9b --- /dev/null +++ b/test/transform/resource/before/StaticConstructor.java @@ -0,0 +1,6 @@ +//CONF: lombok.addNullAnnotations = checkerframework +import lombok.AllArgsConstructor; +@AllArgsConstructor(staticName = "of") +public class StaticConstructor { + String name; +} diff --git a/test/transform/resource/before/ValueStaticConstructorOf.java b/test/transform/resource/before/ValueStaticConstructorOf.java index ac857ffd..bd318d40 100644 --- a/test/transform/resource/before/ValueStaticConstructorOf.java +++ b/test/transform/resource/before/ValueStaticConstructorOf.java @@ -1,12 +1,11 @@ import lombok.Value; @Value(staticConstructor = "of") public class ValueStaticConstructorOf { + String name; + Double price; - String name; - Double price; - - private ValueStaticConstructorOf(String name, Double price) { - this.name = name; - this.price = price; - } + private ValueStaticConstructorOf(String name, Double price) { + this.name = name; + this.price = price; + } } diff --git a/test/transform/resource/before/WithPlain.java b/test/transform/resource/before/WithPlain.java index 1b2a19c4..4f048242 100644 --- a/test/transform/resource/before/WithPlain.java +++ b/test/transform/resource/before/WithPlain.java @@ -1,3 +1,4 @@ +//CONF: lombok.addNullAnnotations = spring import lombok.With; class WithPlain { @lombok.With int i; -- cgit