From: Jan Verbeek <ring@openmailbox.org>
To: dash@vger.kernel.org
Subject: [BUG] Illegal function names are accepted after being used as aliases
Date: Tue, 23 Feb 2016 19:18:06 +0100 [thread overview]
Message-ID: <56CCA25E.5020809@openmailbox.org> (raw)
Function definitions that use a bad function name (such as "-" and "=")
are accepted if the function name already exists as an alias. For example:
$ -
dash: 1: -: not found
$ - () { echo hello; }
dash: 2: Syntax error: Bad function name
$ -
dash: 2: -: not found
$ alias -=true
$ -
$ - () { echo hello; }
$ -
hello
$
next reply other threads:[~2016-02-23 18:24 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-23 18:18 Jan Verbeek [this message]
2016-02-23 18:40 ` [BUG] Illegal function names are accepted after being used as aliases Eric Blake
2016-02-23 18:44 ` Harald van Dijk
2016-02-23 18:58 ` Eric Blake
2016-02-23 19:21 ` Harald van Dijk
2016-02-23 19:33 ` Eric Blake
2016-02-23 21:00 ` Harald van Dijk
2016-02-23 21:49 ` Eric Blake
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56CCA25E.5020809@openmailbox.org \
--to=ring@openmailbox.org \
--cc=dash@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox