From: Peter Stephenson <p.w.stephenson@ntlworld.com>
To: Zsh Hackers' List <zsh-workers@zsh.org>
Subject: PATCH: zcalc default base
Date: Sat, 1 Mar 2014 21:03:27 +0000 [thread overview]
Message-ID: <20140301210327.3e27cabd@pws-pc.ntlworld.com> (raw)
I messed up zcalc's ability to set a default base when I modified it for
the [#_] syntax. I think this is the right fix.
diff --git a/Functions/Misc/zcalc b/Functions/Misc/zcalc
index 6a56d47..b796446 100644
--- a/Functions/Misc/zcalc
+++ b/Functions/Misc/zcalc
@@ -197,7 +197,7 @@ while (( expression_mode )) ||
# Set default base if `[#16]' or `[##16]' etc. on its own.
# Unset it if `[#]' or `[##]'.
if [[ $line = (#b)[[:blank:]]#('[#'(\#|)((<->|)(|_|_<->))']')[[:blank:]]#(*) ]]; then
- if [[ -z $match[4] ]]; then
+ if [[ -z $match[6] ]]; then
if [[ -z $match[3] ]]; then
defbase=
else
--
Peter Stephenson <p.w.stephenson@ntlworld.com>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/
reply other threads:[~2014-03-01 21:03 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20140301210327.3e27cabd@pws-pc.ntlworld.com \
--to=p.w.stephenson@ntlworld.com \
--cc=zsh-workers@zsh.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.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).