Divide Framework 0.1
A free and open-source 3D Framework under heavy development
Loading...
Searching...
No Matches
StackAllocator.h
Go to the documentation of this file.
1/*
2 Author : Tobias Stein
3 Date : 22nd October, 2016
4 File : StackAllocator.h
5
6 Stack allocator.
7
8 All Rights Reserved. (c) Copyright 2016.
9*/
10
11#pragma once
12#ifndef ECS__STACK_ALLOC_H__
13#define ECS__STACK_ALLOC_H__
14
16
17namespace ECS { namespace Memory { namespace Allocator {
18
19 /*
20 */
22 {
23 private:
24
26 {
28 };
29
30 public:
31
32 StackAllocator(size_t memSize, const void* mem);
33
34 virtual ~StackAllocator() override;
35
36 virtual void* allocate(size_t size, u8 alignment) override;
37 virtual void free(void* p) override;
38 virtual void clear() override;
39
40 }; // class StackAllocator
41
42} } } // namespace ECS::Memory::Allocator
43
44#endif // ECS__STACK_ALLOC_H__
#define ECS_API
Definition: Platform.h:16
uint8_t u8
Definition: Platform.h:49