[Top][All Lists]

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

Re: macro FIXNUM_OVERFLOW_P in lisp.h is valid ?

From: Andreas Schwab
Subject: Re: macro FIXNUM_OVERFLOW_P in lisp.h is valid ?
Date: Fri, 23 Oct 2009 22:57:07 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux)

Toru TSUNEYOSHI <address@hidden> writes:

> I read the code of function `string-to-number', and traced functions or
> macros recursively.
>   traces of string-to-number:
>     data.c: Fstring_to_number
>       lisp.h: make_fixnum_or_float
>         lisp.h: FIXNUM_OVERFLOW_P
>   citation of FIXNUM_OVERFLOW_P (in Emacs 23.1):
>     /* Value is non-zero if C integer I doesn't fit into a Lisp fixnum.  */
>     #define FIXNUM_OVERFLOW_P(i) \
> I think FIXNUM_OVERFLOW_P is problematic.

Thanks for the report.  The right fix is to remove the cast, so that the
compiler will promote the operands to the appropriate common type.


Andreas Schwab, address@hidden
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

reply via email to

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