[
https://issues.apache.org/jira/browse/GROOVY-6369?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18149098#comment-18149098
]
Daniel Sun commented on GROOVY-6369:
------------------------------------
Fixed on master; added a regression test in
c359948c59b697dc7447112e666a109a61beb4ab
(https://github.com/apache/groovy/commit/c359948c59b697dc7447112e666a109a61beb4ab).
> Groovy should not allow "new" on generic type
> ---------------------------------------------
>
> Key: GROOVY-6369
> URL: https://issues.apache.org/jira/browse/GROOVY-6369
> Project: Groovy
> Issue Type: Bug
> Components: Compiler
> Reporter: Cédric Champeau
> Assignee: Daniel Sun
> Priority: Major
> Fix For: 7.0.0-alpha-1
>
>
> The following code compiles fine:
> {code}
> public <T> T nouveau() { new T() }
> {code}
> but instiantiating a generic type should not be allowed.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)