Subject: Possible parsing bug with alternate for-loop syntax
From: Mikael Magnusson <[email-masked]>
To: zsh workers <[email-masked]>
Date: Sat, 11 Jun 2016 17:48:48 +0200
List-Id: Zsh Workers List <zsh-workers.zsh.org>

17:44:25 <Mikachu> > for a (1) {echo hi}
17:44:26 <machabot> Mikachu: hi
17:44:29 <Mikachu> > for a (1) {a=hi}; echo $a
17:44:38 <machabot> Mikachu: Timeout (no output).
17:44:36 <Mikachu> > for a (1) {a=hi} }; echo $a
17:44:39 <machabot> Mikachu: hi}
17:45:17 <Mikachu> > for a (1) {builtin local a=hi}; echo $a
17:45:18 <machabot> Mikachu: hi
17:45:22 <Mikachu> > for a (1) {local a=hi}; echo $a
17:45:30 <machabot> Mikachu: Timeout (no output).
17:45:26 <Mikachu> nice
17:45:37 <Mikachu> you get the bug for reserved word local but not for
builtin local

The documentation does state the syntax is { list } with the space
included, but this still seemed somewhat surprising to me.

-- 
Mikael Magnusson