MCPcopy Create free account
hub / github.com/boostorg/stacktrace / get_address_from_frame

Function get_address_from_frame

test/test.cpp:274–290  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

272}
273
274uintptr_t get_address_from_frame(const std::string& frame) {
275 std::size_t address = 0;
276 std::string hex_address;
277 std::size_t pos = frame.find("0x");
278
279 if (pos != std::string::npos) {
280 // Extract the hex address substring
281 hex_address = frame.substr(pos + 2); // Skip "0x"
282
283 // Convert hex string to std::size_t
284 std::stringstream ss;
285 ss << std::hex << hex_address;
286 ss >> address;
287 }
288
289 return address;
290}
291
292void test_relative_virtual_address(const char* file_path)
293{

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected