Mercurial > hg > xemacs-beta
changeset 2834:172fb92bd156
[xemacs-hg @ 2005-06-28 11:32:13 by crestani]
2005-06-28 Marcus Crestani <crestani@xemacs.org>
* gpmevent.c: Remove workaround.
* gpmevent.c (Fgpm_enable): Use GET_DEFUN_LISP_OBJECT to get
Lisp_Object of a built-in function.
* gpmevent.c (syms_of_gpmevent): Remove workaround.
* lisp.h (GET_DEFUN_LISP_OBJECT): New. Returns Lisp_Object of a
DEFUN.
* tooltalk.c (init_tooltalk): Use GET_DEFUN_LISP_OBJECT to get
Lisp_Object of a built-in function.
author | crestani |
---|---|
date | Tue, 28 Jun 2005 11:32:15 +0000 |
parents | 3a7b185f1a2e |
children | ae83ac9c29b3 |
files | src/ChangeLog src/gpmevent.c src/lisp.h src/tooltalk.c |
diffstat | 4 files changed, 17 insertions(+), 20 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog Mon Jun 27 21:51:16 2005 +0000 +++ b/src/ChangeLog Tue Jun 28 11:32:15 2005 +0000 @@ -1,3 +1,14 @@ +2005-06-28 Marcus Crestani <crestani@xemacs.org> + + * gpmevent.c: Remove workaround. + * gpmevent.c (Fgpm_enable): Use GET_DEFUN_LISP_OBJECT to get + Lisp_Object of a built-in function. + * gpmevent.c (syms_of_gpmevent): Remove workaround. + * lisp.h (GET_DEFUN_LISP_OBJECT): New. Returns Lisp_Object of a + DEFUN. + * tooltalk.c (init_tooltalk): Use GET_DEFUN_LISP_OBJECT to get + Lisp_Object of a built-in function. + 2005-06-26 Aidan Kehoe <kehoea@parhasard.net> * event-stream.c (command_builder_find_leaf):
--- a/src/gpmevent.c Mon Jun 27 21:51:16 2005 +0000 +++ b/src/gpmevent.c Tue Jun 28 11:32:15 2005 +0000 @@ -59,10 +59,6 @@ static Lisp_Object gpm_event_queue; static Lisp_Object gpm_event_queue_tail; -#ifdef MC_ALLOC -static Lisp_Object MC_ALLOC_Freceive_gpm_event; -#endif /* MC_ALLOC */ - struct __gpm_state { int gpm_tried; @@ -597,11 +593,7 @@ { rval = 0; Fprocess_kill_without_query (gpm_process, Qnil); -#ifdef MC_ALLOC - gpm_filter = MC_ALLOC_Freceive_gpm_event; -#else /* not MC_ALLOC */ - gpm_filter = wrap_subr (&SFreceive_gpm_event); -#endif /* not MC_ALLOC */ + gpm_filter = GET_DEFUN_LISP_OBJECT (Freceive_gpm_event); set_process_filter (gpm_process, gpm_filter, 1, 0); /* Keep track of the device for later */ @@ -629,17 +621,7 @@ void syms_of_gpmevent (void) { -#ifdef MC_ALLOC -#define DEFSUBR_receive_gpm_event(Fname) \ -do { \ - DEFSUBR_MC_ALLOC (Fname); \ - defsubr (S##Fname); \ - MC_ALLOC_Freceive_gpm_event = wrap_subr (S##Fname); \ -} while (0) - DEFSUBR_receive_gpm_event (Freceive_gpm_event); -#else /* not MC_ALLOC */ DEFSUBR (Freceive_gpm_event); -#endif /* not MC_ALLOC */ DEFSUBR (Fgpm_enable); DEFSUBR (Fgpm_enabled_p); }
--- a/src/lisp.h Mon Jun 27 21:51:16 2005 +0000 +++ b/src/lisp.h Tue Jun 28 11:32:15 2005 +0000 @@ -3016,6 +3016,8 @@ }; \ static struct Lisp_Subr *S##Fname; \ DOESNT_RETURN_TYPE (Lisp_Object) Fname (DEFUN_##max_args arglist) +#define GET_DEFUN_LISP_OBJECT(Fname) \ + wrap_subr (S##Fname); #else /* not MC_ALLOC */ #define DEFUN(lname, Fname, min_args, max_args, prompt, arglist) \ Lisp_Object Fname (EXFUN_##max_args); \ @@ -3056,6 +3058,8 @@ (lisp_fn_t) Fname \ }; \ DOESNT_RETURN_TYPE (Lisp_Object) Fname (DEFUN_##max_args arglist) +#define GET_DEFUN_LISP_OBJECT(Fname) \ + wrap_subr (&S##Fname); #endif /* not MC_ALLOC */ /* Heavy ANSI C preprocessor hackery to get DEFUN to declare a
--- a/src/tooltalk.c Mon Jun 27 21:51:16 2005 +0000 +++ b/src/tooltalk.c Tue Jun 28 11:32:15 2005 +0000 @@ -1289,7 +1289,7 @@ { /* Don't ask the user for confirmation when exiting Emacs */ Fprocess_kill_without_query (lp, Qnil); - fil = wrap_subr (&SFreceive_tooltalk_message); + fil = GET_DEFUN_LISP_OBJECT (Freceive_tooltalk_message); set_process_filter (lp, fil, 1, 0); } else