James Daugherty created GROOVY-11817:
----------------------------------------

             Summary: Various CompileStatic issues when switching to 
invokedynamic
                 Key: GROOVY-11817
                 URL: https://issues.apache.org/jira/browse/GROOVY-11817
             Project: Groovy
          Issue Type: Bug
    Affects Versions: 4.0.29
         Environment: mac os
jdk 17

            Reporter: James Daugherty


I'm trying to switch a rather large Grails 7 project to invoke dynamic, and 
when enabling indy options, I'm seeing compile issues when CompileStatic & 
invokedynamic are used.  Some of these issues are seen when a compile static 
extension is used, but they do work when indy is disabled.

 

I generated a basic Grails application & created reproducers at this GitHub 
repo:  [https://github.com/jdaugherty/groovy-grails-compile-static-issues]  
Each reproducer has it's own branch, so please ignore the code at the root of 
main other than the README.md file.  

 

At a high level, here are the issues: 
 # Where books is a list of domain objects, calling books[0] errors
 # A second example is provided similar to #1, but after calling the sort() 
call and using `[0]` to get the result
 # a long multiplication issue exists where you can't do `holder.created * 
1000L`, where created is a property that returns a Long
 # this may be related, but a similar long addition issue exists

 

 



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

Reply via email to