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

◆ scoped_array2() [1/3]

template<typename T, typename Alloc = fl::allocator<T>>
fl::scoped_array2< T, Alloc >::scoped_array2 ( fl::size_t size = 0)
inlineexplicit

Definition at line 99 of file scoped_array.h.

100 : arr_(nullptr), size_(size) {
101 if (size > 0) {
102 arr_ = mAlloc.allocate(size);
103 // Default initialize each element
104 for (fl::size_t i = 0; i < size; ++i) {
105 mAlloc.construct(&arr_[i]);
106 }
107 }
108 }
fl::size_t size() const

References arr_, mAlloc, size(), and size_.

Referenced by scoped_array2(), scoped_array2(), operator=(), operator=(), and swap().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: