MHs.iteratedLoop(...) throws unexpected WMTE, disallows Iterator subclasses, generates inconsistent loop result type

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P3
    • 9
    • Affects Version/s: 9
    • Component/s: core-libs

      According to MethodHandles.iteratedLoop(...) documentation, it could throw IllegalArgumentException. Documentation specifies that 'conversion' mistakes could lead to runtime exceptions during loop execution (not creation).


      Attached example (IteratedLoop4) produces WrongMethodTypeException.
      iterator=null
      init=null
      body=(String,I,List)I
      Was found on jdk9b109, jdk9b110. Tests are under development, tck_red will be added after development completion.

        1. IteratedLoop3.java
          1 kB
          Anastasiya Solodkaya

            Assignee:
            Michael Haupt
            Reporter:
            Anastasiya Solodkaya (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: