util/DynamicFifoBuffer: add nullptr constructor overload

This commit is contained in:
Max Kellermann 2019-08-16 13:21:28 +02:00
parent a82d61a5e4
commit 1550113506

View File

@ -45,6 +45,12 @@ public:
using typename ForeignFifoBuffer<T>::const_pointer_type;
using typename ForeignFifoBuffer<T>::Range;
/**
* Construct without allocating a buffer.
*/
explicit constexpr DynamicFifoBuffer(std::nullptr_t n) noexcept
:ForeignFifoBuffer<T>(n) {}
/**
* Allocate a buffer with the given capacity.
*/