BZ #65: Innocent looking array usage crashes cacao

Status fields:

creation_ts:2008-05-02 15:44
component:vm
version:default branch
rep_platform:All
op_sys:All
bug_status:RESOLVED
resolution:FIXED
reporter:stefan@complang.tuwien.ac.at
public class array
{
    public static void main (String args[])
    {
        Object o = new int[5][4][3];
        Number[][][] ox = (Number[][][]) o;
    }
}

Expected:

Exception in thread "main" java.lang.ClassCastException: [[[I cannot be cast to
[[[Ljava.lang.Number;
        at array.main(array.java:6)

I get:

(SIGSEGV)
#9  <signal handler called>
#10 0x000000000049183d in builtin_descriptorscompatible (desc=0xc05010, target=0xc05df0)
    at builtin.c:485
#11 0x0000000000491914 in builtin_fast_arraycheckcast (o=0x67aa80, targetclass=0x69eea0)
    at builtin.c:530
#12 0x00002aaaab72f914 in ?? ()

Comment #1 by twisti@complang.tuwien.ac.at on 2008-05-03 10:36:57

Could you please add a JUnit test for this bug?

Comment #2 by stefan@complang.tuwien.ac.at on 2008-05-03 18:00:31

Done.

Comment #3 by stefan@complang.tuwien.ac.at on 2008-05-11 10:26:11

Seems ok with rev 4436cc114a77.