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
This commit is contained in:
parent
37c67319e1
commit
f192590a79
3 changed files with 43 additions and 0 deletions
|
@ -1,3 +1,7 @@
|
|||
2000-05-29 Bryce McKinlay <bryce@albatross.co.nz>
|
||||
|
||||
* libjava.lang/PR242.java: New file. PR gcj/242.
|
||||
|
||||
2000-05-23 Tom Tromey <tromey@cygnus.com>
|
||||
|
||||
* libjava.compile/PR238.java: New file. For PR gcj/238.
|
||||
|
|
36
libjava/testsuite/libjava.lang/PR242.java
Normal file
36
libjava/testsuite/libjava.lang/PR242.java
Normal file
|
@ -0,0 +1,36 @@
|
|||
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());
|
||||
}
|
||||
}
|
||||
}
|
3
libjava/testsuite/libjava.lang/PR242.out
Normal file
3
libjava/testsuite/libjava.lang/PR242.out
Normal file
|
@ -0,0 +1,3 @@
|
|||
...
|
||||
ok
|
||||
0
|
Loading…
Add table
Reference in a new issue