From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7952 invoked by alias); 28 Dec 2013 20:08:11 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 32194 Received: (qmail 4075 invoked from network); 28 Dec 2013 20:08:05 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 From: Bart Schaefer Message-id: <131228120730.ZM26843@torch.brasslantern.com> Date: Sat, 28 Dec 2013 12:07:30 -0800 X-Mailer: OpenZMail Classic (0.9.2 24April2005) To: zsh-workers@zsh.org Subject: Parsing of "anonymous" functions MIME-version: 1.0 Content-type: text/plain; charset=us-ascii I just noticed this: torch% ()()()()()()()() function function function function function function function function> Did we really mean for this to be possible or should the parser be pickier about requiring an "ordinary" command structure as the first thing after the empty parens? The same doesn't quite work with the "function" keyword: torch% function function function function function function function function> print $funcstack torch% functions function () { function () { () { print $funcstack } } } (However, you can't easily execute the function named "function" as the keyword always takes precedence.) Anyway, just an oddity it seemed interesting to point out.