Mercurial > emacs
comparison src/eval.c @ 60418:887436be5f78
(unwind_to_catch): Use UNBLOCK_INPUT_TO.
(Feval, Ffuncall): Use CHECK_CONS_LIST.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Sun, 06 Mar 2005 16:02:47 +0000 |
parents | d9e761d51f98 |
children | 4c111b6f6378 29e773288013 |
comparison
equal
deleted
inserted
replaced
60417:4a07536ef0de | 60418:887436be5f78 |
---|---|
1174 /* Save the value in the tag. */ | 1174 /* Save the value in the tag. */ |
1175 catch->val = value; | 1175 catch->val = value; |
1176 | 1176 |
1177 /* Restore certain special C variables. */ | 1177 /* Restore certain special C variables. */ |
1178 set_poll_suppress_count (catch->poll_suppress_count); | 1178 set_poll_suppress_count (catch->poll_suppress_count); |
1179 interrupt_input_blocked = catch->interrupt_input_blocked; | 1179 UNBLOCK_INPUT_TO (catch->interrupt_input_blocked); |
1180 handling_signal = 0; | 1180 handling_signal = 0; |
1181 immediate_quit = 0; | 1181 immediate_quit = 0; |
1182 | 1182 |
1183 do | 1183 do |
1184 { | 1184 { |
2064 Lisp_Object args_left; | 2064 Lisp_Object args_left; |
2065 register int i, maxargs; | 2065 register int i, maxargs; |
2066 | 2066 |
2067 args_left = original_args; | 2067 args_left = original_args; |
2068 numargs = Flength (args_left); | 2068 numargs = Flength (args_left); |
2069 | |
2070 CHECK_CONS_LIST (); | |
2069 | 2071 |
2070 if (XINT (numargs) < XSUBR (fun)->min_args || | 2072 if (XINT (numargs) < XSUBR (fun)->min_args || |
2071 (XSUBR (fun)->max_args >= 0 && XSUBR (fun)->max_args < XINT (numargs))) | 2073 (XSUBR (fun)->max_args >= 0 && XSUBR (fun)->max_args < XINT (numargs))) |
2072 return Fsignal (Qwrong_number_of_arguments, Fcons (fun, Fcons (numargs, Qnil))); | 2074 return Fsignal (Qwrong_number_of_arguments, Fcons (fun, Fcons (numargs, Qnil))); |
2073 | 2075 |
2188 val = apply_lambda (fun, original_args, 1); | 2190 val = apply_lambda (fun, original_args, 1); |
2189 else | 2191 else |
2190 return Fsignal (Qinvalid_function, Fcons (fun, Qnil)); | 2192 return Fsignal (Qinvalid_function, Fcons (fun, Qnil)); |
2191 } | 2193 } |
2192 done: | 2194 done: |
2195 CHECK_CONS_LIST (); | |
2196 | |
2193 lisp_eval_depth--; | 2197 lisp_eval_depth--; |
2194 if (backtrace.debug_on_exit) | 2198 if (backtrace.debug_on_exit) |
2195 val = call_debugger (Fcons (Qexit, Fcons (val, Qnil))); | 2199 val = call_debugger (Fcons (Qexit, Fcons (val, Qnil))); |
2196 backtrace_list = backtrace.next; | 2200 backtrace_list = backtrace.next; |
2197 | 2201 |
2744 | 2748 |
2745 fun = Findirect_function (fun); | 2749 fun = Findirect_function (fun); |
2746 | 2750 |
2747 if (SUBRP (fun)) | 2751 if (SUBRP (fun)) |
2748 { | 2752 { |
2753 CHECK_CONS_LIST (); | |
2754 | |
2749 if (numargs < XSUBR (fun)->min_args | 2755 if (numargs < XSUBR (fun)->min_args |
2750 || (XSUBR (fun)->max_args >= 0 && XSUBR (fun)->max_args < numargs)) | 2756 || (XSUBR (fun)->max_args >= 0 && XSUBR (fun)->max_args < numargs)) |
2751 { | 2757 { |
2752 XSETFASTINT (lisp_numargs, numargs); | 2758 XSETFASTINT (lisp_numargs, numargs); |
2753 return Fsignal (Qwrong_number_of_arguments, Fcons (fun, Fcons (lisp_numargs, Qnil))); | 2759 return Fsignal (Qwrong_number_of_arguments, Fcons (fun, Fcons (lisp_numargs, Qnil))); |
2842 } | 2848 } |
2843 else | 2849 else |
2844 return Fsignal (Qinvalid_function, Fcons (fun, Qnil)); | 2850 return Fsignal (Qinvalid_function, Fcons (fun, Qnil)); |
2845 } | 2851 } |
2846 done: | 2852 done: |
2853 CHECK_CONS_LIST (); | |
2847 lisp_eval_depth--; | 2854 lisp_eval_depth--; |
2848 if (backtrace.debug_on_exit) | 2855 if (backtrace.debug_on_exit) |
2849 val = call_debugger (Fcons (Qexit, Fcons (val, Qnil))); | 2856 val = call_debugger (Fcons (Qexit, Fcons (val, Qnil))); |
2850 backtrace_list = backtrace.next; | 2857 backtrace_list = backtrace.next; |
2851 return val; | 2858 return val; |