X-Git-Url: http://git.tdb.fi/?p=libs%2Fcore.git;a=blobdiff_plain;f=source%2Fdebug%2Fbacktrace.h;h=98aa4d8cdd9736291253cecf403b10d75bf43b2a;hp=66e36f35cfa3637c8b52b497a9d84a4b47dce87d;hb=HEAD;hpb=b56eb5ec1da675da0c66abc53c1e4f6c4e4cccbd diff --git a/source/debug/backtrace.h b/source/debug/backtrace.h index 66e36f3..b8e06af 100644 --- a/source/debug/backtrace.h +++ b/source/debug/backtrace.h @@ -1,41 +1,35 @@ -/* $Id$ - -This file is part of libmspcore -Copyright © 2007 Mikko Rasa, Mikkosoft Productions -Distributed under the LGPL -*/ - #ifndef MSP_DEBUG_BACKTRACE_H_ #define MSP_DEBUG_BACKTRACE_H_ -#include #include #include +#include +#include namespace Msp { namespace Debug { -class Backtrace +class MSPCORE_API Backtrace { public: struct StackFrame { - void *address; + void *address = nullptr; std::string file; std::string symbol; }; private: - std::list frames; + std::vector frames; public: - const std::list &get_frames() const { return frames; } + const std::vector &get_frames() const { return frames; } static Backtrace create(); }; -std::ostream &operator<<(std::ostream &, const Backtrace &); -std::ostream &operator<<(std::ostream &, const Backtrace::StackFrame &); +MSPCORE_API std::ostream &operator<<(std::ostream &, const Backtrace &); +MSPCORE_API std::ostream &operator<<(std::ostream &, const Backtrace::StackFrame &); } // namespace Debug } // namespace Msp