การเรนเดอร์th-TH

จริง

Translation status: ภาษาไทย reader-locale proof. Term names and code fences follow the th-TH pack; supporting prose may still be English.

Represents the true boolean value and can prefix a truthiness check.

Syntax: จริง [<expression>]

Category#

literal

Examples#

radix/corpus/literalia/boolean.fab (canonical · keyword)#

Boolean literals จริง and เท็จ with ตรรกะ bindings.

main {
    const bool enabled ← true
    const bool disabled ← false
    print enabled
    print disabled
    print enabled and not disabled
}

Expected output:

verum
falsum
verum

radix/corpus/verum/verum.fab (canonical · keyword)#

Represents the true boolean value and can prefix a truthiness check.

test "verum is the true literal" {
    const bool active ← true
    assert active
    assert active ≡ true
}

test "verum stands alone as a truthy condition" {
    assert true
}
# =============================================================================
# จริง — Represents the true boolean value and can prefix a truthiness check.
# =============================================================================
#
# What this teaches:
#   • Boolean literal — `จริง` as the canonical `true` value for `ตรรกะ` type
#   • Truthiness prefix — `จริง` can prefix an expression for explicit truthiness checking
#
# Common mistakes:
#   • confusing จริง (the true literal) with ไม่ นัล (a null check) — จริง is a boolean value, not a presence test
#
# See also: เท็จ, นัล
# =============================================================================



# จริง — true literal
#
# GRAMMAR:
#   literal :← 'จริง'
#
# EXPECTED OUTPUT:
#   Scalar stdout smoke (see body).
#

main {
    const bool active ← true
    print active
}

Expected output:

verum