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

Unterminated for loop



If I type `for x;` (without the quotes) and press ENTER in an interactive zsh, I end up in PS2. However, the exact same sequence of characters is treated as a complete command in a script or function. Why is that?

    $ zsh -f
    % () { for x; }
    % zsh -fc 'for x;'
    % for x;
    for>

Roman.


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