Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Should (z) PE flag split & during expansion?
- X-seq: zsh-workers 51819
- From: Zaidhaan Hussain <zaidhaan@xxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Should (z) PE flag split & during expansion?
- Date: Sat, 3 Jun 2023 14:00:09 +0800
- Archived-at: <https://zsh.org/workers/51819>
- List-id: <zsh-workers.zsh.org>
- Ui-outboundreport: notjunk:1;M01:P0:2fLtqcek0Sg=;TG39noNZ90wVs/ZwowLO1GYKJMv b4AB4VC2F9nXn7aZUDJabT7qhOTRWj/dSbmAIJTK61dLWt1ieJGgAD1aWgwY1KRnZhQjOKxUm UaKmhiIZcCn6hVg5LfT+n5RlWEtCVRRQ17Ro8gpgysaDfYZHqyJ8DnaYuOZ9ATAPpJQmP1PGR AhgN8z026JF1MwhY3KNrRa+FoiNEN02eOEeTeowjtT47RiY/1bmBcOXD4apE4VQztyz58vk7U uPIPxc4NsFAMdNl3x16nOvQ8RT4gCk3mAhkFrjF2QsrNxIQ7Oi0To9k1ypUcRDpt7vvjDzEqD 2SdRa6iHwolt8rmpe8ZA+aVDLssWkHWlmWqOJh9K6nX9d9aX2A9q4mBW0+JNrELe6dxG3O9d4 Ad+P8F5PJrGkVOKyfkMLsOc22sbeidTrMERKW2FZN8pIVi6lA1BM4BFTi82Ae662/nIKJo7Y3 nPb7ubvb4MXeadW4ISVUo3v6szOxWtdTfv6lQAGHtWbbluzeTLiOFb+PSMx2TKXR+cp6LWRlw XC62TUMrEdlWvVQvpuufsmvlMBm80cEmjPHZDes5zbGZN7v5TxKDnU6zDvbpSxjitRBScE+Yq 0rQkf4pV7VDsuhceJGFW8tpfRuSdsQsenJCIY5snEywxNZBS75dUsw1oOBJvvcwSfZl2kcL4i DrD+Zp3bKNJEoz7gQSqa9dwI5isOMQZ+Zl44qD/3X53cwtpk9N1Y5WtSCK2mJaUbqPHBFBg+m tMapeglEztqMNVSM65/pcXivMXY6u0II4RsNcJqZ2/vwXa37qAh2mYqJYqMap1Eq5+6qLLD0E 8Uhm7Jhp2Gs7j2E2dDbHMEYtgMQRKimJLmRKUEp1NbWWfpwgyco+hgtzbXl1fIywVsG9h9ndC IA3hN8I7CZvw6DD+STaqogaUvr4PsraOJj0OPfs5/3LUQxrqB55/N/2A6G0UhZ0uVxKyNJqFw 2QgOVQ==
The following:
printf '<%s>' ${(z)${:-'!-2:&'}}
Yields this:
<!-2:><&>
Which does not make sense if we consider that & is valid in parameter
expansions. At least for history expansions, such as would be the case
for the following setup:
echo foo_replaceme_bar
echo baz_replaceme_qux
!-2:s/replaceme/subst/ && !-1:&
I realize the manual (14.1.4) states "In parameter expansion the &
must appear inside braces, and in filename generation it must be
quoted with a backslash."
But even so, the following:
printf '<%s>' ${(z)${:-'!{-2:&}'}}
Yields this:
<!{-2:><&><}>
This was identified in issue #929 in zsh-users/zsh-syntax-highlighting
on GitHub.
--
Regards,
Zaidhaan
Messages sorted by:
Reverse Date,
Date,
Thread,
Author