diff options
| author | Paul Eggert | 2011-06-02 01:25:28 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-06-02 01:25:28 -0700 |
| commit | 275a5dd65098a2d6fcc14c21f805fc8d5e4479ee (patch) | |
| tree | a03e79b0a7c066940ed02cd11927c7fd4080f092 /src/lisp.h | |
| parent | 97f4ea979720e535ade3fe0055fb710e18fb7b5d (diff) | |
| parent | f797625a8ca7bc973b6943c6fce97f1e479a283d (diff) | |
| download | emacs-275a5dd65098a2d6fcc14c21f805fc8d5e4479ee.tar.gz emacs-275a5dd65098a2d6fcc14c21f805fc8d5e4479ee.zip | |
Merge from trunk.
Diffstat (limited to 'src/lisp.h')
| -rw-r--r-- | src/lisp.h | 47 |
1 files changed, 23 insertions, 24 deletions
diff --git a/src/lisp.h b/src/lisp.h index 8df4b67bb45..a9e7354f9fc 100644 --- a/src/lisp.h +++ b/src/lisp.h | |||
| @@ -525,23 +525,21 @@ extern Lisp_Object make_number (EMACS_INT); | |||
| 525 | 525 | ||
| 526 | #define EQ(x, y) (XHASH (x) == XHASH (y)) | 526 | #define EQ(x, y) (XHASH (x) == XHASH (y)) |
| 527 | 527 | ||
| 528 | /* Largest and smallest representable fixnum values. These are the C | 528 | /* Number of bits in a fixnum, including the sign bit. */ |
| 529 | values. */ | ||
| 530 | |||
| 531 | #ifdef USE_2_TAGS_FOR_INTS | 529 | #ifdef USE_2_TAGS_FOR_INTS |
| 532 | # define MOST_NEGATIVE_FIXNUM - ((EMACS_INT) 1 << VALBITS) | 530 | # define FIXNUM_BITS (VALBITS + 1) |
| 533 | # define MOST_POSITIVE_FIXNUM (((EMACS_INT) 1 << VALBITS) - 1) | ||
| 534 | /* Mask indicating the significant bits of a Lisp_Int. | ||
| 535 | I.e. (x & INTMASK) == XUINT (make_number (x)). */ | ||
| 536 | # define INTMASK ((((EMACS_INT) 1) << (VALBITS + 1)) - 1) | ||
| 537 | #else | 531 | #else |
| 538 | # define MOST_NEGATIVE_FIXNUM - ((EMACS_INT) 1 << (VALBITS - 1)) | 532 | # define FIXNUM_BITS VALBITS |
| 539 | # define MOST_POSITIVE_FIXNUM (((EMACS_INT) 1 << (VALBITS - 1)) - 1) | ||
| 540 | /* Mask indicating the significant bits of a Lisp_Int. | ||
| 541 | I.e. (x & INTMASK) == XUINT (make_number (x)). */ | ||
| 542 | # define INTMASK ((((EMACS_INT) 1) << VALBITS) - 1) | ||
| 543 | #endif | 533 | #endif |
| 544 | 534 | ||
| 535 | /* Mask indicating the significant bits of a fixnum. */ | ||
| 536 | #define INTMASK (((EMACS_INT) 1 << FIXNUM_BITS) - 1) | ||
| 537 | |||
| 538 | /* Largest and smallest representable fixnum values. These are the C | ||
| 539 | values. */ | ||
| 540 | #define MOST_POSITIVE_FIXNUM (INTMASK / 2) | ||
| 541 | #define MOST_NEGATIVE_FIXNUM (-1 - MOST_POSITIVE_FIXNUM) | ||
| 542 | |||
| 545 | /* Value is non-zero if I doesn't fit into a Lisp fixnum. It is | 543 | /* Value is non-zero if I doesn't fit into a Lisp fixnum. It is |
| 546 | written this way so that it also works if I is of unsigned | 544 | written this way so that it also works if I is of unsigned |
| 547 | type or if I is a NaN. */ | 545 | type or if I is a NaN. */ |
| @@ -1179,7 +1177,7 @@ struct Lisp_Hash_Table | |||
| 1179 | a special way (e.g. because of weakness). */ | 1177 | a special way (e.g. because of weakness). */ |
| 1180 | 1178 | ||
| 1181 | /* Number of key/value entries in the table. */ | 1179 | /* Number of key/value entries in the table. */ |
| 1182 | unsigned int count; | 1180 | EMACS_INT count; |
| 1183 | 1181 | ||
| 1184 | /* Vector of keys and values. The key of item I is found at index | 1182 | /* Vector of keys and values. The key of item I is found at index |
| 1185 | 2 * I, the value is found at index 2 * I + 1. | 1183 | 2 * I, the value is found at index 2 * I + 1. |
| @@ -1191,11 +1189,12 @@ struct Lisp_Hash_Table | |||
| 1191 | struct Lisp_Hash_Table *next_weak; | 1189 | struct Lisp_Hash_Table *next_weak; |
| 1192 | 1190 | ||
| 1193 | /* C function to compare two keys. */ | 1191 | /* C function to compare two keys. */ |
| 1194 | int (* cmpfn) (struct Lisp_Hash_Table *, Lisp_Object, | 1192 | int (*cmpfn) (struct Lisp_Hash_Table *, |
| 1195 | unsigned, Lisp_Object, unsigned); | 1193 | Lisp_Object, EMACS_UINT, |
| 1194 | Lisp_Object, EMACS_UINT); | ||
| 1196 | 1195 | ||
| 1197 | /* C function to compute hash code. */ | 1196 | /* C function to compute hash code. */ |
| 1198 | unsigned (* hashfn) (struct Lisp_Hash_Table *, Lisp_Object); | 1197 | EMACS_UINT (*hashfn) (struct Lisp_Hash_Table *, Lisp_Object); |
| 1199 | }; | 1198 | }; |
| 1200 | 1199 | ||
| 1201 | 1200 | ||
| @@ -2093,7 +2092,7 @@ extern Lisp_Object Vascii_canon_table; | |||
| 2093 | 2092 | ||
| 2094 | /* Number of bytes of structure consed since last GC. */ | 2093 | /* Number of bytes of structure consed since last GC. */ |
| 2095 | 2094 | ||
| 2096 | extern int consing_since_gc; | 2095 | extern EMACS_INT consing_since_gc; |
| 2097 | 2096 | ||
| 2098 | extern EMACS_INT gc_relative_threshold; | 2097 | extern EMACS_INT gc_relative_threshold; |
| 2099 | 2098 | ||
| @@ -2468,19 +2467,19 @@ extern void syms_of_syntax (void); | |||
| 2468 | 2467 | ||
| 2469 | /* Defined in fns.c */ | 2468 | /* Defined in fns.c */ |
| 2470 | extern Lisp_Object QCrehash_size, QCrehash_threshold; | 2469 | extern Lisp_Object QCrehash_size, QCrehash_threshold; |
| 2471 | extern int next_almost_prime (int); | 2470 | extern EMACS_INT next_almost_prime (EMACS_INT); |
| 2472 | extern Lisp_Object larger_vector (Lisp_Object, int, Lisp_Object); | 2471 | extern Lisp_Object larger_vector (Lisp_Object, EMACS_INT, Lisp_Object); |
| 2473 | extern void sweep_weak_hash_tables (void); | 2472 | extern void sweep_weak_hash_tables (void); |
| 2474 | extern Lisp_Object Qcursor_in_echo_area; | 2473 | extern Lisp_Object Qcursor_in_echo_area; |
| 2475 | extern Lisp_Object Qstring_lessp; | 2474 | extern Lisp_Object Qstring_lessp; |
| 2476 | extern Lisp_Object QCsize, QCtest, QCweakness, Qequal, Qeq, Qeql; | 2475 | extern Lisp_Object QCsize, QCtest, QCweakness, Qequal, Qeq, Qeql; |
| 2477 | unsigned sxhash (Lisp_Object, int); | 2476 | EMACS_UINT sxhash (Lisp_Object, int); |
| 2478 | Lisp_Object make_hash_table (Lisp_Object, Lisp_Object, Lisp_Object, | 2477 | Lisp_Object make_hash_table (Lisp_Object, Lisp_Object, Lisp_Object, |
| 2479 | Lisp_Object, Lisp_Object, Lisp_Object, | 2478 | Lisp_Object, Lisp_Object, Lisp_Object, |
| 2480 | Lisp_Object); | 2479 | Lisp_Object); |
| 2481 | int hash_lookup (struct Lisp_Hash_Table *, Lisp_Object, unsigned *); | 2480 | EMACS_INT hash_lookup (struct Lisp_Hash_Table *, Lisp_Object, EMACS_UINT *); |
| 2482 | int hash_put (struct Lisp_Hash_Table *, Lisp_Object, Lisp_Object, | 2481 | EMACS_INT hash_put (struct Lisp_Hash_Table *, Lisp_Object, Lisp_Object, |
| 2483 | unsigned); | 2482 | EMACS_UINT); |
| 2484 | void init_weak_hash_tables (void); | 2483 | void init_weak_hash_tables (void); |
| 2485 | extern void init_fns (void); | 2484 | extern void init_fns (void); |
| 2486 | EXFUN (Fmake_hash_table, MANY); | 2485 | EXFUN (Fmake_hash_table, MANY); |