aboutsummaryrefslogtreecommitdiff
path: root/src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@zwitserloot.com>2018-02-06 22:12:42 +0100
committerReinier Zwitserloot <reinier@zwitserloot.com>2018-02-07 00:01:22 +0100
commit66469e04fe35e5ceb3723cb563379a03e4883101 (patch)
treea457e2973556c795a7879279b9c39f4ed5f7cb42 /src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java
parent55bcc142d08ac8a4de0c3965333e3816c496799f (diff)
downloadlombok-66469e04fe35e5ceb3723cb563379a03e4883101.tar.gz
lombok-66469e04fe35e5ceb3723cb563379a03e4883101.tar.bz2
lombok-66469e04fe35e5ceb3723cb563379a03e4883101.zip
[var] various upgrades to var:
* var is promoted to the main package. * It is no longer an opt-in thing. * bug: var (unlike val) is allowed in old-style for loops, but if you multi-init: for (var i = 0, j="Foo";;), you now get an error that you can't do that. * tests both for the multi-for situation and the new main package variant.
Diffstat (limited to 'src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java')
-rw-r--r--src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java b/src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java
index 505eb767..839fce6e 100644
--- a/src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java
+++ b/src/eclipseAgent/lombok/eclipse/agent/PatchValEclipse.java
@@ -103,7 +103,7 @@ public class PatchValEclipse {
}
private static boolean couldBeVar(TypeReference type) {
- return PatchVal.couldBe("lombok.experimental.var", type);
+ return PatchVal.couldBe("lombok.experimental.var", type) || PatchVal.couldBe("lombok.var", type);
}
public static void addFinalAndValAnnotationToSingleVariableDeclaration(Object converter, SingleVariableDeclaration out, LocalDeclaration in) {