Bug un tableswitch

Maxim Kizub max at immsp.kiev.ua
Mon Jan 25 14:33:19 PST 1999


Here is a test src:

public class Test {

        public static void main(String[] args) {
                int i = 0x7fffffff;
                System.out.println("switch("+i+")");
                switch(i) {
                case -1: System.out.println("-1"); break;
                case 0: System.out.println("0"); break;
                case 1: System.out.println("1"); break;
                default: System.out.println("default"); break;
                }
        }

}

> javac Test.java
> java Test
switch(2147483647)
default

> kaffe Test
switch(2147483647)
-1


There's something wring in tableswitch generation.

PS Linux x86, RedHat 5.1

Regards
  Maxim Kizub


More information about the kaffe mailing list