From: Nicholas Clark Date: Sat, 7 Oct 2006 22:24:28 +0000 (+0000) Subject: No need to create a new magic vtable if it's all 0 pointers. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=0ca9e7c5f00427e141fad33150dcf6f077317af1;p=p5sagit%2Fp5-mst-13.2.git No need to create a new magic vtable if it's all 0 pointers. [And these are function pointers, so they're not NULL :-)] p4raw-id: //depot/perl@28962 --- diff --git a/XSUB.h b/XSUB.h index e4cc816..de5d33b 100644 --- a/XSUB.h +++ b/XSUB.h @@ -391,7 +391,6 @@ Rethrows a previously caught exception. See L. # define VTBL_uvar &PL_vtbl_uvar # define VTBL_defelem &PL_vtbl_defelem # define VTBL_regexp &PL_vtbl_regexp -# define VTBL_regdata_names &PL_vtbl_regdata_names # define VTBL_regdata &PL_vtbl_regdata # define VTBL_regdatum &PL_vtbl_regdatum # ifdef USE_LOCALE_COLLATE diff --git a/perl.h b/perl.h index 3338ea2..4fb64ed 100644 --- a/perl.h +++ b/perl.h @@ -4832,18 +4832,6 @@ MGVTBL_SET( ); MGVTBL_SET( - PL_vtbl_regdata_names, - NULL, - NULL, - NULL, - NULL, - NULL, - NULL, - NULL, - NULL -); - -MGVTBL_SET( PL_vtbl_regdata, NULL, NULL, diff --git a/sv.c b/sv.c index 4fa4498..5fe95c2 100644 --- a/sv.c +++ b/sv.c @@ -4532,9 +4532,6 @@ Perl_sv_magic(pTHX_ register SV *sv, SV *obj, int how, const char *name, I32 nam case PERL_MAGIC_regdata: vtable = &PL_vtbl_regdata; break; - case PERL_MAGIC_regdata_names: - vtable = &PL_vtbl_regdata_names; - break; case PERL_MAGIC_regdatum: vtable = &PL_vtbl_regdatum; break; @@ -4597,6 +4594,7 @@ Perl_sv_magic(pTHX_ register SV *sv, SV *obj, int how, const char *name, I32 nam case PERL_MAGIC_vec: vtable = &PL_vtbl_vec; break; + case PERL_MAGIC_regdata_names: case PERL_MAGIC_arylen_p: case PERL_MAGIC_rhash: case PERL_MAGIC_symtab: