-
Bug
-
Resolution: Fixed
-
P3
-
6u26
-
b08
-
x86
-
linux
-
Verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2213438 | 8 | Maurizio Cimadamore | P4 | Closed | Fixed | b06 |
JDK-2213636 | 7-pool | Dmeetry Degrave | P3 | Closed | Cannot Reproduce |
FULL PRODUCT VERSION :
javac 1.6.0_20
ADDITIONAL OS VERSION INFORMATION :
Linux 2.6.18-238.19.1.el5 #1 SMP x86_64 GNU/Linux
A DESCRIPTION OF THE PROBLEM :
javac hangs when compiling a class C, which references a class A that suffers from cyclic inheritance.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Create a directory "A_extends_B" containing A.java and B.java as below.
-----------------------------------
public class A extends B
{
}
-----------------------------------
public class B
{
}
-----------------------------------
2) Compile the classes.
3) Create a directory "B_extends_A" containing A.java and B.java as below:
-----------------------------------
public class A
{
}
-----------------------------------
public class B extends A
{
}
-----------------------------------
4) Compile the classes.
5) Create a directory "circular_inheritance" containing C.java as below:
-----------------------------------
public class C
{
A a = new A();
}
-----------------------------------
6) Copy A_extends_B/A.class and B_extends_A/B.class to circular_inheritance.
7) Compile C.java
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
An error.
ACTUAL -
javac hangs indefinitely.
REPRODUCIBILITY :
This bug can be reproduced always.
javac 1.6.0_20
ADDITIONAL OS VERSION INFORMATION :
Linux 2.6.18-238.19.1.el5 #1 SMP x86_64 GNU/Linux
A DESCRIPTION OF THE PROBLEM :
javac hangs when compiling a class C, which references a class A that suffers from cyclic inheritance.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Create a directory "A_extends_B" containing A.java and B.java as below.
-----------------------------------
public class A extends B
{
}
-----------------------------------
public class B
{
}
-----------------------------------
2) Compile the classes.
3) Create a directory "B_extends_A" containing A.java and B.java as below:
-----------------------------------
public class A
{
}
-----------------------------------
public class B extends A
{
}
-----------------------------------
4) Compile the classes.
5) Create a directory "circular_inheritance" containing C.java as below:
-----------------------------------
public class C
{
A a = new A();
}
-----------------------------------
6) Copy A_extends_B/A.class and B_extends_A/B.class to circular_inheritance.
7) Compile C.java
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
An error.
ACTUAL -
javac hangs indefinitely.
REPRODUCIBILITY :
This bug can be reproduced always.
- backported by
-
JDK-2213636 javac hangs when compiling a class that references a cyclically inherited class
- Closed
-
JDK-2213438 javac hangs when compiling a class that references a cyclically inherited class
- Closed
- relates to
-
JDK-6663588 Compiler goes into infinite loop for Cyclic Inheritance test case
- Closed
-
JDK-7024568 Very long method resolution causing OOM error
- Closed