gcc/libjava/testsuite/libjava.lang/PR242.java
Bryce McKinlay f192590a79 re GNATS gcj/242 (Compiler generates call to wrong method from inner class)
2000-05-29  Bryce McKinlay  <bryce@albatross.co.nz>

	* libjava.lang/PR242.java: New file. PR gcj/242.

From-SVN: r34245
2000-05-29 06:26:14 +01:00

37 lines
472 B
Java

class Base
{
int someNum()
{
System.out.println ("ok");
return 0;
}
}
public class PR242 extends Base
{
public static void main(String args[])
{
new PR242();
}
PR242()
{
new Inner().a();
}
class Inner
{
public int dummy()
{
System.out.println ("wrong method called!!");
return -1;
}
public void a()
{
System.out.println ("...");
System.out.println (someNum());
}
}
}