emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master 79f59d4 2/3: Fix up for bignums after merge from tr


From: Tom Tromey
Subject: [Emacs-diffs] master 79f59d4 2/3: Fix up for bignums after merge from trunk
Date: Sat, 11 Aug 2018 15:47:36 -0400 (EDT)

branch: master
commit 79f59d41a3d2ef3b4a9a87265bf517206a5837ad
Author: Tom Tromey <address@hidden>
Commit: Tom Tromey <address@hidden>

    Fix up for bignums after merge from trunk
    
    * src/character.c (char_width): Use XFIXNUM.
    * src/editfns.c (styled_format): Use XFIXNUM, XUFIXNUM.
    * src/fns.c (Fproper_list_p): Use make_fixnum.
---
 src/character.c | 2 +-
 src/editfns.c   | 4 ++--
 src/fns.c       | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/character.c b/src/character.c
index 851e61e..0b14e47 100644
--- a/src/character.c
+++ b/src/character.c
@@ -294,7 +294,7 @@ char_width (int c, struct Lisp_Char_Table *dp)
            if (GLYPH_CODE_P (ch))
              c = GLYPH_CODE_CHAR (ch);
            else if (CHARACTERP (ch))
-             c = XFASTINT (ch);
+             c = XFIXNUM (ch);
            if (c >= 0)
              {
                int w = CHARACTER_WIDTH (c);
diff --git a/src/editfns.c b/src/editfns.c
index b1b9eb6..a109906 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -4749,12 +4749,12 @@ styled_format (ptrdiff_t nargs, Lisp_Object *args, bool 
message)
                    {
                      if (binary_as_unsigned)
                        {
-                         x = XUINT (arg);
+                         x = XUFIXNUM (arg);
                          negative = false;
                        }
                      else
                        {
-                         EMACS_INT i = XINT (arg);
+                         EMACS_INT i = XFIXNUM (arg);
                          negative = i < 0;
                          x = negative ? -i : i;
                        }
diff --git a/src/fns.c b/src/fns.c
index 38b2d28..8258806 100644
--- a/src/fns.c
+++ b/src/fns.c
@@ -163,7 +163,7 @@ A proper list is neither circular nor dotted (i.e., its 
last cdr is nil).  */
     return Qnil;
   if (MOST_POSITIVE_FIXNUM < len)
     xsignal0 (Qoverflow_error);
-  return make_number (len);
+  return make_fixnum (len);
 }
 
 DEFUN ("string-bytes", Fstring_bytes, Sstring_bytes, 1, 1, 0,



reply via email to

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