debug

Generated by tinox doc

tinox.core.debug, bundled with the compiler and also available as a standalone tinox-central package.

Assertions

import tinox.core.debug
class Main
{
    fnc main() -> Int32
    {
        const count: Int64 = 3
        Debug::assert(count > 0, "count must be positive")
        println("live objects use " + Debug::memoryUsage().toString() + " bytes")
        Debug::gcCollect()
        return 0
    }
}

@Errorclass AssertionError

* A Debug assertion failed.

Fields

messageString

class Debug

Methods

@Throwsfn assert(condition: Bool, message: String) → Nothing
@Throwsfn panic(message: String) → Nothing
fn printStackTrace() → Nothing
fn typeName() → String
fn memoryUsage() → Int64
fn gcHeapBytes() → Int64
fn gcFreeBytes() → Int64
fn gcUsedEstimateBytes() → Int64
fn gcAllocatedBytes() → Int64
fn gcCollections() → Int64
fn gcCollect() → Nothing