don't attempt to require Scalar::Util if we're going this far trying to optimize
Daisuke Maki [Wed, 3 Dec 2008 08:35:05 +0000 (08:35 +0000)]
lib/Mouse/Util.pm

index 9d87d5a..e4b8b07 100644 (file)
@@ -175,7 +175,7 @@ BEGIN {
         #   weaken
         # other functions need to be loaded from our respective sources
 
-        if (defined &Scalar::Util::openhandle || eval { require Scalar::Util; 1 }) {
+        if (defined &Scalar::Util::openhandle) {
             *openhandle = \&Scalar::Util::openhandle;
         } else {
             # XXX - room for improvement