Change 33016 by [EMAIL PROTECTED] on 2008/01/20 21:05:26
Move retop first in structs block_sub, block_format and block_eval.
This simplifies some code in Perl_deb_stack_all().
Affected files ...
... //depot/perl/cop.h#152 edit
... //depot/perl/deb.c#57 edit
Differences ...
==== //depot/perl/cop.h#152 (text) ====
Index: perl/cop.h
--- perl/cop.h#151~33015~ 2008-01-20 12:40:38.000000000 -0800
+++ perl/cop.h 2008-01-20 13:05:26.000000000 -0800
@@ -279,8 +279,9 @@
/* subroutine context */
struct block_sub {
- CV * cv;
OP * retop; /* op to execute on exit from sub */
+ /* Above here is the same for sub, format and eval. */
+ CV * cv;
U8 hasargs;
U8 lval; /* XXX merge lval and hasargs? */
/* Above here is the same for sub and format. */
@@ -293,8 +294,9 @@
/* format context */
struct block_format {
- CV * cv;
OP * retop; /* op to execute on exit from sub */
+ /* Above here is the same for sub, format and eval. */
+ CV * cv;
U8 hasargs;
U8 lval; /* XXX merge lval and hasargs? */
/* Above here is the same for sub and format. */
@@ -394,13 +396,14 @@
/* eval context */
struct block_eval {
+ OP * retop; /* op to execute on exit from eval */
+ /* Above here is the same for sub, format and eval. */
U8 old_in_eval;
U16 old_op_type;
SV * old_namesv;
OP * old_eval_root;
SV * cur_text;
CV * cv;
- OP * retop; /* op to execute on exit from eval */
JMPENV * cur_top_env; /* value of PL_top_env when eval CX created */
};
==== //depot/perl/deb.c#57 (text) ====
Index: perl/deb.c
--- perl/deb.c#56~32237~ 2007-11-07 15:23:27.000000000 -0800
+++ perl/deb.c 2008-01-20 13:05:26.000000000 -0800
@@ -293,8 +293,7 @@
if (CxTYPE(cx) == CXt_EVAL || CxTYPE(cx) == CXt_SUB
|| CxTYPE(cx) == CXt_FORMAT)
{
- const OP * const retop = (CxTYPE(cx) == CXt_EVAL)
- ? cx->blk_eval.retop : cx->blk_sub.retop;
+ const OP * const retop = cx->blk_sub.retop;
PerlIO_printf(Perl_debug_log, " retop=%s\n",
retop ? OP_NAME(retop) : "(null)"
End of Patch.