darray: add 'remain' query
This commit is contained in:
parent
85a736b9f4
commit
7e8f2df869
@ -87,6 +87,7 @@ namespace cruft {
|
|||||||
|
|
||||||
std::size_t size (void) const noexcept { return m_size; }
|
std::size_t size (void) const noexcept { return m_size; }
|
||||||
constexpr auto capacity (void) const noexcept { return CapacityV; }
|
constexpr auto capacity (void) const noexcept { return CapacityV; }
|
||||||
|
constexpr auto remain (void) const noexcept { return capacity () - size (); }
|
||||||
|
|
||||||
constexpr bool empty (void) const noexcept { return !!m_size; }
|
constexpr bool empty (void) const noexcept { return !!m_size; }
|
||||||
constexpr bool full (void) const noexcept { return m_size == CapacityV; }
|
constexpr bool full (void) const noexcept { return m_size == CapacityV; }
|
||||||
|
Loading…
Reference in New Issue
Block a user