00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00018 #ifndef LIBCWD_PRIVATE_DEBUG_STACK_H
00019 #define LIBCWD_PRIVATE_DEBUG_STACK_H
00020
00021 #ifndef LIBCWD_CONFIG_H
00022 #include <libcwd/config.h>
00023 #endif
00024 #ifndef LIBCW_CSTDDEF
00025 #define LIBCW_CSTDDEF
00026 #include <cstddef>
00027 #endif
00028
00029 namespace libcwd {
00030 namespace _private_ {
00031
00032
00033
00034
00035 template<typename T>
00036 struct debug_stack_tst {
00037 private:
00038 T st[64];
00039 T* p;
00040 T* end;
00041 public:
00042 void init(void);
00043 void push(T ptr);
00044 void pop(void);
00045 T top(void) const;
00046 size_t size(void) const;
00047 };
00048
00049 }
00050 }
00051
00052 #endif // LIBCWD_PRIVATE_DEBUG_STACK_H