This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
gcj front end bug
- From: Tom Tromey <tromey at redhat dot com>
- To: Java Discuss List <java at gcc dot gnu dot org>
- Cc: Per Bothner <per at bothner dot com>
- Date: 08 Dec 2001 20:33:31 -0700
- Subject: gcj front end bug
- Reply-to: tromey at redhat dot com
The appended program compiles with gcj, but it shouldn't.
I'm guessing this is a bug in the definite assignment code.
I found this because the gij verifier rejects the bytecode we generate
in this case; it actually is invalid.
Tom
public class t
{
public static String foo (int z)
{
String ibo;
switch (z)
{
case 1:
ibo = "least";
break;
case 2:
ibo = "most";
}
return ibo;
}
public static void main (String[] args)
{
System.out.println (foo (args.length));
}
}