This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Java: fix Array_3 byte compiler failures
Andrew Haley wrote:
How could it be otherwise? aconst_null doesn't push an array type.
At the source-code level, it has to be converted to an array type,
before you can use it.
However, I tried a more direct example:
int baz()
{
Object[] x = null;
return x.length;
}
This generates:
0: aconst_null
1: astore_1
2: aload_1
3: arraylength
4: ireturn
So in this case at least case the bytecode has to handle
null_pointer_node.
I withdraw my objection.
--
--Per Bothner
per@bothner.com http://www.bothner.com/per/