Community
Participate
Working Groups
Version: 3.0.0 Build id: 200406251208 The above error is displayed after launching the workbench w/the Java editor open. java.lang.ExceptionInInitializerError at org.eclipse.jdt.core.dom.AST.newConditionalExpression(AST.java:2517) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1652) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:911) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:2077) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:1843) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:770) at org.eclipse.jdt.core.dom.ASTConverter.buildBodyDeclarations (ASTConverter.java:336) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:274) at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.java:152) at org.eclipse.jdt.core.dom.ASTParser.convert(ASTParser.java:711) at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:681) at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:574) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider.createAST (ASTProvider.java:439) at org.eclipse.jdt.internal.ui.javaeditor.ASTProvider.getAST (ASTProvider.java:391) at org.eclipse.jdt.internal.ui.javaeditor.JavaEditor$8.run (JavaEditor.java:3775) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66) Caused by: java.lang.NullPointerException at org.eclipse.jdt.core.dom.ASTNode.addProperty(ASTNode.java:1728) at org.eclipse.jdt.core.dom.ConditionalExpression.<clinit> (ConditionalExpression.java:59) ... 16 more eclipse.buildId=I200406251208 java.version=1.4.2_04 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Would you have a test case to reproduce?
Sorry, I don't a step-by-step recreation steps. It occurred after importing some external plug-ins and restarting. Next time I will save the workspace for later diagnosis.
This might be a concurrency issue.
Reopen.
Jim, I don't think that setting the properties is thread-safe. Is it possible that the static initializer is called in two different threads?
I see the problem. The static file tempPDL is declared in ASTNode. This means that there is conflict if more than one ASTNode subclass is being initialized at the same time.
Created attachment 12988 [details] jdt.core patch
This problem can show up whenever several threads are triggering AST node class initializations simultaneously. I reworked AST node static initializers to no longer use a static variable in ASTNode. Released to HEAD (3.1). Updated build notes. Philippe, This is a candidate fix for inclusion in 3.0.1. (Attached patch makes it easy to apply to 3.0.1 if needed.)
Fine by me. Olivier please review the change and release it if ok.
Reopening until addressed in 3.0.1 stream.
The patch looks good. Now each node has its own list.
Fixed and released in 3_0_maintenance stream.
Verified for 3.0.1 RC1