Chet Ramey wrote: >> ----------------------------- >> $ function name (echo) >> bash: syntax error near unexpected token `echo' >> -----------------------------
> It's not. It's a shift/reduce conflict in the grammar. The default > yacc/bison behavior is to choose the `function word () command' production, > and I have left it that way. The `function word command' form came from > ksh, which doesn't allow the construct you used anyway (it requires one > or more newlines after the word), so the current bash implementation > supports all existing ksh uses. Okay, then it could be mentioned in the manual (as exception or so, like the semikolon in {...;} "for parsing reasons"). Some beginner pointed me at this, thinking he made a mistake or didn't understand the manual. Sorry for not providing a manpage patch. -- This is my life - this is my net! - Jan