Renderingla

sponte

Marks a named declaration slot (parameter or genus field) as voluntary — the caller or provider may omit the value.

Aliases: optional, voluntary

Syntax: <type> <name> sponte [= default | vel default]

Category

declaration

Related

Examples

examples/corpus/sponte/sponte.fab (canonical · keyword)

Marks a named declaration slot (parameter or genus field) as voluntary — the caller or provider may omit the value.

# sponte — optional parameter / field marker
#
# GRAMMAR:
#   optionalMarker :← 'sponte'
#
# EXPECTED OUTPUT:
#   No incipit — declaration or test-runner surface only.
#
# BACKEND:
#   declaration-only optional slots (whitelist: sponte/sponte.fab). Cross-ref: optionalis/optionalis.fab.
#

functio greet(textus nomen, textus titulus sponte) → textus {
    redde nomen
}

functio paginate(numerus pagina sponte vel 1) → textus {
    redde "page"
}

genus User {
    textus name
    textus email sponte
}

Expected output: