PATCH 21.5
This fixes a problem I have encountered when using GCC 4.1. I never had
trouble with earlier versions of GCC, nor with icc. With newer GCCs,
apparently references to bit-restricted fields keep the bit restriction
in subsequent arithmetic operations. This breaks a lot of the bignum
code, in particular.
A similar patch could be applied to XEmacs 21.4, but I don't know if it
is necessary.
src/ChangeLog addition:
2006-06-13 Jerry James <james(a)xemacs.org>
* lisp-union.h: Cast away bit restrictions on values retrieved
from the Lisp_Object union.
xemacs-21.5 source patch:
Diff command: cvs -q diff -uN
Files affected: src/lisp-union.h
Index: src/lisp-union.h
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/lisp-union.h,v
retrieving revision 1.20
diff -d -u -r1.20 lisp-union.h
--- src/lisp-union.h 2005/10/25 11:16:26 1.20
+++ src/lisp-union.h 2006/06/13 15:34:22
@@ -80,11 +80,11 @@
}
Lisp_Object;
-#define XCHARVAL(x) ((x).gu.val)
+#define XCHARVAL(x) ((EMACS_UINT)(x).gu.val)
#define XPNTRVAL(x) ((x).ui)
-#define XREALINT(x) ((x).s.val)
-#define XUINT(x) ((x).u.val)
+#define XREALINT(x) ((EMACS_INT)(x).s.val)
+#define XUINT(x) ((EMACS_UINT)(x).u.val)
#define XTYPE(x) ((x).gu.type)
#define EQ(x,y) ((x).v == (y).v)
--
Jerry James, Assistant Professor james(a)xemacs.org
Computer Science Department
http://www.cs.usu.edu/~jerry/
Utah State University