aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGerd Moellmann1999-11-05 21:30:08 +0000
committerGerd Moellmann1999-11-05 21:30:08 +0000
commitbcf28080666110d736763aa4ad083a0f129e986e (patch)
treeb79bf25aa094efde96b74eaaffdc47c9787eb582 /src
parent630686c871f4ce1f6498c5675d0b7ce008387d12 (diff)
downloademacs-bcf28080666110d736763aa4ad083a0f129e986e.tar.gz
emacs-bcf28080666110d736763aa4ad083a0f129e986e.zip
(struct catchtag): Add member byte_stack.
(internal_catch, Fcondition_case, internal_condition_case) (internal_condition_case_1: Save value of byte_stack_list in catchtag. (unwind_to_catch): Restore byte_stack_list from catchtag.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog20
-rw-r--r--src/eval.c6
2 files changed, 26 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 55a100fbfb6..23c10cc4205 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,5 +1,25 @@
11999-11-05 Gerd Moellmann <gerd@gnu.org> 11999-11-05 Gerd Moellmann <gerd@gnu.org>
2 2
3 * alloc.c (Fgarbage_collect): Call mark_byte_stack and
4 relocate_byte_pcs.
5 (init_alloc_once, init_alloc): Set byte_stack_list to null.
6
7 * eval.c (struct catchtag): Add member byte_stack.
8 (internal_catch, Fcondition_case, internal_condition_case)
9 (internal_condition_case_1: Save value of byte_stack_list in
10 catchtag.
11 (unwind_to_catch): Restore byte_stack_list from catchtag.
12
13 * lisp.h: Add prototypes for new functions in bytecode.c.
14 Add extern declaration for byte_stack_list.
15
16 * bytecode.c (struct byte_stack): New.
17 (byte_stack_list, mark_byte_stack, relocate_byte_pcs): New
18 (BEFORE_POTENTIAL_GC, AFTER_POTENTIAL_GC): New.
19 (FETCH, PUSH, POP, DISCARD, TOP, MAYBE_GC): Rewritten.
20 (HANDLE_RELOCATION): Removed.
21 (Fbyte_code): Use byte_stack structures.
22
3 * filelock.c (Ffile_locked_p): Make FILENAME a required argument. 23 * filelock.c (Ffile_locked_p): Make FILENAME a required argument.
4 24
5 * buffer.c (syms_of_buffer): Extend documentation of 25 * buffer.c (syms_of_buffer): Extend documentation of
diff --git a/src/eval.c b/src/eval.c
index 1f067963d15..f911433e712 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -81,6 +81,7 @@ struct catchtag
81 int lisp_eval_depth; 81 int lisp_eval_depth;
82 int pdlcount; 82 int pdlcount;
83 int poll_suppress_count; 83 int poll_suppress_count;
84 struct byte_stack *byte_stack;
84 }; 85 };
85 86
86struct catchtag *catchlist; 87struct catchtag *catchlist;
@@ -922,6 +923,7 @@ internal_catch (tag, func, arg)
922 c.pdlcount = specpdl_ptr - specpdl; 923 c.pdlcount = specpdl_ptr - specpdl;
923 c.poll_suppress_count = poll_suppress_count; 924 c.poll_suppress_count = poll_suppress_count;
924 c.gcpro = gcprolist; 925 c.gcpro = gcprolist;
926 c.byte_stack = byte_stack_list;
925 catchlist = &c; 927 catchlist = &c;
926 928
927 /* Call FUNC. */ 929 /* Call FUNC. */
@@ -974,6 +976,7 @@ unwind_to_catch (catch, value)
974 } 976 }
975 while (! last_time); 977 while (! last_time);
976 978
979 byte_stack_list = catch->byte_stack;
977 gcprolist = catch->gcpro; 980 gcprolist = catch->gcpro;
978#ifdef DEBUG_GCPRO 981#ifdef DEBUG_GCPRO
979 if (gcprolist != 0) 982 if (gcprolist != 0)
@@ -1085,6 +1088,7 @@ See also the function `signal' for more info.")
1085 c.pdlcount = specpdl_ptr - specpdl; 1088 c.pdlcount = specpdl_ptr - specpdl;
1086 c.poll_suppress_count = poll_suppress_count; 1089 c.poll_suppress_count = poll_suppress_count;
1087 c.gcpro = gcprolist; 1090 c.gcpro = gcprolist;
1091 c.byte_stack = byte_stack_list;
1088 if (_setjmp (c.jmp)) 1092 if (_setjmp (c.jmp))
1089 { 1093 {
1090 if (!NILP (h.var)) 1094 if (!NILP (h.var))
@@ -1145,6 +1149,7 @@ internal_condition_case (bfun, handlers, hfun)
1145 c.pdlcount = specpdl_ptr - specpdl; 1149 c.pdlcount = specpdl_ptr - specpdl;
1146 c.poll_suppress_count = poll_suppress_count; 1150 c.poll_suppress_count = poll_suppress_count;
1147 c.gcpro = gcprolist; 1151 c.gcpro = gcprolist;
1152 c.byte_stack = byte_stack_list;
1148 if (_setjmp (c.jmp)) 1153 if (_setjmp (c.jmp))
1149 { 1154 {
1150 return (*hfun) (c.val); 1155 return (*hfun) (c.val);
@@ -1184,6 +1189,7 @@ internal_condition_case_1 (bfun, arg, handlers, hfun)
1184 c.pdlcount = specpdl_ptr - specpdl; 1189 c.pdlcount = specpdl_ptr - specpdl;
1185 c.poll_suppress_count = poll_suppress_count; 1190 c.poll_suppress_count = poll_suppress_count;
1186 c.gcpro = gcprolist; 1191 c.gcpro = gcprolist;
1192 c.byte_stack = byte_stack_list;
1187 if (_setjmp (c.jmp)) 1193 if (_setjmp (c.jmp))
1188 { 1194 {
1189 return (*hfun) (c.val); 1195 return (*hfun) (c.val);