Uploaded image for project: 'NetBeans'
  1. NetBeans
  2. NETBEANS-3614

Multiple IllegalArgumentException thrown for record. JDK 14

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • None
    • None
    • None
    • OpenJDK Runtime Environment 14-ea+27-1339

    Description

      Editing/Writing any code on the editor for 'record' throws below exceptions:

      Exception 1: 

      [exec] java.lang.IllegalArgumentException
      [exec] at org.netbeans.api.java.source.ClassIndex.encodeSearchKind(ClassIndex.java:873)
      [exec] at org.netbeans.api.java.source.ClassIndex.searchImpl(ClassIndex.java:493)
      [exec] at org.netbeans.api.java.source.ClassIndex.getElements(ClassIndex.java:342)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriders.computeUsers(ComputeOverriders.java:280)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriders.computeUsers(ComputeOverriders.java:261)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriders.computeUsers(ComputeOverriders.java:416)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriders.processImpl(ComputeOverriders.java:203)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriders.process(ComputeOverriders.java:154)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeAnnotations.computeAnnotations(ComputeAnnotations.java:104)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeAnnotations.run(ComputeAnnotations.java:85)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor.callParserResultTask(TaskProcessor.java:561)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.run(TaskProcessor.java:786)
      [exec] at org.openide.util.lookup.Lookups.executeWith(Lookups.java:279)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.execute(TaskProcessor.java:702)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:663)
      [exec] at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
      [exec] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      [exec] at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418)
      [exec] at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45)
      [exec] at org.openide.util.lookup.Lookups.executeWith(Lookups.java:278)
      [exec] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)

      ===========================================================

      Exception 2: 

       

      java.lang.IllegalArgumentExceptionjava.lang.IllegalArgumentException at org.netbeans.modules.java.source.usages.DocumentUtil.encodeKind(DocumentUtil.java:391) at org.netbeans.modules.java.source.usages.BinaryName.create(BinaryName.java:150) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.visitClass(SourceAnalyzerFactory.java:648) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.visitClass(SourceAnalyzerFactory.java:274) at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:824) at jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.scan(SourceAnalyzerFactory.java:385) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.scan(SourceAnalyzerFactory.java:274) at jdk.compiler/com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:90) at jdk.compiler/com.sun.source.util.TreeScanner.scan(TreeScanner.java:105) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.visitCompilationUnit(SourceAnalyzerFactory.java:402) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.visitCompilationUnit(SourceAnalyzerFactory.java:274) at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCCompilationUnit.accept(JCTree.java:604) at jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.scan(SourceAnalyzerFactory.java:385)[catch] at org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$SimpleAnalyzer.analyseUnit(SourceAnalyzerFactory.java:242) at org.netbeans.modules.java.source.usages.PersistentClassIndex$IndexPatch.lambda$updateDirty$0(PersistentClassIndex.java:575) at org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:502) at org.netbeans.modules.parsing.impl.TaskProcessor.callUserTask(TaskProcessor.java:586) at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:130) at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:114) at org.netbeans.modules.parsing.impl.TaskProcessor$2.call(TaskProcessor.java:181) at org.netbeans.modules.parsing.impl.TaskProcessor$2.call(TaskProcessor.java:178) at org.netbeans.modules.masterfs.filebasedfs.utils.FileChangedManager.priorityIO(FileChangedManager.java:153) at org.netbeans.modules.masterfs.providers.ProvidedExtensions.priorityIO(ProvidedExtensions.java:335) at org.netbeans.modules.parsing.nb.DataObjectEnvFactory.runPriorityIO(DataObjectEnvFactory.java:118) at org.netbeans.modules.parsing.impl.Utilities.runPriorityIO(Utilities.java:67) at org.netbeans.modules.parsing.impl.TaskProcessor.runUserTask(TaskProcessor.java:178) at org.netbeans.modules.parsing.api.ParserManager.parse(ParserManager.java:81) at org.netbeans.api.java.source.JavaSource.runUserActionTaskImpl(JavaSource.java:452) at org.netbeans.api.java.source.JavaSource.runUserActionTask(JavaSource.java:423) at org.netbeans.modules.java.source.usages.PersistentClassIndex$IndexPatch.updateDirty(PersistentClassIndex.java:568) at org.netbeans.modules.java.source.usages.PersistentClassIndex$IndexPatch.getPatch(PersistentClassIndex.java:530) at org.netbeans.modules.java.source.usages.PersistentClassIndex.getDeclaredElements(PersistentClassIndex.java:279) at org.netbeans.api.java.source.ClassIndex.searchImpl(ClassIndex.java:566) at org.netbeans.api.java.source.ClassIndex.getDeclaredTypes(ClassIndex.java:531) at org.netbeans.modules.java.editor.imports.ComputeImports.doComputeCandidates(ComputeImports.java:262) at org.netbeans.modules.java.editor.imports.ComputeImports.computeCandidatesEx(ComputeImports.java:212) at org.netbeans.modules.java.editor.imports.ComputeImports.computeCandidatesEx(ComputeImports.java:170) at org.netbeans.modules.java.hints.errors.ImportClass.getCandidateFQNs(ImportClass.java:348) at org.netbeans.modules.java.hints.errors.ImportClass.run(ImportClass.java:185) at org.netbeans.modules.java.hints.infrastructure.CreatorBasedLazyFixList.compute(CreatorBasedLazyFixList.java:123) at org.netbeans.modules.java.hints.infrastructure.LazyHintComputation.run(LazyHintComputation.java:87) at org.netbeans.modules.java.hints.infrastructure.LazyHintComputation.run(LazyHintComputation.java:33) at org.netbeans.modules.java.source.JavaSourceAccessor$CancelableTaskWrapper.run(JavaSourceAccessor.java:273) at org.netbeans.modules.parsing.impl.TaskProcessor.callParserResultTask(TaskProcessor.java:561) at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.run(TaskProcessor.java:786) at org.openide.util.lookup.Lookups.executeWith(Lookups.java:279) at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.execute(TaskProcessor.java:702) at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:663) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418) at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45) at org.openide.util.lookup.Lookups.executeWith(Lookups.java:278) at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)

       

      ===========================================================

      Exception 3:

      [exec] java.lang.IllegalArgumentException: RECORD
      [exec] at org.netbeans.api.java.source.ElementHandle.resolveImpl(ElementHandle.java:284)
      [exec] at org.netbeans.api.java.source.ElementHandle.resolve(ElementHandle.java:131)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriding.compute(ComputeOverriding.java:181)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeOverriding.process(ComputeOverriding.java:107)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeAnnotations.computeAnnotations(ComputeAnnotations.java:103)
      [exec] at org.netbeans.modules.java.editor.overridden.ComputeAnnotations.run(ComputeAnnotations.java:85)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor.callParserResultTask(TaskProcessor.java:561)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.run(TaskProcessor.java:786)
      [exec] at org.openide.util.lookup.Lookups.executeWith(Lookups.java:279)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.execute(TaskProcessor.java:702)
      [exec] at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:663)
      [exec] at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
      [exec] at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      [exec] at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418)
      [exec] at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45)
      [exec] at org.openide.util.lookup.Lookups.executeWith(Lookups.java:278)
      [exec] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)

      Attachments

        Issue Links

          Activity

            No work has yet been logged on this issue.

            People

              Unassigned Unassigned
              singh-akhilesh Akhilesh Singh
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: