[ 
https://issues.apache.org/jira/browse/NETBEANS-896?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Laszlo Kishalmi resolved NETBEANS-896.
--------------------------------------
       Resolution: Fixed
    Fix Version/s: 9.0

> Defining generic method throws Exception on without nbjavac
> -----------------------------------------------------------
>
>                 Key: NETBEANS-896
>                 URL: https://issues.apache.org/jira/browse/NETBEANS-896
>             Project: NetBeans
>          Issue Type: Bug
>          Components: java - Editor
>    Affects Versions: 9.0
>         Environment: release-302-on-20180517 without nbjavac
>            Reporter: Naoki Kishida
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 9.0
>
>          Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> Defining a generic method throws NPE.
> After inputing `<T>`, NPE is thrown.
>  {code}
> class Foo {
>   <T>
> }{code}
> {code}
> java.lang.NullPointerException
>       at 
> org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.visitErroneous(SourceAnalyzerFactory.java:752)
>       at 
> org.netbeans.modules.java.source.usages.SourceAnalyzerFactory$UsagesVisitor.visitErroneous(SourceAnalyzerFactory.java:274)
>       at 
> jdk.compiler/com.sun.tools.javac.tree.JCTree$JCErroneous.accept(JCTree.java:2927)
>       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.visitClass(SourceAnalyzerFactory.java:716)
>       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:808)
>       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.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:591)
>       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$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:501)
>       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:451)
>       at 
> org.netbeans.api.java.source.JavaSource.runUserActionTask(JavaSource.java:422)
>       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.search(PersistentClassIndex.java:220)
>       at 
> org.netbeans.api.java.source.ClassIndex.searchImpl(ClassIndex.java:499)
>       at 
> org.netbeans.api.java.source.ClassIndex.getElements(ClassIndex.java:342)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeOverriders.computeUsers(ComputeOverriders.java:284)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeOverriders.computeUsers(ComputeOverriders.java:265)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeOverriders.computeUsers(ComputeOverriders.java:427)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeOverriders.processImpl(ComputeOverriders.java:203)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeOverriders.process(ComputeOverriders.java:154)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeAnnotations.computeAnnotations(ComputeAnnotations.java:104)
>       at 
> org.netbeans.modules.java.editor.overridden.ComputeAnnotations.run(ComputeAnnotations.java:85)
>       at 
> org.netbeans.modules.parsing.impl.TaskProcessor.callParserResultTask(TaskProcessor.java:561)
> [catch] 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)
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org
For additional commands, e-mail: commits-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to