emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: In CVS Emacs, calc-eval gives multiplication higher precidence than


From: Stefan Monnier
Subject: Re: In CVS Emacs, calc-eval gives multiplication higher precidence than division
Date: Sun, 07 Sep 2008 23:47:12 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

> If a is 2, and c is 5, you're actually telling me that *you*
> would parse:

>       2 b / 5 d

> as ((2 * b) / 5) * d ?

> That's crazy.

> That's (2b)/(5d), according to any math teacher I knew from school.

> That's the only sane parsing of that.

> Now, replace 2 with "a" and 5 with "c", and you get:

>   ab/cd

> which is (ab)/(cd).

Again "a b" is not the same as "a * b", and "ab" is even a lot
more different (given the lack of even a space, it's hard to argue that
there could be something that binds more tightly).
So this argument is irrelevant.  I.e. I agree if Calc gives higher
precedence to the implicit multiplication operator, but not if it does
so to the "*" multiplication operator.



        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]