Cleanup: move linear allocator description to class

This commit is contained in:
Jacques Lucke
2025-05-07 20:49:02 +02:00
parent 52a283a1ee
commit 3a2d4d151f

View File

@@ -4,10 +4,6 @@
/** \file
* \ingroup bli
*
* A linear allocator is the simplest form of an allocator. It never reuses any memory, and
* therefore does not need a deallocation method. It simply hands out consecutive buffers of
* memory. When the current buffer is full, it allocates a new larger buffer and continues.
*/
#pragma once
@@ -25,6 +21,11 @@ namespace blender {
*/
// #define BLI_DEBUG_LINEAR_ALLOCATOR_SIZE
/**
* A linear allocator is the simplest form of an allocator. It never reuses any memory, and
* therefore does not need a deallocation method. It simply hands out consecutive buffers of
* memory. When the current buffer is full, it allocates a new larger buffer and continues.
*/
template<typename Allocator = GuardedAllocator> class LinearAllocator : NonCopyable, NonMovable {
private:
BLI_NO_UNIQUE_ADDRESS Allocator allocator_;