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

array coercion missing for subarray assignment

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.1.0-beta-1
    • None
    • None

    Description

      The following code

        int[][] arr2 = new int[1][]
        arr2[0] = [1,2]
      

      is supported by the static compiler as well as primopts. Normal caching tends to have a ArrayStoreException here. Imho this should be supported, since groovy supports for example int[] x = [1,2] too. arr2[0] is in that respect like x an array under initialization.

      Attachments

        Activity

          People

            blackdrag Jochen Theodorou
            blackdrag Jochen Theodorou
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: