bit::memory
|
A block allocator that only distributes null blocks. More...
#include <null_block_allocator.hpp>
Public Types | |
using | default_block_alignment = std::integral_constant< std::size_t, 1 > |
Public Member Functions | |
null_block_allocator ()=default | |
Default-constructs a null_block_allocator. | |
null_block_allocator (null_block_allocator &&other) noexcept=default | |
Move-constructs a null_block_allocator from another allocator. More... | |
null_block_allocator (const null_block_allocator &other) noexcept=default | |
Copy-constructs a null_block_allocator from another allocator. More... | |
null_block_allocator & | operator= (null_block_allocator &&other) noexcept=default |
Move-assigns a null_block_allocator from another allocator. More... | |
null_block_allocator & | operator= (const null_block_allocator &other) noexcept=default |
Copy-assigns a null_block_allocator from another allocator. More... | |
owner< memory_block > | allocate_block () noexcept |
Allocates a null memory_block. More... | |
void | deallocate_block (owner< memory_block > block) noexcept |
Deallocates a memory_block. More... | |
std::size_t | next_block_size () const noexcept |
Queries the next block size expected from this allocator. More... | |
allocator_info | info () const noexcept |
Gets the info about this allocator. More... | |
A block allocator that only distributes null blocks.
Definition at line 55 of file null_block_allocator.hpp.
|
defaultnoexcept |
Move-constructs a null_block_allocator from another allocator.
other | the other null_block_allocator to move |
|
defaultnoexcept |
Copy-constructs a null_block_allocator from another allocator.
other | the other null_block_allocator to copy |
|
noexcept |
Allocates a null memory_block.
|
noexcept |
Deallocates a memory_block.
block | the block to deallocate |
|
noexcept |
Gets the info about this allocator.
This defaults to 'null_block_allocator'. Use a named_null_block_allocator to override this
|
noexcept |
Queries the next block size expected from this allocator.
|
defaultnoexcept |
Move-assigns a null_block_allocator from another allocator.
other | the other null_block_allocator to move |
(*this)
|
defaultnoexcept |
Copy-assigns a null_block_allocator from another allocator.
other | the other null_block_allocator to copy |
(*this)