The package names were wrong for some of the XS subs. I got rid of
Dave Rolsky [Fri, 29 Aug 2008 21:54:03 +0000 (21:54 +0000)]
Class::MOP::Method->name because it did not have the same behavior as
the Perl version. It can be redone later easily enough.

MOP.xs

diff --git a/MOP.xs b/MOP.xs
index 51a76da..6230e45 100644 (file)
--- a/MOP.xs
+++ b/MOP.xs
@@ -169,7 +169,7 @@ name(self)
         else
             ST(0) = &PL_sv_undef;
 
-MODULE = Class::MOP   PACKAGE = Class::Attribute
+MODULE = Class::MOP   PACKAGE = Class::MOP::Attribute
 
 SV *
 name(self)
@@ -182,18 +182,7 @@ name(self)
         else
             ST(0) = &PL_sv_undef;
 
-MODULE = Class::MOP   PACKAGE = Class::Method
-
-SV *
-name(self)
-    SV *self
-    PREINIT:
-        register HE *he;
-    PPCODE:
-        if (SvROK(self) && (he = hv_fetch_ent((HV *)SvRV(self), key_name, 0, hash_name)))
-            XPUSHs(HeVAL(he));
-        else
-            ST(0) = &PL_sv_undef;
+MODULE = Class::MOP   PACKAGE = Class::MOP::Method
 
 SV *
 body(self)