From: gfx Date: Sat, 9 Jan 2010 08:11:42 +0000 (+0900) Subject: Remove long-deprecated features X-Git-Tag: 0.46~8 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo%2FMouse.git;a=commitdiff_plain;h=ac3bb63341584a1de80eb26340d9b877624c1834 Remove long-deprecated features --- diff --git a/lib/Mouse/Meta/Attribute.pm b/lib/Mouse/Meta/Attribute.pm index 61e9dba..609fa19 100644 --- a/lib/Mouse/Meta/Attribute.pm +++ b/lib/Mouse/Meta/Attribute.pm @@ -249,15 +249,6 @@ sub _throw_type_constraint_error { ); } -sub coerce_constraint { # DEPRECATED - my $type = $_[0]->{type_constraint} - or return $_[1]; - - Carp::cluck("coerce_constraint() has been deprecated, which was an internal utility anyway"); - - return Mouse::Util::TypeConstraints->typecast_constraints($_[0]->associated_class->name, $type, $_[1]); -} - sub clone_and_inherit_options{ my($self, %args) = @_; diff --git a/lib/Mouse/Meta/TypeConstraint.pm b/lib/Mouse/Meta/TypeConstraint.pm index fb7047b..a761d14 100644 --- a/lib/Mouse/Meta/TypeConstraint.pm +++ b/lib/Mouse/Meta/TypeConstraint.pm @@ -24,13 +24,6 @@ sub new { my $check = delete $args{optimized}; - if($args{_compiled_type_constraint}){ - Carp::cluck("'_compiled_type_constraint' has been deprecated, use 'optimized' instead") - if Mouse::Util::_MOUSE_VERBOSE; - - $check = $args{_compiled_type_constraint}; - } - if($check){ $args{hand_optimized_type_constraint} = $check; $args{compiled_type_constraint} = $check; diff --git a/lib/Mouse/Util/TypeConstraints.pm b/lib/Mouse/Util/TypeConstraints.pm index 83fa4d3..3896182 100644 --- a/lib/Mouse/Util/TypeConstraints.pm +++ b/lib/Mouse/Util/TypeConstraints.pm @@ -199,15 +199,6 @@ sub duck_type { ); } -sub typecast_constraints { # DEPRECATED - my($class, $pkg, $type, $value) = @_; - Carp::croak("wrong arguments count") unless @_ == 4; - - Carp::cluck("typecast_constraints() has been deprecated, which was an internal utility anyway"); - - return $type->coerce($value); -} - sub enum { my($name, %valid);