This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Remove core references to SVt_BIND
authorKarl Williamson <public@khwilliamson.com>
Thu, 9 May 2013 00:27:42 +0000 (18:27 -0600)
committerKarl Williamson <public@khwilliamson.com>
Sat, 18 May 2013 15:16:31 +0000 (09:16 -0600)
This scalar type was unused.  This is the first step in using the slot
freed up for another purpose.  The slot is now occupied by a temporary
placeholder named SVt_DUMMY.

dist/Storable/Storable.pm
dist/Storable/Storable.xs
dump.c
sv.c
sv.h

index bb1083d..0cc5d16 100644 (file)
@@ -21,7 +21,7 @@ package Storable; @ISA = qw(Exporter);
 
 use vars qw($canonical $forgive_me $VERSION);
 
-$VERSION = '2.41';
+$VERSION = '2.42';
 
 BEGIN {
     if (eval { local $SIG{__DIE__}; require Log::Agent; 1 }) {
index eca061a..08641cd 100644 (file)
@@ -3469,7 +3469,7 @@ static int sv_type(pTHX_ SV *sv)
        case SVt_PVCV:
                return svis_CODE;
 #if PERL_VERSION > 8
-       /* case SVt_BIND: */
+       /* case SVt_DUMMY: */
 #endif
        default:
                break;
diff --git a/dump.c b/dump.c
index a25740b..70ac487 100644 (file)
--- a/dump.c
+++ b/dump.c
@@ -30,7 +30,7 @@
 
 static const char* const svtypenames[SVt_LAST] = {
     "NULL",
-    "BIND",
+    "DUMMY",
     "IV",
     "NV",
     "PV",
@@ -50,7 +50,7 @@ static const char* const svtypenames[SVt_LAST] = {
 
 static const char* const svshorttypenames[SVt_LAST] = {
     "UNDEF",
-    "BIND",
+    "DUMMY",
     "IV",
     "NV",
     "PV",
@@ -2771,8 +2771,8 @@ Perl_sv_xmlpeek(pTHX_ SV *sv)
     case SVt_PVGV:
        sv_catpv(t, " GV=\"");
        break;
-    case SVt_BIND:
-       sv_catpv(t, " BIND=\"");
+    case SVt_DUMMY:
+       sv_catpv(t, " DUMMY=\"");
        break;
     case SVt_REGEXP:
        sv_catpv(t, " REGEXP=\"");
diff --git a/sv.c b/sv.c
index 3736ba8..ba09305 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -884,7 +884,7 @@ static const struct body_details bodies_by_type[] = {
     /* The bind placeholder pretends to be an RV for now.
        Also it's marked as "can't upgrade" to stop anyone using it before it's
        implemented.  */
-    { 0, 0, 0, SVt_BIND, TRUE, NONV, NOARENA, 0 },
+    { 0, 0, 0, SVt_DUMMY, TRUE, NONV, NOARENA, 0 },
 
     /* IVs are in the head, so the allocation size is 0.  */
     { 0,
@@ -4073,7 +4073,7 @@ Perl_sv_setsv_flags(pTHX_ SV *dstr, SV* sstr, const I32 flags)
        }
        break;
 
-       /* case SVt_BIND: */
+       /* case SVt_DUMMY: */
     case SVt_PVLV:
     case SVt_PVGV:
     case SVt_PVMG:
@@ -6136,7 +6136,7 @@ Perl_sv_clear(pTHX_ SV *const orig_sv)
                SvREFCNT_dec(SvSTASH(sv));
        }
        switch (type) {
-           /* case SVt_BIND: */
+           /* case SVt_DUMMY: */
        case SVt_PVIO:
            if (IoIFP(sv) &&
                IoIFP(sv) != PerlIO_stdin() &&
@@ -9406,7 +9406,7 @@ Perl_sv_reftype(pTHX_ const SV *const sv, const int ob)
                                    ? "GLOB" : "SCALAR");
        case SVt_PVFM:          return "FORMAT";
        case SVt_PVIO:          return "IO";
-       case SVt_BIND:          return "BIND";
+       case SVt_DUMMY:         return "DUMMY";
        case SVt_REGEXP:        return "REGEXP";
        default:                return "UNKNOWN";
        }
@@ -12133,7 +12133,7 @@ S_sv_dup_common(pTHX_ const SV *const sstr, CLONE_PARAMS *const param)
        SvANY(dstr)     = new_XNV();
        SvNV_set(dstr, SvNVX(sstr));
        break;
-       /* case SVt_BIND: */
+       /* case SVt_DUMMY: */
     default:
        {
            /* These are all the types that need complex bodies allocating.  */
diff --git a/sv.h b/sv.h
index 7baef34..98aef7a 100644 (file)
--- a/sv.h
+++ b/sv.h
@@ -22,7 +22,6 @@ in the C<svtype> enum.  Test these flags with the C<SvTYPE> macro.
 The types are:
 
     SVt_NULL
-    SVt_BIND (unused)
     SVt_IV
     SVt_NV
     SVt_RV
@@ -120,7 +119,7 @@ Type flag for I/O objects.  See L</svtype>.
 
 typedef enum {
        SVt_NULL,       /* 0 */
-       SVt_BIND,       /* 1 */
+       SVt_DUMMY,      /* 1 */
        SVt_IV,         /* 2 */
        SVt_NV,         /* 3 */
        /* RV was here, before it was merged with IV.  */