diff options
Diffstat (limited to 'src/data.c')
| -rw-r--r-- | src/data.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/data.c b/src/data.c index fc50658dd7c..7110fb7eae7 100644 --- a/src/data.c +++ b/src/data.c | |||
| @@ -108,10 +108,12 @@ Lisp_Object | |||
| 108 | wrong_type_argument (predicate, value) | 108 | wrong_type_argument (predicate, value) |
| 109 | register Lisp_Object predicate, value; | 109 | register Lisp_Object predicate, value; |
| 110 | { | 110 | { |
| 111 | /* If VALUE is not even a valid Lisp object, abort here | 111 | /* If VALUE is not even a valid Lisp object, we'd want to abort here |
| 112 | where we can get a backtrace showing where it came from. */ | 112 | where we can get a backtrace showing where it came from. We used |
| 113 | if ((unsigned int) XTYPE (value) >= Lisp_Type_Limit) | 113 | to try and do that by checking the tagbits, but nowadays all |
| 114 | abort (); | 114 | tagbits are potentially valid. */ |
| 115 | /* if ((unsigned int) XTYPE (value) >= Lisp_Type_Limit) | ||
| 116 | * abort (); */ | ||
| 115 | 117 | ||
| 116 | xsignal2 (Qwrong_type_argument, predicate, value); | 118 | xsignal2 (Qwrong_type_argument, predicate, value); |
| 117 | } | 119 | } |
| @@ -184,7 +186,7 @@ for example, (type-of 1) returns `integer'. */) | |||
| 184 | { | 186 | { |
| 185 | switch (XTYPE (object)) | 187 | switch (XTYPE (object)) |
| 186 | { | 188 | { |
| 187 | case Lisp_Int: | 189 | case_Lisp_Int: |
| 188 | return Qinteger; | 190 | return Qinteger; |
| 189 | 191 | ||
| 190 | case Lisp_Symbol: | 192 | case Lisp_Symbol: |
| @@ -975,8 +977,10 @@ store_symval_forwarding (symbol, valcontents, newval, buf) | |||
| 975 | int offset = XBUFFER_OBJFWD (valcontents)->offset; | 977 | int offset = XBUFFER_OBJFWD (valcontents)->offset; |
| 976 | Lisp_Object type = XBUFFER_OBJFWD (valcontents)->slottype; | 978 | Lisp_Object type = XBUFFER_OBJFWD (valcontents)->slottype; |
| 977 | 979 | ||
| 978 | if (! NILP (type) && ! NILP (newval) | 980 | if (!(NILP (type) || NILP (newval) |
| 979 | && XTYPE (newval) != XINT (type)) | 981 | || (XINT (type) == LISP_INT_TAG |
| 982 | ? INTEGERP (newval) | ||
| 983 | : XTYPE (newval) == XINT (type)))) | ||
| 980 | buffer_slot_type_mismatch (newval, XINT (type)); | 984 | buffer_slot_type_mismatch (newval, XINT (type)); |
| 981 | 985 | ||
| 982 | if (buf == NULL) | 986 | if (buf == NULL) |