渲染zh-Hant

引數

Translation status: 繁體中文 reader-locale proof. Term names and code fences follow the zh-Hant pack; supporting prose may still be English.

Binds command-line arguments for an entry point.

Syntax: 入口 引數 <name> <block> | 函式 <name>() 引數 <name> <block>

Category#

entry

Examples#

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

Binds command-line arguments for an entry point.

# =============================================================================
# 引數 — Binds command-line arguments for an entry point.
# =============================================================================
#
# What this teaches:
#   • CLI entry binding — `入口 引數 <name>` declares a program entry
#     that receives command-line arguments
#   • Annotation-driven CLI — `@ cli`, `@ 描述`, and `入口 引數`
#     work together to define a structured CLI interface
#
# Common mistakes:
#   • attaching `@ cli` to a `函式` instead of an `入口` (SEM009), or forgetting to annotate with `@ cli` before `入口 引數`
#
# See also: 入口, cli, 命令, 選項, 操作數
# =============================================================================

# 引數 — CLI entry operand binding
#
# GRAMMAR:
#   entryDecl :← '入口' '引數' ident block
#
# EXPECTED OUTPUT:
#   No 入口 — declaration or test-runner surface only.
#
# BACKEND:
#   declaration-only CLI entry (whitelist: 引數/argumenta.fab).
#

@ 命令行 "argumenta-smoke"
@ description "argumenta exemplum"
main args args {
}