Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8267221

jshell feedback is incorrect when creating method with array varargs parameter

    XMLWordPrintable

Details

    • b24
    • generic
    • generic
    • Verified

    Description

      A DESCRIPTION OF THE PROBLEM :
      The jshell feedback, such as "created method test", is incorrect when creating a method which has an array varargs parameter, e.g. `int[]... ints`.
      Instead of showing `[]...` as parameter type only `[]` is shown.

      Note that when using either only multi-dimensional arrays, e.g. `String[][]`, or varargs with non array component type, e.g. `String...`, the feedback is correct.

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Use the following code in jshell:
      void test(int[]... ints) {}

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      It should say:
      > created method test(int[]...)
      ACTUAL -
      It says:
      > created method test(int[])

      Attachments

        Issue Links

          Activity

            People

              jlahoda Jan Lahoda
              webbuggrp Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: