From: Stevan Little Date: Wed, 19 Mar 2008 15:39:17 +0000 (+0000) Subject: rebless instance now returns the instance too X-Git-Tag: 0_64~79 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=830b326c5fe3312bb086d0db36337d751c1337d5;p=gitmo%2FClass-MOP.git rebless instance now returns the instance too --- diff --git a/Changes b/Changes index 1ce55b7..6ff83eb 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,11 @@ Revision history for Perl extension Class-MOP. +0.55 + * Class::MOP::Class + - rebless_instance now returns the instance + it has just blessed, this is mostly to + facilitate chaining + 0.54 Fri. March, 14, 2008 * Class::MOP metaclass.pm diff --git a/README b/README index 4eea3e1..c458ed8 100644 --- a/README +++ b/README @@ -1,4 +1,4 @@ -Class::MOP version 0.54 +Class::MOP version 0.55 =========================== See the individual module documentation for more information diff --git a/lib/Class/MOP.pm b/lib/Class/MOP.pm index bcaf6a8..b8d6808 100644 --- a/lib/Class/MOP.pm +++ b/lib/Class/MOP.pm @@ -14,7 +14,7 @@ use Class::MOP::Method; use Class::MOP::Immutable; BEGIN { - our $VERSION = '0.54'; + our $VERSION = '0.55'; our $AUTHORITY = 'cpan:STEVAN'; use XSLoader; diff --git a/lib/Class/MOP/Class.pm b/lib/Class/MOP/Class.pm index 126f788..e299e53 100644 --- a/lib/Class/MOP/Class.pm +++ b/lib/Class/MOP/Class.pm @@ -12,7 +12,7 @@ use Carp 'confess'; use Scalar::Util 'blessed', 'reftype', 'weaken'; use Sub::Name 'subname'; -our $VERSION = '0.29'; +our $VERSION = '0.30'; our $AUTHORITY = 'cpan:STEVAN'; use base 'Class::MOP::Module'; @@ -439,6 +439,8 @@ sub rebless_instance { foreach my $attr ($self->compute_all_applicable_attributes) { $attr->initialize_instance_slot($meta_instance, $instance, \%params); } + + $instance; } # Inheritance