tags:

views:

178

answers:

1

I am receiving the following message from my Eclipse compiler, and my project fails to compile....

Internal compiler error: java.lang.NullPointerException at org.eclipse.jdt.internal.compiler.problem.ProblemReporter.missingTypeInMethod(ProblemReporter.java:5075)

I've tried updating Eclipse, restarting eclipse, closing and opening the project, refreshing, cleaning/rebuilding, etc. I'm out of ideas.

+1  A: 

That seems to be the bug 250297, fixed in eclipse 3.4.2. Also fixed in the 3.5 (M4, November 2008, as mentioned in this JDT release notes)

The failure occurs on line (>>>):

public void missingTypeInMethod(MessageSend messageSend, MethodBinding method)
{
    List missingTypes = method.collectMissingTypes(null);
>>> TypeBinding missingType = (TypeBinding) missingTypes.get(0);

It would indicate that though we identified a missing type (which we try to complain against), we fail to locate it inside the method signature...


So... if you are using an "older" version of eclipse (like 3.4, or 3.4.1), a good solution is to upgrade (that is, install another fresh version of eclipse, 3.4.2 or 3.5.1), while reusing your same workspace.
The error should then go away.

VonC
I should have mentioned this before, I have Eclipse 3.5.1.R35x_v20090910...
Sarah Haskins