This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 270709 - IllegalStateException: Cannot call getCompilationUnit() if current phase < JavaSource.Phase.PARSED. You must call toPhase(Phase.PARSED) first.
Summary: IllegalStateException: Cannot call getCompilationUnit() if current phase < Ja...
Status: NEW
Alias: None
Product: java
Classification: Unclassified
Component: Project (show other bugs)
Version: Dev
Hardware: All All
: P3 normal (vote)
Assignee: Tomas Zezula
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-05-22 13:46 UTC by Jiri Prox
Modified: 2017-05-22 13:46 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 229219


Attachments
stacktrace (9.22 KB, text/plain)
2017-05-22 13:46 UTC, Jiri Prox
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Prox 2017-05-22 13:46:35 UTC
Build: NetBeans IDE Dev (Build 201705220001)
VM: Java HotSpot(TM) 64-Bit Server VM, 9-ea+167, Java(TM) SE Runtime Environment, 9-ea+167
OS: Windows 7

User Comments:
jiriprox: ISE when crearting module-info in j2se project




Stacktrace: 
java.lang.IllegalStateException: Cannot call getCompilationUnit() if current phase < JavaSource.Phase.PARSED. You must call toPhase(Phase.PARSED) first.
   at org.netbeans.modules.java.source.parsing.CompilationInfoImpl.getCompilationUnit(CompilationInfoImpl.java:222)
   at org.netbeans.api.java.source.CompilationInfo.getCompilationUnit(CompilationInfo.java:186)
   at org.netbeans.modules.java.api.common.queries.ModuleInfoAccessibilityQueryImpl.lambda$readExports$253(ModuleInfoAccessibilityQueryImpl.java:291)
   at org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:523)
   at org.netbeans.modules.parsing.impl.TaskProcessor.callUserTask(TaskProcessor.java:609)
   at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:153)
Comment 1 Jiri Prox 2017-05-22 13:46:38 UTC
Created attachment 164377 [details]
stacktrace