zsh-users
 help / color / mirror / code / Atom feed
From: Atom Smasher <atom@smasher.org>
To: zsh-users@zsh.org
Subject: $[ 09.5 ]  -- bad math expression
Date: Sun, 2 Dec 2012 23:30:34 +1300 (NZDT)	[thread overview]
Message-ID: <alpine.DEB.2.00.1212022323450.27859@oreo.lan> (raw)

with zsh 4.2.1 i get what i'd expect here:

 	echo "$[ 09.5 ]"
 	9.5

and all math operations work as expected. with zsh 4.3.10, this is broken:

 	echo "$[ 09.5 ]"
 	zsh: bad math expression: operator expected at `.5 '

and all math operations using "09.5" result in errors. the problem seems 
to come up when using a non-integer with a leading zero.

is this a known bug? are there any workarounds?

thanks...


-- 
         ...atom

  ________________________
  http://atom.smasher.org/
  762A 3B98 A3C3 96C9 C6B7 582A B88D 52E4 D9F5 7808
  -------------------------------------------------

 	"Those who profess to favor freedom, and yet deprecate
 	 agitation, are men who want rain without thunder and
 	 lightning. They want the ocean without the roar of
 	 its many waters."
 		-- Frederick Douglass


             reply	other threads:[~2012-12-02 10:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-02 10:30 Atom Smasher [this message]
2012-12-02 21:05 ` Peter Stephenson
2012-12-02 21:59 ` Bart Schaefer
2012-12-02 22:15   ` Atom Smasher

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=alpine.DEB.2.00.1212022323450.27859@oreo.lan \
    --to=atom@smasher.org \
    --cc=zsh-users@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).