Default memory allocator using allocators utilities.
More...
#include <allocator.h>
|
TYPE * | allocate (u_integer size) override |
| Allocates memory using global operator new.
|
|
void | deallocate (TYPE *ptr, u_integer size) override |
| Deallocates memory using global operator delete.
|
|
constexpr | allocatorBase () |
| Constructs a new allocatorBase instance.
|
|
void | construct (O_TYPE *o_ptr, Args &&... args) |
| Constructs an object in allocated memory.
|
|
virtual | ~allocatorBase ()=0 |
| Virtual destructor.
|
|
|
using | propagate_on_container_copy_assignment |
| No propagation on copy.
|
|
using | propagate_on_container_move_assignment |
| No propagation on move.
|
|
using | propagate_on_container_swap |
| No propagation on swap.
|
|
using | propagate_on_container_merge |
| No propagation on merge.
|
|
using | rebind_alloc |
| Rebinds allocator to different type.
|
|
static void | destroy (O_TYPE *o_ptr) |
| Destroys an object without deallocating.
|
|
template<typename TYPE>
class original::allocator< TYPE >
Default memory allocator using allocators utilities.
- Template Parameters
-
TYPE | Type of objects to allocate |
Implements standard-compliant allocator using:
- Examples
- D:/FrozenLemonTee/Arbeit/PracticeProject/original/src/core/vector.h.
◆ allocate()
Allocates memory using global operator new.
- Parameters
-
size | Number of elements to allocate |
- Returns
- Pointer to allocated memory
- Exceptions
-
- Note
- Returns nullptr if size is 0
Implements original::allocatorBase< TYPE, allocator >.
◆ deallocate()
The documentation for this class was generated from the following file: