ToyGine2 26.2.0
Game Engine for retro consoles
Loading...
Searching...
No Matches
assertion_stub.cpp File Reference

Stub definitions for the assertion callback API declared in core/assertion.hpp. More...

#include <cstdio>
#include "core.hpp"
Include dependency graph for assertion_stub.cpp:

Namespaces

namespace  toy
 Root namespace containing all engine modules.
namespace  toy::assertion
 Configurable assertion failure handling and optional stack trace.

Functions

void toy::assertion::initialize ()
 Prepares the assertion system; call before using assertion macros or setCallbacks().
void toy::assertion::deInitialize ()
 Shuts down the assertion system and clears callbacks.
void toy::assertion::setCallbacks (AssertionCallback assertionCallback, StackWalkCallback stackWalkCallback)
 Registers the assertion and stack-walk callbacks.
void toy::assertion::assertion (const char *code, const char *message, const char *fileName, const char *functionName, size_t lineNumber)
 Handles a failed assertion: formats code, message, fileName, functionName, lineNumber and invokes the registered AssertionCallback if set.

Variables

static AssertionCallback toy::assertion::s_assertionCallback = nullptr

Detailed Description

Stub definitions for the assertion callback API declared in core/assertion.hpp.