Ken Irving wrote:
So maybe the declaration could be fixed to show that, e.g., as either of: name () compound-command [redirection] function name [()] compound-command [redirection] I can't see how to put that in one construct...
BNF would use: < 'function' <NAME> > | < <NAME> '()' > <compound-command> [redirection] (ignoring that it would probably also specify <SPACE> where needed maybe using bash syntax: +(function _name_ | _name_ () ) compound-command [redirection]