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

javac assertion error when compiling overlay sources

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 9
    • 9
    • tools
    • b139
    • generic
    • generic
    • Verified

      When compiling overlay sources such as for jsr166 the compiler crashes with this stack trace, instead javac should display a suitable error and fail gracefully. A reproducer attached.

      An exception has occurred in the compiler (9-internal). Please file a bug against the Java compiler via the Java bug reporting page (http://bugreport.java.com) after checking the Bug Database (http://bugs.java.com) for duplicates. Include your program and the following diagnostic in your report. Thank you.
      java.lang.AssertionError
      at com.sun.tools.javac.util.Assert.error(jdk.compiler@9-internal/Assert.java:155)
      at com.sun.tools.javac.util.Assert.checkNull(jdk.compiler@9-internal/Assert.java:54)
      at com.sun.tools.javac.code.Symtab.enterModule(jdk.compiler@9-internal/Symtab.java:753)
      at com.sun.tools.javac.comp.Modules.enterModule(jdk.compiler@9-internal/Modules.java:257)
      at com.sun.tools.javac.comp.Modules.enterModules(jdk.compiler@9-internal/Modules.java:235)
      at com.sun.tools.javac.comp.Modules.enter(jdk.compiler@9-internal/Modules.java:203)
      at com.sun.tools.javac.main.JavaCompiler.readSourceFile(jdk.compiler@9-internal/JavaCompiler.java:816)
      at com.sun.tools.javac.main.JavaCompiler.readSourceFile(jdk.compiler@9-internal/JavaCompiler.java:778)
      at com.sun.tools.javac.main.JavaCompiler.access$100(jdk.compiler@9-internal/JavaCompiler.java:97)
      at com.sun.tools.javac.main.JavaCompiler$1.complete(jdk.compiler@9-internal/JavaCompiler.java:339)
      at com.sun.tools.javac.code.ClassFinder.fillIn(jdk.compiler@9-internal/ClassFinder.java:362)
      at com.sun.tools.javac.code.ModuleFinder.lambda$findSingleModule$0(jdk.compiler@9-internal/ModuleFinder.java:206)
      at com.sun.tools.javac.code.Symbol.complete(jdk.compiler@9-internal/Symbol.java:601)
      at com.sun.tools.javac.comp.Modules.setCompilationUnitModules(jdk.compiler@9-internal/Modules.java:361)
      at com.sun.tools.javac.comp.Modules.enter(jdk.compiler@9-internal/Modules.java:205)
      at com.sun.tools.javac.main.JavaCompiler.initModules(jdk.compiler@9-internal/JavaCompiler.java:1020)
      at com.sun.tools.javac.main.JavaCompiler.initModules(jdk.compiler@9-internal/JavaCompiler.java:1012)
      at com.sun.tools.javac.main.JavaCompiler.compile(jdk.compiler@9-internal/JavaCompiler.java:906)
      at com.sun.tools.javac.main.Main.compile(jdk.compiler@9-internal/Main.java:261)
      at com.sun.tools.javac.main.Main.compile(jdk.compiler@9-internal/Main.java:143)
      at com.sun.tools.javac.Main.compile(jdk.compiler@9-internal/Main.java:55)
      at com.sun.tools.javac.Main.main(jdk.compiler@9-internal/Main.java:41)

            jlahoda Jan Lahoda
            ksrini Kumar Srinivasan
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: