aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman1994-09-17 00:35:09 +0000
committerRichard M. Stallman1994-09-17 00:35:09 +0000
commit627a95022609fafff38fedd6745ea3c2f9f985e5 (patch)
tree26fe6a6411d160cd3ccc71bb874ca6ed35c3c2f8 /src
parent0c38c2f9e01078ef2f29f9bdcf5e92c515117974 (diff)
downloademacs-627a95022609fafff38fedd6745ea3c2f9f985e5.tar.gz
emacs-627a95022609fafff38fedd6745ea3c2f9f985e5.zip
(Lisp_Object): Use EMACS_INT.
(MARKBIT): Don't define if already defined. (VALMASK, GCTYPEMASK, XSETTYPE, XSET) (XSETCONS, XSETBUFFER, XSETVECTOR, XSETSUBR, XSETSTRING) (XSETSYMBOL, XSETFUNCTION, XSETMARKER, XSETOBJFWD) (XSETINTPTR, XSETWINDOW, XSETPROCESS, XSETFLOAT) (struct Lisp_String, struct Lisp_Vector): Use EMACS_INT.
Diffstat (limited to 'src')
-rw-r--r--src/lisp.h42
1 files changed, 22 insertions, 20 deletions
diff --git a/src/lisp.h b/src/lisp.h
index d720944d8b8..d49fb527b18 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -242,7 +242,7 @@ Lisp_Object;
242 242
243#ifdef NO_UNION_TYPE 243#ifdef NO_UNION_TYPE
244 244
245#define Lisp_Object int 245#define Lisp_Object EMACS_INT
246 246
247/* These values are overridden by the m- file on some machines. */ 247/* These values are overridden by the m- file on some machines. */
248#ifndef VALBITS 248#ifndef VALBITS
@@ -254,9 +254,9 @@ Lisp_Object;
254#endif 254#endif
255 255
256#ifndef VALMASK 256#ifndef VALMASK
257#define VALMASK ((1<<VALBITS) - 1) 257#define VALMASK ((((EMACS_INT) 1)<<VALBITS) - 1)
258#endif 258#endif
259#define GCTYPEMASK ((1<<GCTYPEBITS) - 1) 259#define GCTYPEMASK ((((EMACS_INT) 1)<<GCTYPEBITS) - 1)
260 260
261/* Two flags that are set during GC. On some machines, these flags 261/* Two flags that are set during GC. On some machines, these flags
262 are defined differently by the m- file. */ 262 are defined differently by the m- file. */
@@ -270,7 +270,9 @@ Lisp_Object;
270 is a "large" one, one which was separately malloc'd 270 is a "large" one, one which was separately malloc'd
271 rather than being part of a string block. */ 271 rather than being part of a string block. */
272 272
273#ifndef MARKBIT
273#define MARKBIT (1 << (VALBITS + GCTYPEBITS)) 274#define MARKBIT (1 << (VALBITS + GCTYPEBITS))
275#endif /*MARKBIT */
274 276
275/* In the size word of a vector, this bit means the vector has been marked. 277/* In the size word of a vector, this bit means the vector has been marked.
276 In the size word of a large string, likewise. */ 278 In the size word of a large string, likewise. */
@@ -300,7 +302,7 @@ you lose
300#endif 302#endif
301 303
302#ifndef XSETTYPE 304#ifndef XSETTYPE
303#define XSETTYPE(a, b) ((a) = XUINT (a) | ((int)(b) << VALBITS)) 305#define XSETTYPE(a, b) ((a) = XUINT (a) | ((EMACS_INT)(b) << VALBITS))
304#endif 306#endif
305 307
306/* Use XFASTINT for fast retrieval and storage of integers known 308/* Use XFASTINT for fast retrieval and storage of integers known
@@ -354,7 +356,7 @@ extern int pure_size;
354 356
355#ifndef XSET 357#ifndef XSET
356#define XSET(var, type, ptr) \ 358#define XSET(var, type, ptr) \
357 ((var) = ((int)(type) << VALBITS) + ((int) (ptr) & VALMASK)) 359 ((var) = ((EMACS_INT)(type) << VALBITS) + ((EMACS_INT) (ptr) & VALMASK))
358#endif 360#endif
359 361
360/* During garbage collection, XGCTYPE must be used for extracting types 362/* During garbage collection, XGCTYPE must be used for extracting types
@@ -446,19 +448,19 @@ extern int pure_size;
446#define XPROCESS(a) ((struct Lisp_Process *) XPNTR(a)) 448#define XPROCESS(a) ((struct Lisp_Process *) XPNTR(a))
447#define XFLOAT(a) ((struct Lisp_Float *) XPNTR(a)) 449#define XFLOAT(a) ((struct Lisp_Float *) XPNTR(a))
448 450
449#define XSETCONS(a, b) XSETPNTR(a, (int) (b)) 451#define XSETCONS(a, b) XSETPNTR(a, (EMACS_INT) (b))
450#define XSETBUFFER(a, b) XSETPNTR(a, (int) (b)) 452#define XSETBUFFER(a, b) XSETPNTR(a, (EMACS_INT) (b))
451#define XSETVECTOR(a, b) XSETPNTR(a, (int) (b)) 453#define XSETVECTOR(a, b) XSETPNTR(a, (EMACS_INT) (b))
452#define XSETSUBR(a, b) XSETPNTR(a, (int) (b)) 454#define XSETSUBR(a, b) XSETPNTR(a, (EMACS_INT) (b))
453#define XSETSTRING(a, b) XSETPNTR(a, (int) (b)) 455#define XSETSTRING(a, b) XSETPNTR(a, (EMACS_INT) (b))
454#define XSETSYMBOL(a, b) XSETPNTR(a, (int) (b)) 456#define XSETSYMBOL(a, b) XSETPNTR(a, (EMACS_INT) (b))
455#define XSETFUNCTION(a, b) XSETPNTR(a, (int) (b)) 457#define XSETFUNCTION(a, b) XSETPNTR(a, (EMACS_INT) (b))
456#define XSETMARKER(a, b) XSETPNTR(a, (int) (b)) 458#define XSETMARKER(a, b) XSETPNTR(a, (EMACS_INT) (b))
457#define XSETOBJFWD(a, b) XSETPNTR(a, (int) (b)) 459#define XSETOBJFWD(a, b) XSETPNTR(a, (EMACS_INT) (b))
458#define XSETINTPTR(a, b) XSETPNTR(a, (int) (b)) 460#define XSETINTPTR(a, b) XSETPNTR(a, (EMACS_INT) (b))
459#define XSETWINDOW(a, b) XSETPNTR(a, (int) (b)) 461#define XSETWINDOW(a, b) XSETPNTR(a, (EMACS_INT) (b))
460#define XSETPROCESS(a, b) XSETPNTR(a, (int) (b)) 462#define XSETPROCESS(a, b) XSETPNTR(a, (EMACS_INT) (b))
461#define XSETFLOAT(a, b) XSETPNTR(a, (int) (b)) 463#define XSETFLOAT(a, b) XSETPNTR(a, (EMACS_INT) (b))
462 464
463#ifdef USE_TEXT_PROPERTIES 465#ifdef USE_TEXT_PROPERTIES
464/* Basic data type for use of intervals. See the macros in intervals.h */ 466/* Basic data type for use of intervals. See the macros in intervals.h */
@@ -549,14 +551,14 @@ struct Lisp_Buffer_Cons
549 551
550struct Lisp_String 552struct Lisp_String
551 { 553 {
552 int size; 554 EMACS_INT size;
553 DECLARE_INTERVALS /* `data' field must be last. */ 555 DECLARE_INTERVALS /* `data' field must be last. */
554 unsigned char data[1]; 556 unsigned char data[1];
555 }; 557 };
556 558
557struct Lisp_Vector 559struct Lisp_Vector
558 { 560 {
559 int size; 561 EMACS_INT size;
560 struct Lisp_Vector *next; 562 struct Lisp_Vector *next;
561 Lisp_Object contents[1]; 563 Lisp_Object contents[1];
562 }; 564 };