Kết xuấtvi

lựa_chọ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.

Binds CLI options metadata to a function declaration.

Syntax: hàm <name>(...) lựa_chọn <ident> → <type>

Category#

entry

Examples#

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

Binds CLI options metadata to a function declaration.

# =============================================================================
# lựa_chọn — Binds CLI options metadata to a function declaration.
# =============================================================================
#
# What this teaches:
#   • Options bundle — The `lựa_chọn <ident> → <type>` syntax attaches a CLI options struct to a function.
#   • Declaration syntax — Options are declared as a modifier on the function signature, after the parameter list.
#
# Common mistakes:
#   • Duplicate flag definitions in lựa_chọn — each short and long flag must be unique within the CLI surface.
#
# See also: đối_số, gọi
# =============================================================================

# lựa_chọn — CLI options bundle on hàm
#
# GRAMMAR:
#   funcModifier :← ')' 'lựa_chọn' ident '→' type
#
# EXPECTED OUTPUT:
#   No bắt_đầu — declaration or test-runner surface only.
#
# BACKEND:
#   declaration-only CLI binding (whitelist: lựa_chọn/optiones.fab).
#

fn mitte() options Opts → string {
    return "ok"
}