SVphv_REHASH can use the same flag bit as SVf_FAKE. This allows
Nicholas Clark [Tue, 14 Mar 2006 15:21:54 +0000 (15:21 +0000)]
0x10000000 (SVf_AMAGIC) to be set on all 16 SV types, which seems to
be necessary to fix subtle bugs involving reblessing and overloading.

p4raw-id: //depot/perl@27496

sv.h

diff --git a/sv.h b/sv.h
index d91957c..4461a3c 100644 (file)
--- a/sv.h
+++ b/sv.h
@@ -307,8 +307,9 @@ perform the upgrade if necessary.  See C<svtype>.
                                              fact an offset [SvREPADTMP(sv)]
                                           5: On a pad name SV, that slot in the
                                              frame AV is a REFCNT'ed reference
-                                             to a lexical from "outside".
-                                       */
+                                             to a lexical from "outside". */
+#define SVphv_REHASH   SVf_FAKE        /* 6: On a PVHV, hash values are being
+                                             recalculated */
 #define SVf_OOK                0x02000000      /* has valid offset value
                                           For a PVHV this means that a
                                           hv_aux struct is present after the
@@ -334,8 +335,6 @@ perform the upgrade if necessary.  See C<svtype>.
 /* Some private flags. */
 
 /* PVHV */
-#define SVphv_REHASH   0x10000000      /* PVHV is recalculating hash values */
-/* PVHV */
 #define SVphv_SHAREKEYS 0x20000000     /* PVHV
                                           keys live on shared string table */
 /* PVNV, PVMG, PVGV, presumably only inside pads */