javac should fail early when emitting illegal signature attributes

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P3
    • 11
    • Affects Version/s: 8, 9, 10, 11
    • Component/s: tools
    • b15
    • Verified

        Code like this:

        class Outer<X> {
           class Inner { }

           void test(Outer<?> outer) {
              outer.new Inner() { };
           }
        }

        Makes javac generate bad signature attributes:

        class Outer$1 extends Outer<<captured wildcard>>.Inner {
          final Outer this$0;
          Outer$1(Outer, Outer);
        }

        Javac should fail when generating code that is guaranteed to fail at verify.


              Assignee:
              Maurizio Cimadamore
              Reporter:
              Maurizio Cimadamore
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: