There is another modification to your code the makes the compiler happy:
public class foo {
static Class oClass = (new Object()).getClass();
public void bar(Object param) {
if (oClass == param.getClass()) {
/* do nothing */ ;
}
}
}
Why is that?
I don't know - I can only try
Ron Resnick wrote:
> You don't get to see internal javac compiler errors every day -
Not every day, but once a month...
(Codeconversion, stackSize Null, np...)
Sorry for OT, couldn't resist...
--
To UNSUBSCRIBE, email to [EMA
Thanks for the rapid responses Martin, Steve. I'll quickly take this
off blackdown due to its non-Linux relevance. I thought I would point
out the following though:
If you insert an actual executable hunk of code into the if block,
things work properly. Eg, consider
class foo
{
void bar (Objec
Ron Resnick wrote:
>
> Heh.
>
> You don't get to see internal javac compiler errors every day -
> this was kind of neat:
>
> [resnick@rresnick f3]$ javac foo.java
> java.lang.NullPointerException
> at
> sun.tools.tree.ConditionalExpression.costInline(ConditionalExpression.java)
>
Ron Resnick writes:
> Heh.
>
> You don't get to see internal javac compiler errors every day -
> this was kind of neat:
>
> [resnick@rresnick f3]$ javac foo.java
> java.lang.NullPointerException
> at
> sun.tools.tree.ConditionalExpression.costInline(ConditionalExpression.java)
Heh.
You don't get to see internal javac compiler errors every day -
this was kind of neat:
[resnick@rresnick f3]$ javac foo.java
java.lang.NullPointerException
at
sun.tools.tree.ConditionalExpression.costInline(ConditionalExpression.java)
at
sun.tools.tree.BinaryExpression.cos