JShell does not handle -source 8 properly

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P4
    • 17
    • Affects Version/s: 17
    • Component/s: tools
    • None
    • b06

      Running JShell with -source 8 (-C-source -C8), only the first snippet is evaluated:
      ---
      $ jshell -C-source -C8
      | Welcome to JShell -- Version 17-internal
      | For an introduction type: /help intro

      jshell> 1+1
      $1 ==> 2

      jshell> 1+2
      | Error:
      | cannot find symbol
      | symbol: class
      | 1+2
      | ^
      | Error:
      | static import only from classes and interfaces
      | 1+2
      | ^

      ---

            Assignee:
            Jan Lahoda
            Reporter:
            Jan Lahoda
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: