Skip to content

Conversation

@nikitalita
Copy link
Contributor

@nikitalita nikitalita commented Mar 11, 2025

Many C++ projects have their own memory management systems. This is especially the case for games (which often have their own scripting system, which would like to make use of a DAP library to debug them). Often times these games will redefine free via a macro to invoke their own memory mangement functions. If free() gets defined as a macro, attempting to compile any.h will cause the compiler to explode.

I note that this is a private function that is only used within any.h and it's only used twice, so this should not create any API compatibility issues.

Many C++ projects that have their own memory management systems. This is especially the case for games (which often have their own scripting system, which would like to make use of a DAP library to debug them). Often times these games will redefine `free` via a macro to invoke their own memory mangement functions. If `free()` gets defined as a macro, attempting to compile `any.h` will cause the compiler to explode.

I note that this is a private function that is only used within `any.h` and it's only used twice, so this should not create any API compatibility issues.
@nikitalita
Copy link
Contributor Author

@dneto0 any chance of this being merged?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant