zsh-users
 help / color / mirror / code / Atom feed
From: "Clifford Caoile" <piyokun@email.com>
To: <zsh-users@sunsite.dk>
Subject: RE: a calculator for zsh - zcalc and pcal conflict
Date: Fri, 31 Jan 2003 21:03:08 +0900	[thread overview]
Message-ID: <BBEKIEKOHGEFJBFLEENGEEFACGAA.piyokun@email.com> (raw)
In-Reply-To: <22197.1043948058@csr.com>

Everyone:

Thanks to kwong and Phil for the zcalc suggestions. I have implemented the
$@ in the input string and also the noglob/realias trick in my own .zshrc.
I'm pretty sure the settings are obvious so I won't post them here.

I don't know how "elegant" my "zcalc" is, but I get some round-off errors
with some float computations. For example:

+2403> zcalc 23.0 * 1.05                         ~ 31Fri203104
24.150000000000002
+2404> zsh --version                             ~ 31Fri203106
zsh 4.0.6 (i686-pc-cygwin)

+2403> echo $(( 23.0 * 1.05))                  ~ 31Fri205300 1
24.150000000000002
+2404> zsh --version                             ~ 31Fri205302
zsh 4.0.4 (i386-redhat-linux-gnu)

I have seen it where there isn't any round off error on my other machines at
work and at home. What is this? Anyway, not a big deal, just a little
annoying.

Also, thanks to Peter S. for the heads up on the zsh-4.1.x dev branch. I
guess for my own sake I should rename this "zcalc" so I'll be forward
compatible. As far as I'm concerned, only 4.0.4 and 4.0.6 exist, because
those are the zsh versions on my personal and work computers (RedHat 7.3,
8.0, Cygwin 2003/1), so I didn't know about that. I look forward to a
release, but frankly, I think zsh-4.0.6 is pretty cool as is.

Anyway, I've been thinking more and more that zsh is becoming more and more
emacs-y, as in fully featured for the interactive use. GNU Emacs is an
"advanced, self-documenting, customizable, extensible real-time display
editor." zsh is an "advanced,
self-documenting, customizable, extensible real-time display CLI".

  ,-~-.
 < ^ ; ~,  Clifford Escobar CAOILE  (aka "Piyo-kun")
  (_  _,
   J~~>  _.___...:.__..__.: __.:_. .:_.__::_..:._::._...  _____ p(^_^)q


| -----Original Message-----
| From: Peter Stephenson [mailto:pws@csr.com]
| Sent: Friday, January 31, 2003 02:34
| To: zsh-users@sunsite.dk
| Subject: Re: a calculator for zsh - zcalc and pcal conflict
|
|
| kwong@nwsgpa.ih.lucent.com wrote:
| > All,
| >
| > Earlier I posted a calculator "pcal" written in perl as
| > a followup to Clifford's post of "zcalc" written in zsh.
| >
| > Andy Spiegl noticed a problem and his email is attached
| > below.
|
| If you're worrying about conflicts, you might note there is already a
| `zcalc' supplied with the 4.1 zsh distribution.  It's a command-line
| interface rather than one-shot.  See the zshcontrib manual page.
|
| Yes, we still need to release 4.1, so you wouldn't know about this
| unless you're tracking the development version.
|
| --
| Peter Stephenson <pws@csr.com>                  Software Engineer
| CSR Ltd., Science Park, Milton Road,
| Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 692070
|
|
| **********************************************************************
| The information transmitted is intended only for the person or
| entity to which it is addressed and may contain confidential
| and/or privileged material.
| Any review, retransmission, dissemination or other use of, or
| taking of any action in reliance upon, this information by
| persons or entities other than the intended recipient is
| prohibited.
| If you received this in error, please contact the sender and
| delete the material from any computer.
| **********************************************************************



      reply	other threads:[~2003-01-31 12:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-30 17:08 kwong
2003-01-30 17:34 ` Peter Stephenson
2003-01-31 12:03   ` Clifford Caoile [this message]

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=BBEKIEKOHGEFJBFLEENGEEFACGAA.piyokun@email.com \
    --to=piyokun@email.com \
    --cc=zsh-users@sunsite.dk \
    /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).