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

Paul King closed GROOVY-4757.
-----------------------------

> Can't compile method with generic signatures and default visibiliy access
> -------------------------------------------------------------------------
>
>                 Key: GROOVY-4757
>                 URL: https://issues.apache.org/jira/browse/GROOVY-4757
>             Project: Groovy
>          Issue Type: Bug
>          Components: parser-antlr
>    Affects Versions: 1.7.10
>            Reporter: Andres Almiray
>            Assignee: Daniel Sun
>            Priority: Major
>             Fix For: 2.6.0-alpha-1
>
>
> The following script results in a compilation error
> {code}
> class Foo {
>     <T extends Object> void foo(T t) {}
> }
> f = new Foo()
> // compiler output
> 1 compilation error:
> unexpected token: < at line: 2, column: 5
> {code}
> Adding a visibility accessor makes it work
> {code}
> class Foo {
>     public <T extends Object> void foo(T t) {}
> }
> f = new Foo()
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to