diff options
author | Dmitry Antipov <dmantipov@yandex.ru> | 2015-01-16 14:41:20 +0300 |
---|---|---|
committer | Dmitry Antipov <dmantipov@yandex.ru> | 2015-01-16 14:41:20 +0300 |
commit | 7ee2733f1ecd3d4f2bd782aa802b090c77fbb135 (patch) | |
tree | 630d68f6cbd86350adeddd59ba87eb105ff2ad0b | |
parent | b689b906f27c326c4c7531d4987ffaae49b50dcd (diff) | |
download | emacs-7ee2733f1ecd3d4f2bd782aa802b090c77fbb135.tar.gz |
Tiny lisp.h cleanup
* lisp.h (XTERMINAL): Add eassert.
* process.c (make_lisp_proc): Now static here.
-rw-r--r-- | src/ChangeLog | 3 | ||||
-rw-r--r-- | src/lisp.h | 8 | ||||
-rw-r--r-- | src/process.c | 5 |
3 files changed, 10 insertions, 6 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 63da5cbd972..0601e5a5aed 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -15,6 +15,9 @@ * window.c (allocate_window): Now static here. Use ALLOCATE_ZEROED_PSEUDOVECTOR. Add comment. + * lisp.h (XTERMINAL): Add eassert. + * process.c (make_lisp_proc): Now static here. + 2015-01-16 Paul Eggert <eggert@cs.ucla.edu> Give up on -Wsuggest-attribute=const diff --git a/src/lisp.h b/src/lisp.h index fd0a0342cf8..7c7d3f3e2e5 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -608,6 +608,7 @@ INLINE bool SUBRP (Lisp_Object); INLINE bool (SYMBOLP) (Lisp_Object); INLINE bool (VECTORLIKEP) (Lisp_Object); INLINE bool WINDOWP (Lisp_Object); +INLINE bool TERMINALP (Lisp_Object); INLINE struct Lisp_Save_Value *XSAVE_VALUE (Lisp_Object); INLINE struct Lisp_Symbol *(XSYMBOL) (Lisp_Object); INLINE void *(XUNTAG) (Lisp_Object, int); @@ -998,6 +999,7 @@ XWINDOW (Lisp_Object a) INLINE struct terminal * XTERMINAL (Lisp_Object a) { + eassert (TERMINALP (a)); return XUNTAG (a, Lisp_Vectorlike); } @@ -1060,12 +1062,6 @@ builtin_lisp_symbol (int index) return make_lisp_symbol (lispsym + index); } -INLINE Lisp_Object -make_lisp_proc (struct Lisp_Process *p) -{ - return make_lisp_ptr (p, Lisp_Vectorlike); -} - #define XSETINT(a, b) ((a) = make_number (b)) #define XSETFASTINT(a, b) ((a) = make_natnum (b)) #define XSETCONS(a, b) ((a) = make_lisp_ptr (b, Lisp_Cons)) diff --git a/src/process.c b/src/process.c index 30380548210..0789f20f1d2 100644 --- a/src/process.c +++ b/src/process.c @@ -422,6 +422,11 @@ pset_write_queue (struct Lisp_Process *p, Lisp_Object val) } +static Lisp_Object +make_lisp_proc (struct Lisp_Process *p) +{ + return make_lisp_ptr (p, Lisp_Vectorlike); +} static struct fd_callback_data { |