diff options
author | Roel Spilker <r.spilker@gmail.com> | 2010-11-07 02:48:13 +0100 |
---|---|---|
committer | Roel Spilker <r.spilker@gmail.com> | 2010-11-07 02:48:13 +0100 |
commit | 50524f338ef1f29a1848a2f2d542d6b7317c5eff (patch) | |
tree | b873f6124fa9d517531baf25a80e42f41d80fdbe /src/core/lombok/javac | |
parent | 2e88614a840bd9cb91521bd2d7498670b5626054 (diff) | |
download | lombok-50524f338ef1f29a1848a2f2d542d6b7317c5eff.tar.gz lombok-50524f338ef1f29a1848a2f2d542d6b7317c5eff.tar.bz2 lombok-50524f338ef1f29a1848a2f2d542d6b7317c5eff.zip |
Provide access to the actual annotation values
Diffstat (limited to 'src/core/lombok/javac')
-rw-r--r-- | src/core/lombok/javac/Javac.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/lombok/javac/Javac.java b/src/core/lombok/javac/Javac.java index 58a24207..6d9800ab 100644 --- a/src/core/lombok/javac/Javac.java +++ b/src/core/lombok/javac/Javac.java @@ -90,6 +90,7 @@ public class Javac { String name = m.getName(); List<String> raws = new ArrayList<String>(); List<Object> guesses = new ArrayList<Object>(); + List<Object> expressions = new ArrayList<Object>(); final List<DiagnosticPosition> positions = new ArrayList<DiagnosticPosition>(); boolean isExplicit = false; @@ -112,17 +113,19 @@ public class Javac { List<JCExpression> elems = ((JCNewArray)rhs).elems; for (JCExpression inner : elems) { raws.add(inner.toString()); + expressions.add(inner); guesses.add(calculateGuess(inner)); positions.add(inner.pos()); } } else { raws.add(rhs.toString()); + expressions.add(rhs); guesses.add(calculateGuess(rhs)); positions.add(rhs.pos()); } } - values.put(name, new AnnotationValue(node, raws, guesses, isExplicit) { + values.put(name, new AnnotationValue(node, raws, expressions, guesses, isExplicit) { @Override public void setError(String message, int valueIdx) { if (valueIdx < 0) node.addError(message); else node.addError(message, positions.get(valueIdx)); |