Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-2953

PriorityQueue is inheriently broken if subclass attempts to use "heap" w/generic T bound to anything other then "Object"

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.2, 4.0-ALPHA
    • Component/s: None
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      as discovered in SOLR-2410 the fact that the protected "heap" variable in PriorityQueue is initialized using an Object[] makes it impossible for subclasses of PriorityQueue to exist and access the "heap" array unless they bind the generic to Object.

        Attachments

        1. LUCENE-2953.patch
          1 kB
          Hoss Man
        2. LUCENE-2953.patch
          18 kB
          Uwe Schindler
        3. BenchmarkArrayAccess.java
          3 kB
          Dawid Weiss

          Issue Links

            Activity

              People

              • Assignee:
                thetaphi Uwe Schindler
                Reporter:
                hossman Hoss Man
              • Votes:
                1 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: