bất_biến
Translation status: Tiếng Việt reader-locale proof. Term names and code fences follow the vi pack; supporting prose may still be English.
Marks a function as non-mutating.
Syntax: hàm <name>(...) bất_biến → <type>
Category#
function
Related#
Examples#
radix/corpus/immutata/immutata.fab (canonical · keyword)#
Marks a function as non-mutating.
# =============================================================================
# bất_biến — Marks a function as non-mutating
# =============================================================================
#
# What this teaches:
# • Marks a function as non-mutating.
# • Related keywords: ném_lỗi
#
# Common mistakes:
# • Mutating state inside an `bất_biến` function — `bất_biến` is a non-mutation contract; modifying `vào` parameters or external state breaks the contract.
#
# See also: ném_lỗi
# =============================================================================
# bất_biến — immutability contract on hàm
#
# GRAMMAR:
# funcModifier :← 'bất_biến'
#
# EXPECTED OUTPUT:
# No bắt_đầu — declaration or test-runner surface only.
#
# BACKEND:
# declaration-only function modifier (whitelist: bất_biến/immutata.fab).
#
fn inspecta() readonly → int {
return 0
}