aboutsummaryrefslogtreecommitdiff
path: root/src/core/lombok/eclipse/handlers/HandleVal.java
diff options
context:
space:
mode:
authorReinier Zwitserloot <reinier@zwitserloot.com>2012-08-10 18:06:13 +0200
committerReinier Zwitserloot <reinier@zwitserloot.com>2012-08-10 18:06:13 +0200
commit1be7da76012b246af24d0515d192bca85d65c823 (patch)
tree21d9675c00d812c6bbbf76edb80d38b16777740d /src/core/lombok/eclipse/handlers/HandleVal.java
parent70317c73841d3e83b4b8008b68bea95753a5275f (diff)
downloadlombok-1be7da76012b246af24d0515d192bca85d65c823.tar.gz
lombok-1be7da76012b246af24d0515d192bca85d65c823.tar.bz2
lombok-1be7da76012b246af24d0515d192bca85d65c823.zip
* Added priorities to handlers, along with implementation of the priority system for javac and ecj.
* @Value now makes the class itself final by default.
Diffstat (limited to 'src/core/lombok/eclipse/handlers/HandleVal.java')
-rw-r--r--src/core/lombok/eclipse/handlers/HandleVal.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/core/lombok/eclipse/handlers/HandleVal.java b/src/core/lombok/eclipse/handlers/HandleVal.java
index 56b3effd..e7849952 100644
--- a/src/core/lombok/eclipse/handlers/HandleVal.java
+++ b/src/core/lombok/eclipse/handlers/HandleVal.java
@@ -22,6 +22,7 @@
package lombok.eclipse.handlers;
import lombok.val;
+import lombok.core.HandlerPriority;
import lombok.eclipse.DeferUntilPostDiet;
import lombok.eclipse.EclipseASTAdapter;
import lombok.eclipse.EclipseASTVisitor;
@@ -38,6 +39,7 @@ import org.mangosdk.spi.ProviderFor;
*/
@ProviderFor(EclipseASTVisitor.class)
@DeferUntilPostDiet
+@HandlerPriority(65536) // 2^16; resolution needs to work, so if the RHS expression is i.e. a call to a generated getter, we have to run after that getter has been generated.
public class HandleVal extends EclipseASTAdapter {
@Override public void visitLocal(EclipseNode localNode, LocalDeclaration local) {
if (!EclipseHandlerUtil.typeMatches(val.class, localNode, local.type)) return;