mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-04-22 10:50:58 +00:00
dap: rename free method to freeValue to avoid running afoul of macro defs
This commit is contained in:
parent
b920ff86ce
commit
ccf3698776
1 changed files with 3 additions and 3 deletions
|
@ -67,7 +67,7 @@ class any {
|
|||
|
||||
static inline void* alignUp(void* val, size_t alignment);
|
||||
inline void alloc(size_t size, size_t align);
|
||||
inline void free();
|
||||
inline void freeValue();
|
||||
inline bool isInBuffer(void* ptr) const;
|
||||
|
||||
void* value = nullptr;
|
||||
|
@ -106,7 +106,7 @@ any::any(any&& other) noexcept : type(other.type) {
|
|||
void any::reset() {
|
||||
if (value != nullptr) {
|
||||
type->destruct(value);
|
||||
free();
|
||||
freeValue();
|
||||
}
|
||||
value = nullptr;
|
||||
type = nullptr;
|
||||
|
@ -191,7 +191,7 @@ void any::alloc(size_t size, size_t align) {
|
|||
value = alignUp(heap, align);
|
||||
}
|
||||
|
||||
void any::free() {
|
||||
void any::freeValue() {
|
||||
assert(value != nullptr);
|
||||
if (heap != nullptr) {
|
||||
delete[] reinterpret_cast<uint8_t*>(heap);
|
||||
|
|
Loading…
Reference in a new issue