debug
Generated by tinox doc
Assertions and small runtime-introspection helpers: Debug::assert/panic for fail-fast checks, plus GC/memory diagnostics (memoryUsage, gcCollect) used to tune the Boehm GC on live workloads.
Assertions
import tinox.core.debug;
class Main
{
fnc main() -> Int32
{
let count: Int64 = 3;
Debug::assert(count > 0, "count must be positive");
println("live objects use " + Debug::memoryUsage().toString() + " bytes");
Debug::gcCollect();
return 0;
}
}
class Debug
Methods
fn assert(condition: Bool, message: String) → Nothing
fn panic(message: String) → Nothing
fn printStackTrace() → Nothing
fn typeName() → String
fn memoryUsage() → Int64
fn gcCollect() → Nothing