[cvs] / jsr166 / src / main / java / util / PriorityQueue.java Repository:
ViewVC logotype

Diff of /jsr166/src/main/java/util/PriorityQueue.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.113, Wed Nov 30 03:31:47 2016 UTC revision 1.114, Wed Nov 30 18:12:52 2016 UTC
# Line 731  Line 731 
731       */       */
732      @SuppressWarnings("unchecked")      @SuppressWarnings("unchecked")
733      private void heapify() {      private void heapify() {
734          for (int i = (size >>> 1) - 1; i >= 0; i--)          final Object[] es = queue;
735              siftDown(i, (E) queue[i]);          final int half = (size >>> 1) - 1;
736            if (comparator == null)
737                for (int i = half; i >= 0; i--)
738                    siftDownComparable(i, (E) es[i]);
739            else
740                for (int i = half; i >= 0; i--)
741                    siftDownUsingComparator(i, (E) es[i]);
742      }      }
743    
744      /**      /**

Legend:
Removed from v.1.113  
changed lines
  Added in v.1.114

Doug Lea
ViewVC Help
Powered by ViewVC 1.0.8