aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc.c
diff options
context:
space:
mode:
authorRichard M. Stallman2003-01-06 00:45:45 +0000
committerRichard M. Stallman2003-01-06 00:45:45 +0000
commit42172a6ba0be481cced03016e1b88d180a518023 (patch)
tree9667c92082bf24cbda8b1c71bc4b08275ee60d3a /src/alloc.c
parent781d152abed2e3bf528130b6b2df30596af28372 (diff)
downloademacs-42172a6ba0be481cced03016e1b88d180a518023.tar.gz
emacs-42172a6ba0be481cced03016e1b88d180a518023.zip
(make_save_value): New function.
Diffstat (limited to 'src/alloc.c')
-rw-r--r--src/alloc.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/alloc.c b/src/alloc.c
index 5cb34b9ed45..b884bfabfb0 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -2631,6 +2631,26 @@ allocate_misc ()
2631 return val; 2631 return val;
2632} 2632}
2633 2633
2634/* Return a Lisp_Misc_Save_Value object containing POINTER and
2635 INTEGER. This is used to package C values to call record_unwind_protect.
2636 The unwind function can get the C values back using XSAVE_VALUE. */
2637
2638Lisp_Object
2639make_save_value (pointer, integer)
2640 void *pointer;
2641 int integer;
2642{
2643 register Lisp_Object val;
2644 register struct Lisp_Save_Value *p;
2645
2646 val = allocate_misc ();
2647 XMISCTYPE (val) = Lisp_Misc_Save_Value;
2648 p = XSAVE_VALUE (val);
2649 p->pointer = pointer;
2650 p->integer = integer;
2651 return val;
2652}
2653
2634DEFUN ("make-marker", Fmake_marker, Smake_marker, 0, 0, 0, 2654DEFUN ("make-marker", Fmake_marker, Smake_marker, 0, 0, 0,
2635 doc: /* Return a newly allocated marker which does not point at any place. */) 2655 doc: /* Return a newly allocated marker which does not point at any place. */)
2636 () 2656 ()