diff options
| author | Karl Heuer | 1994-09-27 03:27:31 +0000 |
|---|---|---|
| committer | Karl Heuer | 1994-09-27 03:27:31 +0000 |
| commit | 6e54b3de90ae06d2baa063e96776608cc6c23156 (patch) | |
| tree | c0043aa80d07f61bd3df8d38ece619e4b9a9f7c6 /src | |
| parent | e687453f6e222aa19080885204c462394579ed58 (diff) | |
| download | emacs-6e54b3de90ae06d2baa063e96776608cc6c23156.tar.gz emacs-6e54b3de90ae06d2baa063e96776608cc6c23156.zip | |
(quotify_arg, Fcall_interactively, Fprefix_numeric_value): Use type test
macros.
Diffstat (limited to 'src')
| -rw-r--r-- | src/callint.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/callint.c b/src/callint.c index fa0099bd4d6..e36b6c147d8 100644 --- a/src/callint.c +++ b/src/callint.c | |||
| @@ -114,7 +114,7 @@ Lisp_Object | |||
| 114 | quotify_arg (exp) | 114 | quotify_arg (exp) |
| 115 | register Lisp_Object exp; | 115 | register Lisp_Object exp; |
| 116 | { | 116 | { |
| 117 | if (XTYPE (exp) != Lisp_Int && XTYPE (exp) != Lisp_String | 117 | if (!INTEGERP (exp) && !STRINGP (exp) |
| 118 | && !NILP (exp) && !EQ (exp, Qt)) | 118 | && !NILP (exp) && !EQ (exp, Qt)) |
| 119 | return Fcons (Qquote, Fcons (exp, Qnil)); | 119 | return Fcons (Qquote, Fcons (exp, Qnil)); |
| 120 | 120 | ||
| @@ -200,7 +200,7 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 200 | 200 | ||
| 201 | retry: | 201 | retry: |
| 202 | 202 | ||
| 203 | if (XTYPE (function) == Lisp_Symbol) | 203 | if (SYMBOLP (function)) |
| 204 | enable = Fget (function, Qenable_recursive_minibuffers); | 204 | enable = Fget (function, Qenable_recursive_minibuffers); |
| 205 | 205 | ||
| 206 | fun = indirect_function (function); | 206 | fun = indirect_function (function); |
| @@ -212,7 +212,7 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 212 | or go to `lose' if not interactive, or go to `retry' | 212 | or go to `lose' if not interactive, or go to `retry' |
| 213 | to specify a different function, or set either STRING or SPECS. */ | 213 | to specify a different function, or set either STRING or SPECS. */ |
| 214 | 214 | ||
| 215 | if (XTYPE (fun) == Lisp_Subr) | 215 | if (SUBRP (fun)) |
| 216 | { | 216 | { |
| 217 | string = (unsigned char *) XSUBR (fun)->prompt; | 217 | string = (unsigned char *) XSUBR (fun)->prompt; |
| 218 | if (!string) | 218 | if (!string) |
| @@ -225,7 +225,7 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 225 | /* Let SPECS (which is nil) be used as the args. */ | 225 | /* Let SPECS (which is nil) be used as the args. */ |
| 226 | string = 0; | 226 | string = 0; |
| 227 | } | 227 | } |
| 228 | else if (XTYPE (fun) == Lisp_Compiled) | 228 | else if (COMPILEDP (fun)) |
| 229 | { | 229 | { |
| 230 | if (XVECTOR (fun)->size <= COMPILED_INTERACTIVE) | 230 | if (XVECTOR (fun)->size <= COMPILED_INTERACTIVE) |
| 231 | goto lose; | 231 | goto lose; |
| @@ -253,7 +253,7 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 253 | goto lose; | 253 | goto lose; |
| 254 | 254 | ||
| 255 | /* If either specs or string is set to a string, use it. */ | 255 | /* If either specs or string is set to a string, use it. */ |
| 256 | if (XTYPE (specs) == Lisp_String) | 256 | if (STRINGP (specs)) |
| 257 | { | 257 | { |
| 258 | /* Make a copy of string so that if a GC relocates specs, | 258 | /* Make a copy of string so that if a GC relocates specs, |
| 259 | `string' will still be valid. */ | 259 | `string' will still be valid. */ |
| @@ -329,9 +329,9 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 329 | 329 | ||
| 330 | event = XVECTOR (this_command_keys)->contents[next_event]; | 330 | event = XVECTOR (this_command_keys)->contents[next_event]; |
| 331 | if (EVENT_HAS_PARAMETERS (event) | 331 | if (EVENT_HAS_PARAMETERS (event) |
| 332 | && XTYPE (event = XCONS (event)->cdr) == Lisp_Cons | 332 | && (event = XCONS (event)->car, CONSP (event)) |
| 333 | && XTYPE (event = XCONS (event)->car) == Lisp_Cons | 333 | && (event = XCONS (event)->car, CONSP (event)) |
| 334 | && XTYPE (event = XCONS (event)->car) == Lisp_Window) | 334 | && (event = XCONS (event)->car), WINDOWP (event)) |
| 335 | { | 335 | { |
| 336 | if (MINI_WINDOW_P (XWINDOW (event)) | 336 | if (MINI_WINDOW_P (XWINDOW (event)) |
| 337 | && ! (minibuf_level > 0 && EQ (event, minibuf_window))) | 337 | && ! (minibuf_level > 0 && EQ (event, minibuf_window))) |
| @@ -464,7 +464,7 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 464 | case 'e': /* The invoking event. */ | 464 | case 'e': /* The invoking event. */ |
| 465 | if (next_event >= this_command_key_count) | 465 | if (next_event >= this_command_key_count) |
| 466 | error ("%s must be bound to an event with parameters", | 466 | error ("%s must be bound to an event with parameters", |
| 467 | (XTYPE (function) == Lisp_Symbol | 467 | (SYMBOLP (function) |
| 468 | ? (char *) XSYMBOL (function)->name->data | 468 | ? (char *) XSYMBOL (function)->name->data |
| 469 | : "command")); | 469 | : "command")); |
| 470 | args[i] = XVECTOR (this_command_keys)->contents[next_event++]; | 470 | args[i] = XVECTOR (this_command_keys)->contents[next_event++]; |
| @@ -554,7 +554,7 @@ Otherwise, this is done only if an arg is read using the minibuffer.") | |||
| 554 | if (varies[i] == 0) | 554 | if (varies[i] == 0) |
| 555 | arg_from_tty = 1; | 555 | arg_from_tty = 1; |
| 556 | 556 | ||
| 557 | if (NILP (visargs[i]) && XTYPE (args[i]) == Lisp_String) | 557 | if (NILP (visargs[i]) && STRINGP (args[i])) |
| 558 | visargs[i] = args[i]; | 558 | visargs[i] = args[i]; |
| 559 | 559 | ||
| 560 | tem = (unsigned char *) index (tem, '\n'); | 560 | tem = (unsigned char *) index (tem, '\n'); |
| @@ -609,7 +609,7 @@ Its numeric meaning is what you would get from `(interactive \"p\")'.") | |||
| 609 | XSETINT (val, -1); | 609 | XSETINT (val, -1); |
| 610 | else if (CONSP (raw)) | 610 | else if (CONSP (raw)) |
| 611 | XSETINT (val, XINT (XCONS (raw)->car)); | 611 | XSETINT (val, XINT (XCONS (raw)->car)); |
| 612 | else if (XTYPE (raw) == Lisp_Int) | 612 | else if (INTEGERP (raw)) |
| 613 | val = raw; | 613 | val = raw; |
| 614 | else | 614 | else |
| 615 | XFASTINT (val) = 1; | 615 | XFASTINT (val) = 1; |