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

jshell tool: double shift-tab on variable crashes tool

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b147
    • Verification:
      Verified

      Description

      Reproducible with any type variable --

      jshell> Object o
      o ==> null

      jshell> o
      .o:java.lang.Object
      <press shift-tab again to see javadoc>

      jshell> oException in thread "main" java.lang.NullPointerException
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter$2.visitStartElement(JavadocFormatter.java:642)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter$2.visitStartElement(JavadocFormatter.java:635)
              at jdk.compiler/com.sun.tools.javac.tree.DCTree$DCStartElement.accept(DCTree.java:780)
              at jdk.compiler/com.sun.source.util.DocTreeScanner.scan(DocTreeScanner.java:80)
              at jdk.compiler/com.sun.source.util.DocTreeScanner.scan(DocTreeScanner.java:99)
              at jdk.compiler/com.sun.source.util.DocTreeScanner.visitDocComment(DocTreeScanner.java:184)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter$2.visitDocComment(JavadocFormatter.java:665)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter$2.visitDocComment(JavadocFormatter.java:635)
              at jdk.compiler/com.sun.tools.javac.tree.DCTree$DCDocComment.accept(DCTree.java:132)
              at jdk.compiler/com.sun.source.util.DocTreeScanner.scan(DocTreeScanner.java:80)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter.countTableColumns(JavadocFormatter.java:677)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter.access$100(JavadocFormatter.java:70)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter$FormatJavadocScanner.visitDocComment(JavadocFormatter.java:144)
              at jdk.compiler/com.sun.tools.javac.tree.DCTree$DCDocComment.accept(DCTree.java:132)
              at jdk.compiler/com.sun.source.util.DocTreeScanner.scan(DocTreeScanner.java:80)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter$FormatJavadocScanner.scan(JavadocFormatter.java:549)
              at jdk.compiler/jdk.internal.shellsupport.doc.JavadocFormatter.formatJavadoc(JavadocFormatter.java:118)
              at jdk.jshell/jdk.internal.jshell.tool.ConsoleIOContext.lambda$documentation$7(ConsoleIOContext.java:287)
              at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
              at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1480)
              at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
              at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
              at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913)
              at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
              at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:511)
              at jdk.jshell/jdk.internal.jshell.tool.ConsoleIOContext.documentation(ConsoleIOContext.java:294)
              at jdk.jshell/jdk.internal.jshell.tool.ConsoleIOContext.lambda$new$4(ConsoleIOContext.java:173)
              at jdk.internal.le/jdk.internal.jline.console.ConsoleReader.readLine(ConsoleReader.java:2529)
              at jdk.internal.le/jdk.internal.jline.console.ConsoleReader.readLine(ConsoleReader.java:2278)
              at jdk.jshell/jdk.internal.jshell.tool.ConsoleIOContext.readLine(ConsoleIOContext.java:200)
              at jdk.jshell/jdk.internal.jshell.tool.JShellTool.run(JShellTool.java:862)
              at jdk.jshell/jdk.internal.jshell.tool.JShellTool.start(JShellTool.java:538)
              at jdk.jshell/jdk.internal.jshell.tool.JShellTool.start(JShellTool.java:502)
              at jdk.jshell/jdk.internal.jshell.tool.JShellTool.main(JShellTool.java:492)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jlahoda Jan Lahoda
              Reporter:
              rfield Robert Field
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: