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

◆ push_back()

template<typename T, size_t INLINED_SIZE>
void fl::InlinedVector< T, INLINED_SIZE >::push_back ( const T & value)
inline

Definition at line 919 of file vector.h.

919 {
920 if (!mUsingHeap) {
921 if (mFixed.size() < INLINED_SIZE) {
922 mFixed.push_back(value);
923 return;
924 }
925 // overflow: move inline data into heap
926 mHeap.reserve(INLINED_SIZE * 2);
927 for (auto &v : mFixed) {
928 mHeap.push_back(v);
929 }
930 mFixed.clear();
931 mUsingHeap = true;
932 }
933 mHeap.push_back(value);
934 }
HeapVector< T > mHeap
Definition vector.h:1025
FixedVector< T, INLINED_SIZE > mFixed
Definition vector.h:1024

References mFixed, mHeap, and mUsingHeap.

Referenced by loop(), and anonymous_namespace{xypaths.cpp}::make_path().

+ Here is the caller graph for this function: