In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/bb3b7d7b82b9d2ba93dc99ecf064f0c701ef2c59?hp=c85f23b236fa90fedd9cceed2da12481184d5bbf>
- Log ----------------------------------------------------------------- commit bb3b7d7b82b9d2ba93dc99ecf064f0c701ef2c59 Author: Daniel Dragan <[email protected]> Date: Thu Jul 2 17:22:09 2015 -0400 all SV inheriter types have DEBUG_LEAKING_SCALARS data, so always show it I noticed AV *s in my C debugger didn't the sv_debug_* members, but if I casted the AV * to a SV * in my C debugger using a expession in my watch tab, all the info was there. Put the DEBUG_LEAKING_SCALARS in _SV_HEAD_UNION so the sv_debug_* members appear everywhere (CV/HV/AV/etc), not just for SVs. ----------------------------------------------------------------------- Summary of changes: sv.h | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/sv.h b/sv.h index 49cafe4..0076ddd 100644 --- a/sv.h +++ b/sv.h @@ -212,20 +212,24 @@ typedef struct hek HEK; HE** svu_hash; \ GP* svu_gp; \ PerlIO *svu_fp; \ - } sv_u + } sv_u \ + _SV_HEAD_DEBUG +#ifdef DEBUG_LEAKING_SCALARS +#define _SV_HEAD_DEBUG ;\ + PERL_BITFIELD32 sv_debug_optype:9; /* the type of OP that allocated us */ \ + PERL_BITFIELD32 sv_debug_inpad:1; /* was allocated in a pad for an OP */ \ + PERL_BITFIELD32 sv_debug_line:16; /* the line where we were allocated */ \ + UV sv_debug_serial; /* serial number of sv allocation */ \ + char * sv_debug_file; /* the file where we were allocated */ \ + SV * sv_debug_parent /* what we were cloned from (ithreads)*/ +#else +#define _SV_HEAD_DEBUG +#endif struct STRUCT_SV { /* struct sv { */ _SV_HEAD(void*); _SV_HEAD_UNION; -#ifdef DEBUG_LEAKING_SCALARS - PERL_BITFIELD32 sv_debug_optype:9; /* the type of OP that allocated us */ - PERL_BITFIELD32 sv_debug_inpad:1; /* was allocated in a pad for an OP */ - PERL_BITFIELD32 sv_debug_line:16; /* the line where we were allocated */ - UV sv_debug_serial; /* serial number of sv allocation */ - char * sv_debug_file; /* the file where we were allocated */ - SV * sv_debug_parent; /* what we were cloned from (ithreads)*/ -#endif }; struct gv { -- Perl5 Master Repository
