groovy-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Graeme Rocher (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (GROOVY-7864) Stack overflow correcting generics when using @CompileStatic
Date Wed, 29 Jun 2016 06:28:45 GMT

    [ https://issues.apache.org/jira/browse/GROOVY-7864?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15354642#comment-15354642
] 

Graeme Rocher commented on GROOVY-7864:
---------------------------------------

This is a duplicate of https://issues.apache.org/jira/browse/GROOVY-7722

> Stack overflow correcting generics when using @CompileStatic
> ------------------------------------------------------------
>
>                 Key: GROOVY-7864
>                 URL: https://issues.apache.org/jira/browse/GROOVY-7864
>             Project: Groovy
>          Issue Type: Bug
>    Affects Versions: 2.4.7
>            Reporter: Graeme Rocher
>              Labels: duplicate
>
> I have this RxJava code:
> {code}
> HttpClientRequest httpClientRequest = httpClient.createGet(uri)
> httpClientRequest
>         .switchMap { HttpClientResponse response ->
>     response.getContent()
> }.switchMap { Object object ->
>     return Observable.create(new Observable.OnSubscribe() {
>         @Override
>         void call(Subscriber subscriber) {
>             ....
>         }
>     })
> }
> {code}
> Which produces a StackOverflow:
> {code}
> Information:Groovyc: java.lang.StackOverflowError
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:316)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
> ls.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>     at org.codehaus.groovy.ast.tools.GenericsUtils.correctToGenericsSpecRecurse(GenericsUtils.java:340)
>   etc.
> {code}
> Issues seems to originate from the `new  Observable.OnSubscribe()` anonymous inner class
constructor



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message