Skip to content
Tcl Source Code Check-in [b6eed8b994]
Login

Check-in [b6eed8b994]

Overview
Comment:TIP 672: add $((expr)) expression substitution $((expr)) is a shortcut for [expr {expr}], usable wherever $ substitution works: words, quoted strings, subst and Tcl_ParseVarName. The body is parsed once, as the argument of a braced expr, so nothing is substituted twice. New token type TCL_TOKEN_EXPR_SUBST. subst gains -expressions and -noexpressions; -nocommands and -novariables also turn it off. The build switch TCL_EXPR_SUBST_PARENS selects the trigger: $(( (default) or $(. Includes documentation and 107 new tests.
Timelines: family | ancestors | descendants | both | tip-672-v2
Files: files | file ages | folders
SHA3-256: b6eed8b994e311e8bacd269f58339db83a23bc0f76f49690ea12a1e08d970a2b
User & Date: rocketship98 on 2026-10-24 23:36:48.725
Original User & Date: core5 on 2026-10-24 23:36:48.725
Other Links: branch diff | manifest | tags
Context
2026-10-26
02:57
Guard against stack overflow from deeply nested $((expr)): apply the same nesting limit as TclCompil... check-in: 24c265df9a user: rocketship98 tags: tip-672-v2
2026-10-24
23:36
TIP 672: add $((expr)) expression substitution $((expr)) is a shortcut for [expr {expr}], usable ... check-in: b6eed8b994 user: rocketship98 tags: tip-672-v2
15:07
More marking of default switch branches as unreachable check-in: d6dd6d0f71 user: dkf tags: trunk, main
Changes