From: gfx Date: Mon, 17 Aug 2009 04:36:24 +0000 (+0900) Subject: Add a comment. X-Git-Tag: 0.92_01~21 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3b7c6e11b98be9aafc1d31d328b17bd5753c6121;p=gitmo%2FClass-MOP.git Add a comment. --- diff --git a/xs/Package.xs b/xs/Package.xs index 1086e21..06e93ed 100644 --- a/xs/Package.xs +++ b/xs/Package.xs @@ -346,6 +346,10 @@ CODE: && isGV(CvGV(subr)) && strEQ(GvNAME(CvGV(subr)), "__ANON__")){ + /* NOTE: + A gv "has-a" cv, but a cv refers to a gv as a (pseudo) weak ref. + so we can replace CvGV with no SvREFCNT_inc/dec. + */ CvGV(subr) = gv; CvANON_off(subr); }