#include <cstddef>
#include <cstdint>
-namespace folly { namespace exception_tracer {
+namespace folly {
+namespace exception_tracer {
constexpr size_t kMaxFrames = 500;
struct StackTrace {
- StackTrace() : frameCount(0) { }
+ StackTrace() : frameCount(0) {}
size_t frameCount;
uintptr_t addresses[kMaxFrames];
// A StackTraceStack MUST be placed in zero-initialized memory.
class StackTraceStack {
class Node;
+
public:
/**
* Push the current stack trace onto the stack.
/**
* Is the stack empty?
*/
- bool empty() const { return !top_; }
+ bool empty() const {
+ return !top_;
+ }
/**
* Return the top stack trace, or nullptr if the stack is empty.
uintptr_t guard2_;
#endif
};
-
-}} // namespaces
+} // namespace exception_tracer
+} // namespace folly