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

generics: assertion error using Arrays.fill

XMLWordPrintable

    • mantis
    • generic
    • solaris_8

      frog:~/gjc-work/generics.ws/TEST $ cat -n Bug.java
           1
           2 public class Bug
           3 {
           4
           5 public static <E> void bug(E[] a, E e)
           6 {
           7 java.util.Arrays.fill(a, 0, 100, e);
           8 }
           9
          10 }
          11
      frog:~/gjc-work/generics.ws/TEST $ newjavac -gj Bug.java
      An exception has occurred in the compiler (1.4.0-rc). 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.AssertionError
              at com.sun.tools.javac.v8.code.Symbol$TypeSymbol.precedes(Symbol.java:351)
              at com.sun.tools.javac.v8.comp.Infer.insert(Infer.java:80)
              at com.sun.tools.javac.v8.comp.Infer.closure(Infer.java:67)
              at com.sun.tools.javac.v8.comp.Infer.lub(Infer.java:172)
              at com.sun.tools.javac.v8.comp.Infer.minimizeInst(Infer.java:342)
              at com.sun.tools.javac.v8.comp.Infer.instantiateMethod(Infer.java:406)
              at com.sun.tools.javac.v8.comp.Resolve.instantiate(Resolve.java:270)
              at com.sun.tools.javac.v8.comp.Resolve.findMethod(Resolve.java:472)
              at com.sun.tools.javac.v8.comp.Resolve.resolveQualifiedMethod(Resolve.java:914)
              at com.sun.tools.javac.v8.comp.Attr.selectSym(Attr.java:1545)
              at com.sun.tools.javac.v8.comp.Attr.visitSelect(Attr.java:1469)
              at com.sun.tools.javac.v8.tree.Tree$Select.accept(Tree.java:906)
              at com.sun.tools.javac.v8.comp.Attr.attribTree(Attr.java:288)
      ...

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

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: