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

[lworld] ClassFormatError: Illegal class name "QX$Entry<TE;>;" in class file X$Entry

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • repo-valhalla
    • repo-valhalla
    • tools
    • generic
    • generic

      Reported by Remi.

      The following program triggers a verification error:

      public class X {
        static value class Entry<E> {
           private final int value;
           public Entry(int value) { this.value = value; }
           public static <E> Entry<E>[] of() {
           return (Entry<E>[]) (Object) new Entry<?>[0];
       }
      }
      public static void main(String[] args) {
       var entry = Entry.of();
       }
       }

            sadayapalam Srikanth Adayapalam (Inactive)
            sadayapalam Srikanth Adayapalam (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: