aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKen Raeburn2010-05-15 17:19:05 -0400
committerKen Raeburn2010-05-15 17:19:05 -0400
commit5276642588f017741f425c9c83025684feb5afdd (patch)
treeef6aa73f77dcc61ac963353ead9fda03182e3198 /src
parent8b4eb7969cefe32154d719ac7c3137b1e43b72f9 (diff)
downloademacs-5276642588f017741f425c9c83025684feb5afdd.tar.gz
emacs-5276642588f017741f425c9c83025684feb5afdd.zip
* lisp.h (XFLOAT_DATA): Use "0?x:x" to generate an rvalue. (bug#5916)
(LISP_MAKE_RVALUE) [!USE_LISP_UNION_TYPE && !__GNUC__]: Likewise.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog4
-rw-r--r--src/lisp.h13
2 files changed, 10 insertions, 7 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 32761b6f446..877accc913b 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,9 @@
12010-05-15 Ken Raeburn <raeburn@raeburn.org> 12010-05-15 Ken Raeburn <raeburn@raeburn.org>
2 2
3 * lisp.h (XFLOAT_DATA): Use "0?x:x" to generate an
4 rvalue. (bug#5916)
5 (LISP_MAKE_RVALUE) [!USE_LISP_UNION_TYPE && !__GNUC__]: Likewise.
6
3 * emacs.c (main): Initialize initial-environment and 7 * emacs.c (main): Initialize initial-environment and
4 process-environment before generating from env, not after. 8 process-environment before generating from env, not after.
5 9
diff --git a/src/lisp.h b/src/lisp.h
index 7d329cc754c..b4ff446b064 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -310,11 +310,10 @@ LISP_MAKE_RVALUE (Lisp_Object o)
310 return o; 310 return o;
311} 311}
312#else 312#else
313/* This isn't quite right - it keeps the argument as an lvalue. 313/* This is more portable to pre-C99 non-GCC compilers, but for
314 Making it const via casting would help avoid code actually 314 backwards compatibility GCC still accepts an old GNU extension
315 modifying the location in question, but the casting could cover 315 which caused this to only generate a warning. */
316 other type-related bugs. */ 316#define LISP_MAKE_RVALUE(o) (0 ? (o) : (o))
317#define LISP_MAKE_RVALUE(o) (o)
318#endif 317#endif
319 318
320#else /* USE_LISP_UNION_TYPE */ 319#else /* USE_LISP_UNION_TYPE */
@@ -1461,9 +1460,9 @@ struct Lisp_Float
1461 }; 1460 };
1462 1461
1463#ifdef HIDE_LISP_IMPLEMENTATION 1462#ifdef HIDE_LISP_IMPLEMENTATION
1464#define XFLOAT_DATA(f) (XFLOAT (f)->u.data_ + 0) 1463#define XFLOAT_DATA(f) (0 ? XFLOAT (f)->u.data_ : XFLOAT (f)->u.data_)
1465#else 1464#else
1466#define XFLOAT_DATA(f) (XFLOAT (f)->u.data + 0) 1465#define XFLOAT_DATA(f) (0 ? XFLOAT (f)->u.data : XFLOAT (f)->u.data)
1467/* This should be used only in alloc.c, which always disables 1466/* This should be used only in alloc.c, which always disables
1468 HIDE_LISP_IMPLEMENTATION. */ 1467 HIDE_LISP_IMPLEMENTATION. */
1469#define XFLOAT_INIT(f,n) (XFLOAT (f)->u.data = (n)) 1468#define XFLOAT_INIT(f,n) (XFLOAT (f)->u.data = (n))