- `addrToHex` - formats an address as a hexadecimal sring - `constAddrToHex` - const variant of `addrToHex`
9 lines
291 B
C++
9 lines
291 B
C++
#include "include/public/toon_boom/ext/util.hpp"
|
|
|
|
std::string addrToHex(void* addr) {
|
|
return std::format("0x{:010X}", reinterpret_cast<uintptr_t>(addr));
|
|
}
|
|
|
|
std::string constAddrToHex(const void* addr) {
|
|
return std::format("0x{:010X}", reinterpret_cast<const uintptr_t>(addr));
|
|
} |