Subject: Re: bug#16283: 24.2; Built-in function * , used for calculating product, gives wrong output

From: Eli Zaretskii <[email-masked]>
Date: Sat, 28 Dec 2013 20:52:02 +0200

> From: Mohammed Sami <[email-masked]>
> Date: Sat, 28 Dec 2013 23:45:38 +0530
> 
> After starting window Emacs with "emacs -q", when I evaluate (* 1024 1024
> 1024 1024), I get 0.
> (* 1024 1024) works correctly, but repeating '1024' more than two times
> gives wrong value.

A 32-bit build of Emacs cannot correctly do integer math beyond the
value of most-positive-fixnum, whose value is 536870911.  This is a
fundamental limitation of Emacs Lisp, not a bug.

You can work around this bu using floating-point numbers:

  (* 1024.0 1024.0 1024.0) => 1073741824.0

Closing.