Rename Extending::Recipe2 to Extending::Debugging_BaseClassRole
[gitmo/Moose.git] / lib / Moose / Util / TypeConstraints.pm
index e713562..b44a0eb 100644 (file)
@@ -165,6 +165,9 @@ sub create_class_type_constraint {
               . " and cannot be created again in "
               . $pkg_defined_in )
         }
+        else {
+            return $type;
+        }
     }
 
     my %options = (
@@ -198,6 +201,9 @@ sub create_role_type_constraint {
               . " and cannot be created again in "
               . $pkg_defined_in )
         }
+        else {
+            return $type;
+        }
     }
 
     my %options = (
@@ -1116,7 +1122,7 @@ The subroutine should return a code string suitable for inlining. You can
 assume that the check will be wrapped in parentheses when it is inlined.
 
 The inlined code should include any checks that your type's parent types
-do. If your parent type constraint defines its own inlning, you can simply use
+do. If your parent type constraint defines its own inlining, you can simply use
 that to avoid repeating code. For example, here is the inlining code for the
 C<Value> type, which is a subtype of C<Defined>: