mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-21 20:20:24 +02:00
* continuations.c, debug.[ch], eval.c, gscm.c init.c, root.c,
throw.c: Renamed last_debug_info_frame -> scm_last_debug_frame.
This commit is contained in:
parent
02ba201059
commit
1646d37b71
5 changed files with 17 additions and 13 deletions
|
@ -118,7 +118,7 @@ scm_make_cont (answer)
|
||||||
*dst++ = *src++;
|
*dst++ = *src++;
|
||||||
#endif /* def CHEAP_CONTINUATIONS */
|
#endif /* def CHEAP_CONTINUATIONS */
|
||||||
#ifdef DEBUG_EXTENSIONS
|
#ifdef DEBUG_EXTENSIONS
|
||||||
SCM_DFRAME (cont) = last_debug_info_frame;
|
SCM_DFRAME (cont) = scm_last_debug_frame;
|
||||||
#endif
|
#endif
|
||||||
return cont;
|
return cont;
|
||||||
}
|
}
|
||||||
|
@ -185,7 +185,7 @@ scm_dynthrow (a)
|
||||||
#endif
|
#endif
|
||||||
#endif /* ndef CHEAP_CONTINUATIONS */
|
#endif /* ndef CHEAP_CONTINUATIONS */
|
||||||
#ifdef DEBUG_EXTENSIONS
|
#ifdef DEBUG_EXTENSIONS
|
||||||
last_debug_info_frame = SCM_DFRAME (cont);
|
scm_last_debug_frame = SCM_DFRAME (cont);
|
||||||
#endif
|
#endif
|
||||||
SCM_THROW_VALUE(cont) = val;
|
SCM_THROW_VALUE(cont) = val;
|
||||||
longjmp (SCM_JMPBUF (cont), 1);
|
longjmp (SCM_JMPBUF (cont), 1);
|
||||||
|
|
|
@ -529,7 +529,7 @@ scm_expr_stack (obj)
|
||||||
scm_debug_frame *frame;
|
scm_debug_frame *frame;
|
||||||
long offset = 0;
|
long offset = 0;
|
||||||
if (SCM_UNBNDP (obj))
|
if (SCM_UNBNDP (obj))
|
||||||
frame = last_debug_info_frame;
|
frame = scm_last_debug_frame;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
SCM_ASSERT (SCM_NIMP (obj), obj, SCM_ARG1, s_expr_stack);
|
SCM_ASSERT (SCM_NIMP (obj), obj, SCM_ARG1, s_expr_stack);
|
||||||
|
|
|
@ -127,7 +127,9 @@ typedef struct scm_debug_frame
|
||||||
scm_debug_info vect[1];
|
scm_debug_info vect[1];
|
||||||
} scm_debug_frame;
|
} scm_debug_frame;
|
||||||
|
|
||||||
extern scm_debug_frame *last_debug_info_frame;
|
#ifndef USE_THREADS
|
||||||
|
extern scm_debug_frame *scm_last_debug_frame;
|
||||||
|
#endif
|
||||||
|
|
||||||
#define SCM_TAILREC (1L << 10)
|
#define SCM_TAILREC (1L << 10)
|
||||||
#define SCM_TRACED_FRAME (1L << 9)
|
#define SCM_TRACED_FRAME (1L << 9)
|
||||||
|
|
|
@ -1324,14 +1324,16 @@ SCM (*scm_ceval_ptr) (SCM exp, SCM env);
|
||||||
SCM (*scm_ceval_ptr) ();
|
SCM (*scm_ceval_ptr) ();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* last_debug_info_frame contains a pointer to the last debugging
|
/* scm_last_debug_frame contains a pointer to the last debugging
|
||||||
* information stack frame. It is accessed very often from the
|
* information stack frame. It is accessed very often from the
|
||||||
* debugging evaluator, so it should probably not be indirectly
|
* debugging evaluator, so it should probably not be indirectly
|
||||||
* addressed. Better to save and restore it from the current root at
|
* addressed. Better to save and restore it from the current root at
|
||||||
* any stack swaps.
|
* any stack swaps.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
scm_debug_frame *last_debug_info_frame;
|
#ifndef USE_THREADS
|
||||||
|
scm_debug_frame *scm_last_debug_frame;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* scm_debug_eframe_size is the number of slots available for pseudo
|
/* scm_debug_eframe_size is the number of slots available for pseudo
|
||||||
* stack frames at each real stack frame.
|
* stack frames at each real stack frame.
|
||||||
|
@ -1447,10 +1449,10 @@ SCM_CEVAL (x, env)
|
||||||
scm_debug_info vect[scm_debug_eframe_size];
|
scm_debug_info vect[scm_debug_eframe_size];
|
||||||
scm_debug_info *info;
|
scm_debug_info *info;
|
||||||
} debug;
|
} debug;
|
||||||
debug.prev = last_debug_info_frame;
|
debug.prev = scm_last_debug_frame;
|
||||||
debug.status = scm_debug_eframe_size;
|
debug.status = scm_debug_eframe_size;
|
||||||
debug.info = &debug.vect[0];
|
debug.info = &debug.vect[0];
|
||||||
last_debug_info_frame = (scm_debug_frame *) &debug;
|
scm_last_debug_frame = (scm_debug_frame *) &debug;
|
||||||
#endif
|
#endif
|
||||||
#ifdef EVAL_STACK_CHECKING
|
#ifdef EVAL_STACK_CHECKING
|
||||||
if (SCM_STACK_OVERFLOW_P ((SCM_STACKITEM *) &proc)
|
if (SCM_STACK_OVERFLOW_P ((SCM_STACKITEM *) &proc)
|
||||||
|
@ -2305,7 +2307,7 @@ exit:
|
||||||
scm_ithrow (scm_i_exit_frame, scm_cons2 (t.arg1, proc, SCM_EOL), 0);
|
scm_ithrow (scm_i_exit_frame, scm_cons2 (t.arg1, proc, SCM_EOL), 0);
|
||||||
}
|
}
|
||||||
ret:
|
ret:
|
||||||
last_debug_info_frame = debug.prev;
|
scm_last_debug_frame = debug.prev;
|
||||||
return proc;
|
return proc;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
@ -2427,11 +2429,11 @@ SCM_APPLY (proc, arg1, args)
|
||||||
#ifdef DEBUG_EXTENSIONS
|
#ifdef DEBUG_EXTENSIONS
|
||||||
#ifdef DEVAL
|
#ifdef DEVAL
|
||||||
scm_debug_frame debug;
|
scm_debug_frame debug;
|
||||||
debug.prev = last_debug_info_frame;
|
debug.prev = scm_last_debug_frame;
|
||||||
debug.status = SCM_APPLYFRAME;
|
debug.status = SCM_APPLYFRAME;
|
||||||
debug.vect[0].a.proc = proc;
|
debug.vect[0].a.proc = proc;
|
||||||
debug.vect[0].a.args = SCM_EOL;
|
debug.vect[0].a.args = SCM_EOL;
|
||||||
last_debug_info_frame = &debug;
|
scm_last_debug_frame = &debug;
|
||||||
#else
|
#else
|
||||||
if (SCM_DEBUGGINGP)
|
if (SCM_DEBUGGINGP)
|
||||||
return scm_dapply (proc, arg1, args);
|
return scm_dapply (proc, arg1, args);
|
||||||
|
@ -2622,7 +2624,7 @@ exit:
|
||||||
scm_ithrow (scm_i_exit_frame, scm_cons2 (arg1, proc, SCM_EOL), 0);
|
scm_ithrow (scm_i_exit_frame, scm_cons2 (arg1, proc, SCM_EOL), 0);
|
||||||
}
|
}
|
||||||
ret:
|
ret:
|
||||||
last_debug_info_frame = debug.prev;
|
scm_last_debug_frame = debug.prev;
|
||||||
return proc;
|
return proc;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
@ -221,7 +221,7 @@ _eval_port (answer, toplvl, port, printp)
|
||||||
*/
|
*/
|
||||||
SCM_BASE (scm_rootcont) = (SCM_STACKITEM *) & i;
|
SCM_BASE (scm_rootcont) = (SCM_STACKITEM *) & i;
|
||||||
#ifdef DEBUG_EXTENSIONS
|
#ifdef DEBUG_EXTENSIONS
|
||||||
SCM_DFRAME (scm_rootcont) = last_debug_info_frame = 0;
|
SCM_DFRAME (scm_rootcont) = scm_last_debug_frame = 0;
|
||||||
#endif
|
#endif
|
||||||
saved_inp = scm_cur_inp;
|
saved_inp = scm_cur_inp;
|
||||||
i = setjmp (SCM_JMPBUF (scm_rootcont));
|
i = setjmp (SCM_JMPBUF (scm_rootcont));
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue