From: Jesse Luehrs <doy@tozt.net>
Date: Sun, 14 Nov 2010 16:43:53 +0000 (-0600)
Subject: a couple more comments
X-Git-Tag: 0.14~14
X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9aa6fe4f1c0b7719085d51b26b2237f071b1a94f;p=gitmo%2FPackage-Stash-XS.git

a couple more comments
---

diff --git a/Stash.xs b/Stash.xs
index 2eb03a0..44e7ce4 100644
--- a/Stash.xs
+++ b/Stash.xs
@@ -39,6 +39,8 @@
 #define GvCVOK(g) GvCVu(g) /* XXX: should this really be GvCVu? or GvCV? */
 #define GvIOOK(g) GvIO(g)
 
+/* see above - don't let scalar slots become unpopulated, this breaks
+ * assumptions in core */
 #if PERL_VERSION < 10
 #define GvSetSV(g,v) do {               \
     SV *_v = (SV*)(v);                  \
@@ -461,6 +463,9 @@ add_symbol(self, variable, initial=NULL, ...)
     }
 */
 
+    /* GV_ADDMULTI rather than GV_ADD because otherwise you get 'used only
+     * once' warnings in some situations... i can't reproduce this, but CMOP
+     * triggers it */
     glob = gv_fetchsv(name, GV_ADDMULTI, vartype_to_svtype(variable.type));
 
     if (initial) {