[ 
https://issues.apache.org/jira/browse/GROOVY-11178?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Eric Milles updated GROOVY-11178:
---------------------------------
    Description: 
Consider the following:
{code:groovy}
import java.lang.annotation.*
@Target(ElementType.TYPE_USE)
public @interface A {
}

Object o = new @A Object()
{code}

The annotation {{@A}} is added to the AST into the Object type's annotations.  
However, once type is resolved, the annotations come from the redirect and so 
this annotation is left unresolved and unavailable.

  was:
Consider the following:
{code:groovy}
import java.lang.annotation.*
@Target(ElementType.TYPE_USE)
public @interface A {
}

Object o = new @A Object()
{code}

The annotation {{@A}} is added to the AST into the Object type's annotations.  
However, one resolved, the annotations come from the redirect and so this 
annotation is left unresolved and unavailable.


> JSR 308: constructor call annotations not resolved or available
> ---------------------------------------------------------------
>
>                 Key: GROOVY-11178
>                 URL: https://issues.apache.org/jira/browse/GROOVY-11178
>             Project: Groovy
>          Issue Type: Bug
>    Affects Versions: 5.0.0-alpha-2, 4.0.15
>            Reporter: Eric Milles
>            Assignee: Eric Milles
>            Priority: Major
>              Labels: annotations
>
> Consider the following:
> {code:groovy}
> import java.lang.annotation.*
> @Target(ElementType.TYPE_USE)
> public @interface A {
> }
> Object o = new @A Object()
> {code}
> The annotation {{@A}} is added to the AST into the Object type's annotations. 
>  However, once type is resolved, the annotations come from the redirect and 
> so this annotation is left unresolved and unavailable.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to