File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -445,11 +445,11 @@ siftup_max(PyListObject *heap, Py_ssize_t pos)
445445 return -1 ;
446446 }
447447
448- /* Bubble up the smaller child until hitting a leaf. */
448+ /* Bubble up the larger child until hitting a leaf. */
449449 arr = _PyList_ITEMS (heap );
450450 limit = endpos >> 1 ; /* smallest pos that has no child */
451451 while (pos < limit ) {
452- /* Set childpos to index of smaller child. */
452+ /* Set childpos to index of larger child. */
453453 childpos = 2 * pos + 1 ; /* leftmost child position */
454454 if (childpos + 1 < endpos ) {
455455 PyObject * a = arr [childpos + 1 ];
@@ -469,7 +469,7 @@ siftup_max(PyListObject *heap, Py_ssize_t pos)
469469 return -1 ;
470470 }
471471 }
472- /* Move the smaller child up. */
472+ /* Move the larger child up. */
473473 tmp1 = arr [childpos ];
474474 tmp2 = arr [pos ];
475475 arr [childpos ] = tmp2 ;
You can’t perform that action at this time.
0 commit comments