comparison src/lisp.h @ 9328:4db4768d5857

(XFASTINT): Changed to non-lvalue syntax, to ensure that callers will use XSETFASTINT instead.
author Karl Heuer <kwzh@gnu.org>
date Tue, 04 Oct 1994 17:04:39 +0000
parents ec707cca800a
children c4389e902a15
comparison
equal deleted inserted replaced
9327:b3398cf56fba 9328:4db4768d5857
314 #endif 314 #endif
315 315
316 /* For integers known to be positive, XFASTINT provides fast retrieval 316 /* For integers known to be positive, XFASTINT provides fast retrieval
317 and XSETFASTINT provides fast storage. This takes advantage of the 317 and XSETFASTINT provides fast storage. This takes advantage of the
318 fact that Lisp_Int is 0. */ 318 fact that Lisp_Int is 0. */
319 #define XFASTINT(a) (a) 319 #define XFASTINT(a) ((a) + 0)
320 #define XSETFASTINT(a, b) ((a) = (b)) 320 #define XSETFASTINT(a, b) ((a) = (b))
321 321
322 /* Extract the value of a Lisp_Object as a signed integer. */ 322 /* Extract the value of a Lisp_Object as a signed integer. */
323 323
324 #ifndef XINT /* Some machines need to do this differently. */ 324 #ifndef XINT /* Some machines need to do this differently. */
398 #define XSETTYPE(a, b) ((a).u.type = (char) (b)) 398 #define XSETTYPE(a, b) ((a).u.type = (char) (b))
399 399
400 /* For integers known to be positive, XFASTINT provides fast retrieval 400 /* For integers known to be positive, XFASTINT provides fast retrieval
401 and XSETFASTINT provides fast storage. This takes advantage of the 401 and XSETFASTINT provides fast storage. This takes advantage of the
402 fact that Lisp_Int is 0. */ 402 fact that Lisp_Int is 0. */
403 #define XFASTINT(a) ((a).i) 403 #define XFASTINT(a) ((a).i + 0)
404 #define XSETFASTINT(a, b) ((a).i = (b)) 404 #define XSETFASTINT(a, b) ((a).i = (b))
405 405
406 #ifdef EXPLICIT_SIGN_EXTEND 406 #ifdef EXPLICIT_SIGN_EXTEND
407 /* Make sure we sign-extend; compilers have been known to fail to do so. */ 407 /* Make sure we sign-extend; compilers have been known to fail to do so. */
408 #define XINT(a) (((a).i << 8) >> 8) 408 #define XINT(a) (((a).i << 8) >> 8)