Mercurial > emacs
comparison src/eval.c @ 112023:ac49e05bfcf2
Remove unused declarations
* src/buffer.c: Remove unused declarations.
* src/buffer.h: Likewise.
* src/charset.h: Likewise.
* src/composite.h: Likewise.
* src/dispextern.h: Likewise.
* src/dispnew.c: Likewise.
* src/font.h: Likewise.
* src/fontset.c: Likewise.
* src/fontset.h: Likewise.
* src/intervals.h: Likewise.
* src/keymap.h: Likewise.
* src/lisp.h: Likewise.
* src/syntax.c: Likewise.
* src/syntax.h: Likewise.
* src/termhooks.h: Likewise.
* src/window.h: Likewise.
* src/xsettings.h: Likewise.
* src/xterm.c: Likewise.
* src/xterm.h: Likewise.
* src/chartab.c (sub_char_table_ref): Make static.
* src/dispnew.c (line_hash_code, required_matrix_height)
(required_matrix_width): Likewise.
* src/eval.c (interactive_p, apply_lambda): Likewise.
* src/fns.c (string_make_multibyte, copy_hash_table, hash_clear):
Likewise.
* src/font.c (QCadstyle, QCregistry, font_make_spec)
(font_parse_fcname, font_encode_char, font_at): Likewise.
* src/frame.c (x_frame_get_arg): Likewise.
* src/keymap.c (get_keyelt): Likewise.
* src/lread.c (read_filtered_event): Likewise.
* src/print.c (write_string_1): Likewise.
* src/window.c (delete_window, window_height, window_width)
(foreach_window): Likewise.
* src/xrdb.c (x_get_customization_string, x_get_resource): Likewise.
* src/xterm.c (x_scroll_bar_clear, xembed_set_info)
(xembed_send_message): Likewise.
* src/eval.c (run_hook_list_with_args): Delete.
* src/font.c (font_unparse_gtkname, font_update_lface): Likewise.
* src/terminal.c (get_terminal_param): Likewise.
* src/xterm.c (x_alloc_lighter_color_for_widget): Likewise.
author | Andreas Schwab <schwab@linux-m68k.org> |
---|---|
date | Mon, 27 Dec 2010 18:29:38 +0100 |
parents | a5a188ddc758 |
children | 417b1e4d63cd |
comparison
equal
deleted
inserted
replaced
112022:5753dd68911a | 112023:ac49e05bfcf2 |
---|---|
165 | 165 |
166 Lisp_Object Vmacro_declaration_function; | 166 Lisp_Object Vmacro_declaration_function; |
167 | 167 |
168 static Lisp_Object funcall_lambda (Lisp_Object, int, Lisp_Object*); | 168 static Lisp_Object funcall_lambda (Lisp_Object, int, Lisp_Object*); |
169 static void unwind_to_catch (struct catchtag *, Lisp_Object) NO_RETURN; | 169 static void unwind_to_catch (struct catchtag *, Lisp_Object) NO_RETURN; |
170 static int interactive_p (int); | |
171 static Lisp_Object apply_lambda (Lisp_Object, Lisp_Object, int); | |
170 | 172 |
171 void | 173 void |
172 init_eval_once (void) | 174 init_eval_once (void) |
173 { | 175 { |
174 specpdl_size = 50; | 176 specpdl_size = 50; |
579 call-interactively. | 581 call-interactively. |
580 | 582 |
581 EXCLUDE_SUBRS_P non-zero means always return 0 if the function | 583 EXCLUDE_SUBRS_P non-zero means always return 0 if the function |
582 called is a built-in. */ | 584 called is a built-in. */ |
583 | 585 |
584 int | 586 static int |
585 interactive_p (int exclude_subrs_p) | 587 interactive_p (int exclude_subrs_p) |
586 { | 588 { |
587 struct backtrace *btp; | 589 struct backtrace *btp; |
588 Lisp_Object fun; | 590 Lisp_Object fun; |
589 | 591 |
2683 UNGCPRO; | 2685 UNGCPRO; |
2684 return ret; | 2686 return ret; |
2685 } | 2687 } |
2686 } | 2688 } |
2687 | 2689 |
2688 /* Run a hook symbol ARGS[0], but use FUNLIST instead of the actual | |
2689 present value of that symbol. | |
2690 Call each element of FUNLIST, | |
2691 passing each of them the rest of ARGS. | |
2692 The caller (or its caller, etc) must gcpro all of ARGS, | |
2693 except that it isn't necessary to gcpro ARGS[0]. */ | |
2694 | |
2695 Lisp_Object | |
2696 run_hook_list_with_args (Lisp_Object funlist, int nargs, Lisp_Object *args) | |
2697 { | |
2698 Lisp_Object sym; | |
2699 Lisp_Object val; | |
2700 Lisp_Object globals; | |
2701 struct gcpro gcpro1, gcpro2, gcpro3; | |
2702 | |
2703 sym = args[0]; | |
2704 globals = Qnil; | |
2705 GCPRO3 (sym, val, globals); | |
2706 | |
2707 for (val = funlist; CONSP (val); val = XCDR (val)) | |
2708 { | |
2709 if (EQ (XCAR (val), Qt)) | |
2710 { | |
2711 /* t indicates this hook has a local binding; | |
2712 it means to run the global binding too. */ | |
2713 | |
2714 for (globals = Fdefault_value (sym); | |
2715 CONSP (globals); | |
2716 globals = XCDR (globals)) | |
2717 { | |
2718 args[0] = XCAR (globals); | |
2719 /* In a global value, t should not occur. If it does, we | |
2720 must ignore it to avoid an endless loop. */ | |
2721 if (!EQ (args[0], Qt)) | |
2722 Ffuncall (nargs, args); | |
2723 } | |
2724 } | |
2725 else | |
2726 { | |
2727 args[0] = XCAR (val); | |
2728 Ffuncall (nargs, args); | |
2729 } | |
2730 } | |
2731 UNGCPRO; | |
2732 return Qnil; | |
2733 } | |
2734 | |
2735 /* Run the hook HOOK, giving each function the two args ARG1 and ARG2. */ | 2690 /* Run the hook HOOK, giving each function the two args ARG1 and ARG2. */ |
2736 | 2691 |
2737 void | 2692 void |
2738 run_hook_with_args_2 (Lisp_Object hook, Lisp_Object arg1, Lisp_Object arg2) | 2693 run_hook_with_args_2 (Lisp_Object hook, Lisp_Object arg1, Lisp_Object arg2) |
2739 { | 2694 { |
3061 val = call_debugger (Fcons (Qexit, Fcons (val, Qnil))); | 3016 val = call_debugger (Fcons (Qexit, Fcons (val, Qnil))); |
3062 backtrace_list = backtrace.next; | 3017 backtrace_list = backtrace.next; |
3063 return val; | 3018 return val; |
3064 } | 3019 } |
3065 | 3020 |
3066 Lisp_Object | 3021 static Lisp_Object |
3067 apply_lambda (Lisp_Object fun, Lisp_Object args, int eval_flag) | 3022 apply_lambda (Lisp_Object fun, Lisp_Object args, int eval_flag) |
3068 { | 3023 { |
3069 Lisp_Object args_left; | 3024 Lisp_Object args_left; |
3070 Lisp_Object numargs; | 3025 Lisp_Object numargs; |
3071 register Lisp_Object *arg_vector; | 3026 register Lisp_Object *arg_vector; |