Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

magic-space and pipe symbols in parentheses



Hey list,

Simon Désaulniers found this (the ^ in the line below indicates the
cursor position at a zsh prompt):

zsh% $(foo) bar
          ^

Now insert "| " with space being bound to magic-space:

  bindkey ' ' magic-space

...to get this (the " bar" is gone):

zsh% $(foo| )
            ^

This works from "zsh -f" with the additional bindkey I mentioned.

I've bisected this down to:

commit 4073a6655cafc78728cb126cfe44e89cc7ba720a
Author: Peter Stephenson <pws@xxxxxxx>
Date:   Thu Nov 3 10:30:00 2016 +0000

    39815: Read input to end on parse error in $(...) inside a string.

    This allows ${(z)} to output the whole string, although we can't do
    word splitting from the error onwards.


Not sure how this is related to magic-space, but this is what I get.


Regards, Frank
-- 
In protocol design, perfection has been reached not when there is
nothing left to add, but when there is nothing left to take away.
                                                  -- RFC 1925



Messages sorted by: Reverse Date, Date, Thread, Author