1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-05-22 00:11:30 +02:00

cf. users/29635: additional detail of parameter expansion in math context.

This commit is contained in:
Bart Schaefer 2024-02-04 20:46:49 -08:00
parent 58ff6c68d5
commit 791aaf88cc
2 changed files with 8 additions and 0 deletions

View file

@ -1,5 +1,8 @@
2024-02-04 Bart Schaefer <schaefer@zsh.org>
* unposted (cf. users/29635): Doc/Zsh/arith.yo: additional detail
of parameter expansion in math context.
* 52521: Etc/BUGS: mapfile handling of empty/unreadable files
2024-02-04 Mikael Magnusson <mikachu@gmail.com>

View file

@ -206,6 +206,11 @@ example,
example(((val2 = val1 * 2)))
assigns twice the value of tt($val1) to the parameter named tt(val2).
If the expansion of tt($val1) is text rather than a number, then when
tt(val1) is referenced that text is itself evaluated as a math expression
as if surrounded by parentheses `tt(LPAR()$val1)tt(RPAR())'. Expansion
continues until there are no more parameter references, a number has
resulted, or an expression error occurs.
An internal integer representation of a named parameter
can be specified with the tt(integer) builtin.