X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7beafee9423f4cfa2fb08c8c5ff579f884314c79..9869c26285dc51d13607cddaa04f65ce983653a5:/include/wx/msw/stackwalk.h diff --git a/include/wx/msw/stackwalk.h b/include/wx/msw/stackwalk.h index b003181bc8..6ff467205e 100644 --- a/include/wx/msw/stackwalk.h +++ b/include/wx/msw/stackwalk.h @@ -4,7 +4,6 @@ // Author: Vadim Zeitlin // Modified by: // Created: 2005-01-08 -// RCS-ID: $Id$ // Copyright: (c) 2005 Vadim Zeitlin // Licence: wxWindows licence /////////////////////////////////////////////////////////////////////////////// @@ -12,6 +11,8 @@ #ifndef _WX_MSW_STACKWALK_H_ #define _WX_MSW_STACKWALK_H_ +#include "wx/arrstr.h" + // these structs are declared in windows headers struct _CONTEXT; struct _EXCEPTION_POINTERS; @@ -27,7 +28,7 @@ class WXDLLIMPEXP_BASE wxStackFrame : public wxStackFrameBase { private: wxStackFrame *ConstCast() const - { return wx_const_cast(wxStackFrame *, this); } + { return const_cast(this); } size_t DoGetParamCount() const { return m_paramTypes.GetCount(); } @@ -63,7 +64,7 @@ protected: // helper for debug API: it wants to have addresses as DWORDs size_t GetSymAddr() const { - return wx_reinterpret_cast(size_t, m_address); + return reinterpret_cast(m_address); } private: @@ -84,15 +85,19 @@ private: class WXDLLIMPEXP_BASE wxStackWalker : public wxStackWalkerBase { public: - wxStackWalker() { } + // we don't use ctor argument, it is for compatibility with Unix version + // only + wxStackWalker(const char * WXUNUSED(argv0) = NULL) { } - virtual void Walk(size_t skip = 1); - virtual void WalkFromException(); + virtual void Walk(size_t skip = 1, size_t maxDepth = wxSTACKWALKER_MAX_DEPTH); +#if wxUSE_ON_FATAL_EXCEPTION + virtual void WalkFromException(size_t maxDepth = wxSTACKWALKER_MAX_DEPTH); +#endif // wxUSE_ON_FATAL_EXCEPTION // enumerate stack frames from the given context - void WalkFrom(const _CONTEXT *ctx, size_t skip = 1); - void WalkFrom(const _EXCEPTION_POINTERS *ep, size_t skip = 1); + void WalkFrom(const _CONTEXT *ctx, size_t skip = 1, size_t maxDepth = wxSTACKWALKER_MAX_DEPTH); + void WalkFrom(const _EXCEPTION_POINTERS *ep, size_t skip = 1, size_t maxDepth = wxSTACKWALKER_MAX_DEPTH); }; #endif // _WX_MSW_STACKWALK_H_