渲染zh-Hans

参数

Translation status: 简体中文 reader-locale proof. Term names and code fences follow the zh-Hans 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 {
}