Add a constant, MOUSE_XS
[gitmo/Mouse.git] / lib / Mouse / Util.pm
index a226e1e..eea5f73 100644 (file)
@@ -52,6 +52,9 @@ BEGIN{
         $xs = eval sprintf("#line %d %s\n", __LINE__, $hack_mouse_file) . q{
             require XSLoader;
             XSLoader::load('Mouse', $VERSION);
+
+            *Mouse::Meta::Method::Constructor::XS::meta = \&meta;
+            *Mouse::Meta::Method::Destructor::XS::meta  = \&meta;
         };
         #warn $@ if $@;
     }
@@ -60,7 +63,7 @@ BEGIN{
         require 'Mouse/PurePerl.pm'; # we don't want to create its namespace
     }
 
-    *_MOUSE_XS = sub(){ $xs };
+    *MOUSE_XS = sub(){ $xs };
 }