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

DOC: jshell Tool Reference -- jshell-specific shortcuts not documented

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 9, 10
    • Fix Version/s: 10
    • Component/s: docs
    • Labels:

      Description

      Of these, only <tab> completion is documented --

      jshell> /help shortcuts
      |
      | shortcuts
      |
      | Supported shortcuts include:
      |
      | <tab>
      | After entering the first few letters of a Java identifier,
      | a jshell command, or, in some cases, a jshell command argument,
      | press the <tab> key to complete the input.
      | If there is more than one completion, then possible completions will be shown.
      | Will show documentation if available and appropriate.
      |
      | Shift-<tab> v
      | After a complete expression, hold down <shift> while pressing <tab>,
      | then release and press "v", the expression will be converted to
      | a variable declaration whose type is based on the type of the expression.
      |
      | Shift-<tab> m
      | After a complete expression or statement, hold down <shift> while pressing <tab>,
      | then release and press "m", the expression or statement will be converted to
      | a method declaration. If an expression, the return type is based on the type
      | of the expression.
      |
      | Shift-<tab> i
      | After an unresolvable identifier, hold down <shift> while pressing <tab>,
      | then release and press "i", and jshell will propose possible imports
      | which will resolve the identifier based on the content of the specified classpath.


      Note: Shift-<tab> m -- was added in JDK 10.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jgordon Joni Gordon
                Reporter:
                rfield Robert Field
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Due:
                  Created:
                  Updated:
                  Resolved: