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

◆ swap()

void fl::Str::swap ( Str & other)

Definition at line 245 of file str.cpp.

245 {
246 if (this != &other) {
247 fl::swap(mLength, other.mLength);
248 char temp[FASTLED_STR_INLINED_SIZE];
250 memcpy(mInlineData, other.mInlineData, FASTLED_STR_INLINED_SIZE);
251 memcpy(other.mInlineData, temp, FASTLED_STR_INLINED_SIZE);
252 fl::swap(mHeapData, other.mHeapData);
253 }
254}
void swap(array< T, N > &lhs, array< T, N > &rhs) noexcept(noexcept(lhs.swap(rhs)))
Definition array.h:140
#define FASTLED_STR_INLINED_SIZE
Definition str.h:14

References Str(), FASTLED_STR_INLINED_SIZE, fl::StrN< SIZE >::mHeapData, fl::StrN< FASTLED_STR_INLINED_SIZE >::mHeapData, fl::StrN< SIZE >::mInlineData, fl::StrN< FASTLED_STR_INLINED_SIZE >::mInlineData, fl::StrN< SIZE >::mLength, fl::StrN< FASTLED_STR_INLINED_SIZE >::mLength, and fl::swap().

+ Here is the call graph for this function: