Björn Kautler created GROOVY-9510:
-------------------------------------

             Summary: DelegatesTo and similar for annotation member methods
                 Key: GROOVY-9510
                 URL: https://issues.apache.org/jira/browse/GROOVY-9510
             Project: Groovy
          Issue Type: Bug
            Reporter: Björn Kautler


If you have an annotation with a closure field like for example this in Spock:
{code:java}
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.TYPE, ElementType.METHOD})
@ExtensionAnnotation(RequiresExtension.class)
public @interface Requires {
  Class<? extends Closure> value();
}{code}
you can use it like
{code:java}
@Requires({ os.windows }){code}
But I see no way to add IDE-hints for that closure like 
{{@DelegatesTo(PreconditionContext.class)}} as it is restriced to parameters.

It would be nice if you could also annotate annotation member methods (and if 
IDEs would then support that too).



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to