Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-10594

Unable to Call StringBuilder.substring() method (JDK17, Groovy 3)

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.0.15
    • None
    • None

    Description

      I am attaching a sample project that will simply print Hello on console. JDK target is set to 11.

      Project can be run using command

      ./gradlew clean run
      

      When running project with JDK11 it will successfully print Hello to console

      But when running with JDK17, it fails with error

      groovy.lang.MissingMethodException: No signature of method: java.lang.StringBuilder.substring() is applicable for argument types: (Integer, Integer) values: [0, 5] 

      Attachments

        1. demo.zip
          106 kB
          Gurpreet

        Issue Links

          Activity

            People

              emilles Eric Milles
              gurpreetsingh Gurpreet
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: