On Wed, Jan 25, 2023 at 3:48 PM Bart Schaefer wrote: > > The value being assigned to the variable is coming from $1=${(P)1} and > ${(P)1} includes the specified justification, so the value assigned is > always already the correct width. Which means ${(P)#1} is the justification, no need to fork typeset for that, and ... > Is there any other way to reference > the "real, unfilled" value of a parameter that has justification > specified? The only reliable way I can find is to first remove the justification: % typeset -L5 FOO=123456789 % printf "<%s>\n" $FOO <12345> % typeset +L FOO % printf "<%s>\n" $FOO <123456789> This can be done without otherwise changing the type or tied-ness of the scalar. One more pass at it attached.