Groovy JDK 11 disable the WARNING message

前端 未结 3 1895
猫巷女王i
猫巷女王i 2020-12-11 14:47

When I run Groovy 2.5.3 on JDK 11 its giving warning message:

groovy -e \'print \"h         


        
相关标签:
3条回答
  • You can disable the Java warnings with GROOVY_TURN_OFF_JAVA_WARNINGS as a temporary fix:

    $ GROOVY_TURN_OFF_JAVA_WARNINGS=true groovy -e 'print "hi\n"'
    hi
    
    0 讨论(0)
  • 2020-12-11 15:09

    The current stable version 3.0.x of Groovy is reported to fix this issue, see GROOVY-8339 for the detailed discussion.

    0 讨论(0)
  • 2020-12-11 15:18

    This is still an issue in Groovy 2.5.8

    I'm on macOS. I chose to fall back to Java 8 (In homebrew, do a brew cask install adoptopenjdk8) and the warnings went away. I understand that is is not desirable if you need a newer JDK (I do not)

    0 讨论(0)
提交回复
热议问题