diff options
author | Nicholas Clark <nick@ccl4.org> | 2010-10-09 09:02:15 +0100 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2010-10-09 09:02:15 +0100 |
commit | 997daa56862a0fc771141f2bb18cab1d4d6fe8e3 (patch) | |
tree | bf850e04fefcd960772dc3ba7c5768539e775ef7 /gv.c | |
parent | ac4c972082d442917e12ef24ec829ae48334b0f3 (diff) | |
download | perl-997daa56862a0fc771141f2bb18cab1d4d6fe8e3.tar.gz |
Move the automatic instantiation of @AnyDBM_File::ISA to Perl_yylex()
case KEY_dbmopen in Perl_yylex() has always had special-case code to create
@AnyDBM_File::ISA, using GV_ADDMULTI. S_gv_magicalize_isa() [part of
Perl_gv_fetchpvn_flags()] has special case code to spot "AnyDBM_File::ISA"
being created with GV_ADDMULTI, and populate the variable if it is empty.
Grouping the special case code in one place makes more sense. Removing the
special case code from gv.c means that there is no longer a check clause in the
code path for *every* package's @ISA initialisation.
Diffstat (limited to 'gv.c')
-rw-r--r-- | gv.c | 15 |
1 files changed, 0 insertions, 15 deletions
@@ -978,21 +978,6 @@ S_gv_magicalize_isa(pTHX_ GV *gv, const char *nambeg, I32 add) GvMULTI_on(gv); sv_magic(MUTABLE_SV(av), MUTABLE_SV(gv), PERL_MAGIC_isa, NULL, 0); - /* NOTE: No support for tied ISA */ - if ((add & GV_ADDMULTI) && strEQ(nambeg,"AnyDBM_File::ISA") - && AvFILLp(av) == -1) - { - av_push(av, newSVpvs("NDBM_File")); - gv_stashpvs("NDBM_File", GV_ADD); - av_push(av, newSVpvs("DB_File")); - gv_stashpvs("DB_File", GV_ADD); - av_push(av, newSVpvs("GDBM_File")); - gv_stashpvs("GDBM_File", GV_ADD); - av_push(av, newSVpvs("SDBM_File")); - gv_stashpvs("SDBM_File", GV_ADD); - av_push(av, newSVpvs("ODBM_File")); - gv_stashpvs("ODBM_File", GV_ADD); - } } STATIC void |