acme
Foundational cross-platform layer of the ca2 framework
Toggle main menu visibility
Loading...
Searching...
No Matches
quantum.h
1
// Created by camilo on 2024-09-01 20:10 <3ThomasBorregaardSorensen!! ThomasMonth?ThomasLikes5?
2
#pragma once
3
4
5
#include "acme/memory/memory_allocate.h"
6
7
8
class
memory_quantum
9
{
10
public
:
11
12
13
memory_quantum()
14
{
15
16
17
}
18
19
20
~memory_quantum()
21
{
22
23
24
}
25
26
27
void
*
operator
new
(
size_t
s)
28
{
29
30
auto
p = ::memory_allocate(s);
31
32
#if REFERENCING_DEBUGGING
33
34
::allocator::__on_start_construct(p, s,
true
);
35
36
#endif
37
38
return
p;
39
40
}
41
42
43
44
void
*
operator
new
[](
size_t
s)
45
{
46
47
return ::memory_allocate(s);
48
49
}
50
51
52
void
operator
delete
(
void
*p)
53
{
54
55
return ::memory_free(p);
56
57
}
58
59
60
void
operator
delete
[](
void
*p)
61
{
62
63
return ::memory_free(p);
64
65
}
66
67
68
};
69
70
71
memory
quantum.h
Generated by
1.17.0