[ https://issues.apache.org/jira/browse/GROOVY-11207 ]
Eric Milles deleted comment on GROOVY-11207: -------------------------------------- was (Author: emilles): Can you see if the master branch handles this? There was at least one fix on this front. > STC rejects concatenated string as annotation parameter > ------------------------------------------------------- > > Key: GROOVY-11207 > URL: https://issues.apache.org/jira/browse/GROOVY-11207 > Project: Groovy > Issue Type: Bug > Components: Static Type Checker > Affects Versions: 4.0.12 > Reporter: Christopher Smith > Assignee: Eric Milles > Priority: Major > > {code:groovy} > @CompileStatic > class Example { > public static final String ASDF = 'asdf' > @Grab(ASDF + ':asdf:123') > // @CompileDynamic > void foo() {} > } > {code} > This produces the familiar {{Attribute 'value' should have type > 'java.lang.String'; but found type 'java.lang.Object' in @groovy.lang.Grab}} > on the annotation value, but applying {{@CompileDynamic}} to the method > declaration (alongside the non-working annotation!) fixes it. -- This message was sent by Atlassian Jira (v8.20.10#820010)