Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4500240

javac throws StackOverflowError for recursive inheritance

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      hopper
    • CPU:
      generic
    • OS:
      generic
    • Verification:
      Verified

      Description



      Name: skR10005 Date: 09/06/2001


      The javac throws StackOverflowError for the following code:
      ====================A.java==================
      interface B {
      }
      interface A extends B {
      }
      ====================B.java==================
      interface B extends A {
      }
      ============================================
      $javac -J-version
      java version "1.4.0-beta3"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta3-b78)
      Java HotSpot(TM) Client VM (build 1.4.0-beta3-b78, mixed mode)
      $javac -d . A.java
      $javac -d . B.java
      An exception has occurred in the compiler (1.4.0-beta3). Please file a bug at the Java
      Developer Connection
      (http://java.sun.com/cgi-bin/bugreport.cgi) after checking the Bug Parade for duplicates.
      Include your program
      and the following diagnostic in your report. Thank you.
      java.lang.StackOverflowError
              at com.sun.tools.javac.v8.comp.Check.checkImplementations(Check.java:899)
              at com.sun.tools.javac.v8.comp.Check.checkImplementations(Check.java:900)
              ..........
              last line is repeated many times

      ======================================================================

        Attachments

          Activity

            People

            Assignee:
            gafter Neal Gafter
            Reporter:
            serjsunw Serj Serj (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: