[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools] Re: Somewhat odd compiler error: "... missing type java.lang.Object"

Jon,

the Java compiler stops processing when it doesn't find java.lang.Object. If
this
type is missing no Java file can be compiled successfully. So this is a kind
of
optimization. But I agree that the compiler error should be more prominent
so
that the user knows how to fix that problem.

Dirk


"Jon Skeet" <skeet@xxxxxxxxx> wrote in message
news:MPG.15ec2763d77b287f989695@xxxxxxxxxxxxxxxxxxx
> Jon Skeet <skeet@xxxxxxxxx> wrote:
> > I've just added a new class to my project (by adding it to the file
> > system then refreshing the directory from local), and it's come up with
> > a bizarre compilation error:
> >
> > "This compilation unit indirectly references the missing type
> > java.lang.Object (typically some required class file is referencing a
> > type outside the classpath)"
> >
> > Rebuilding all doesn't help, and the error cursor is stuck on line one
> > of the source file.
> >
> > I'm pretty sure the code itself is okay, and when playing with
> > refactoring I think I saw this error before (but dismissed it as user
> > error at the time).
> >
> > Any advice? Clearly java.lang.Object is known about, otherwise *nothing*
> > would compile...
>
> Fear not, I've found the problem. My installation was screwed up, almost
> certainly due to gross user error.
>
> (It's somewhat surprising that a rebuild all didn't mark all classes as
> problematic though.)
>
> --
> Jon Skeet - <skeet@xxxxxxxxx>
> http://www.pobox.com/~skeet/
> If replying to the group, please do not mail me too