[ https://issues.apache.org/jira/browse/GROOVY-7677?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eric Milles closed GROOVY-7677. ------------------------------- Resolution: Information Provided > AbstractASTTransformation member-value methods should traverse compile-time > constants > ------------------------------------------------------------------------------------- > > Key: GROOVY-7677 > URL: https://issues.apache.org/jira/browse/GROOVY-7677 > Project: Groovy > Issue Type: Improvement > Components: groovy-jdk > Affects Versions: 2.4.5 > Reporter: Christopher Smith > Priority: Major > Labels: annotations > > As described [in Cédric's article on parameterized > transformations|https://melix.github.io/ast-workshop/exercise4-hints.html], > the value of an annotation member during a transformation can be one of > several types of expression. The {{AbstractASTTransformation}} class provides > a number of methods that "get member values", but only if those values are > provided as an *immediate* {{ConstantExpression}}. > Using, for example, a {{public static final String}} as an annotation value > is perfectly legitimate, and the current implementation simply treats the > value as if it were not present. While it would be some work, I suggest that > the behavior of these methods should be enhanced to both traverse > property/variable expressions and support retrieval of annotation default > values. > If this is agreeable and there's no identifiable technical reason why this > isn't feasible, then I'll attempt to implement at least part of the behavior > as part of [my blog > series|https://blog.chrylis.com/2015/11/13/introducing-gjt/] and would like > to explore merging it into the main distribution. -- This message was sent by Atlassian Jira (v8.20.10#820010)