FastLED 3.9.15
Loading...
Searching...
No Matches

◆ push_heap() [2/2]

template<typename Iterator, typename Compare>
void fl::push_heap ( Iterator first,
Iterator last,
Compare comp )

Definition at line 33 of file priority_queue.h.

33 {
34 auto pos = last - 1;
35 auto parent = first + ((pos - first) - 1) / 2;
36
37 while (pos > first && comp(*parent, *pos)) {
38 auto tmp = *parent;
39 *parent = *pos;
40 *pos = tmp;
41
42 pos = parent;
43 parent = first + ((pos - first) - 1) / 2;
44 }
45}
uint8_t pos
Definition Blur.ino:11

References pos.

Referenced by fl::PriorityQueue< T, Compare, VectorT >::push(), and push_heap().

+ Here is the caller graph for this function: