MCPcopy Create free account
hub / github.com/GameTechDev/PresentMon / ToString

Method ToString

IntelPresentMon/CommonUtilities/log/StackTrace.cpp:57–72  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

55 return !frames_.empty();
56 }
57 std::string StackTrace::ToString() const
58 {
59 std::ostringstream oss;
60 if (Resolved()) {
61 for (auto& f : GetFrames()) {
62 oss << " [" << f.index << "] " << f.description << "\n";
63 if (f.line != 0 || !f.file.empty()) {
64 oss << " > " << f.file << '(' << f.line << ")\n";
65 }
66 }
67 }
68 else {
69 oss << "\n !! UNRESOLVED STACK TRACE !!\n\n";
70 }
71 return oss.str();
72 }
73 std::unique_ptr<StackTrace> StackTrace::Here(size_t skip)
74 {
75 return std::make_unique<StackTrace>(std::stacktrace::current(skip));

Callers 7

GetTraceStringMethod · 0.45
FormatMethod · 0.45
SubmitMethod · 0.45
CreateMethod · 0.45
OpenMethod · 0.45
operator[]Method · 0.45

Calls 1

emptyMethod · 0.80

Tested by

no test coverage detected