From: Stevan Little Date: Wed, 28 May 2008 00:47:22 +0000 (+0000) Subject: adding error message X-Git-Tag: 0_55~135 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d3308256b154f169e81ebd695c9185aef6209e0b;p=gitmo%2FMoose.git adding error message --- diff --git a/Changes b/Changes index 7d61bd7..357ff2b 100644 --- a/Changes +++ b/Changes @@ -6,6 +6,12 @@ Revision history for Perl extension Moose - now use the get_all_package_symbols from the updated Class::MOP, test suite is now 10 seconds faster + + * Moose::Meta::Method::Destructor + Moose::Meta::Method::Constructor + - added more descriptive error message to help + keep people from wasting time tracking an error + that is easily fixed by upgrading. 0.45 Saturday, May 24, 2008 * Moose diff --git a/lib/Moose/Meta/Method/Constructor.pm b/lib/Moose/Meta/Method/Constructor.pm index 230e315..3527301 100644 --- a/lib/Moose/Meta/Method/Constructor.pm +++ b/lib/Moose/Meta/Method/Constructor.pm @@ -7,7 +7,7 @@ use warnings; use Carp 'confess'; use Scalar::Util 'blessed', 'weaken', 'looks_like_number'; -our $VERSION = '0.10'; +our $VERSION = '0.11'; our $AUTHORITY = 'cpan:STEVAN'; use base 'Moose::Meta::Method', @@ -21,7 +21,7 @@ sub new { || confess "You must pass a hash of options"; ($options{package_name} && $options{name}) - || confess "You must supply the package_name and name parameters"; + || confess "You must supply the package_name and name parameters $Class::MOP::Method::UPGRADE_ERROR_TEXT"; my $self = bless { # from our superclass diff --git a/lib/Moose/Meta/Method/Destructor.pm b/lib/Moose/Meta/Method/Destructor.pm index 77a439b..3e1f7c8 100644 --- a/lib/Moose/Meta/Method/Destructor.pm +++ b/lib/Moose/Meta/Method/Destructor.pm @@ -7,7 +7,7 @@ use warnings; use Carp 'confess'; use Scalar::Util 'blessed', 'weaken'; -our $VERSION = '0.03'; +our $VERSION = '0.02'; our $AUTHORITY = 'cpan:STEVAN'; use base 'Moose::Meta::Method', @@ -21,7 +21,7 @@ sub new { || confess "You must pass a hash of options"; ($options{package_name} && $options{name}) - || confess "You must supply the package_name and name parameters"; + || confess "You must supply the package_name and name parameters $Class::MOP::Method::UPGRADE_ERROR_TEXT"; my $self = bless { # from our superclass