[Moose-commits] r7669 - Class-MOP/trunk
rafl at code2.0beta.co.uk
rafl at code2.0beta.co.uk
Sat Feb 14 02:59:10 GMT 2009
Author: rafl
Date: 2009-02-13 18:59:10 -0800 (Fri, 13 Feb 2009)
New Revision: 7669
Modified:
Class-MOP/trunk/MOP.xs
Log:
Don't call GvCV on something that's not a GV.
Modified: Class-MOP/trunk/MOP.xs
===================================================================
--- Class-MOP/trunk/MOP.xs 2009-02-14 01:22:10 UTC (rev 7668)
+++ Class-MOP/trunk/MOP.xs 2009-02-14 02:59:10 UTC (rev 7669)
@@ -354,7 +354,7 @@
HV *stash;
char *key;
I32 keylen;
- GV *gv;
+ SV *gv;
PPCODE:
if (!SvPOK(klass) || !SvCUR(klass)) {
XSRETURN_NO;
@@ -390,7 +390,7 @@
}
(void)hv_iterinit(stash);
- while ((gv = (GV *)hv_iternextsv(stash, &key, &keylen))) {
+ while ((gv = hv_iternextsv(stash, &key, &keylen))) {
if (keylen <= 0) {
continue;
}
@@ -399,7 +399,7 @@
continue;
}
- if (GvCV(gv)) {
+ if (!isGV(gv) || GvCV(gv)) {
XSRETURN_YES;
}
}
More information about the Moose-commits
mailing list