StackHelper.h 276 B

123456789101112131415161718
  1. #pragma once
  2. #include "../Common.h"
  3. NS_BF_BEGIN
  4. class StackHelper
  5. {
  6. public:
  7. StackHelper();
  8. bool CanStackExpand(int wantBytes = 32*1024);
  9. bool Execute(const std::function<void()>& func); // Can fail if the job thread overflows stack - must check result
  10. };
  11. NS_BF_END