Address review: restore CHAISCRIPT_DEBUG to true/false for stronger typing

C++ preserves the true/false keywords in #if directives ([cpp.cond]),
so the MSVC Debug guard around CHAISCRIPT_MAX_CALL_DEPTH still works
without weakening the macro to integer 1/0.

Requested by @lefticus in PR #700 review.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
leftibot 2026-05-02 11:09:09 -06:00
parent bd6fd1f237
commit 1d354e11c8

View File

@ -70,9 +70,9 @@ static_assert(_MSC_FULL_VER >= 190024210, "Visual C++ 2015 Update 3 or later req
#endif #endif
#ifdef _DEBUG #ifdef _DEBUG
#define CHAISCRIPT_DEBUG 1 #define CHAISCRIPT_DEBUG true
#else #else
#define CHAISCRIPT_DEBUG 0 #define CHAISCRIPT_DEBUG false
#endif #endif
// Upper bound on the depth of nested ChaiScript function calls. Hitting it // Upper bound on the depth of nested ChaiScript function calls. Hitting it