use strict;
use warnings;
-our $VERSION = '0.01';
+our $VERSION = '0.02';
use 5.006;
use Sub::Exporter;
use Carp 'confess';
use Scalar::Util 'blessed';
+use Class::Method::Modifiers ();
use Mouse::Meta::Attribute;
use Mouse::Meta::Class;
blessed => sub {
return \&blessed;
},
+
+ before => sub {
+ return \&Class::Method::Modifiers::before;
+ },
+
+ after => sub {
+ return \&Class::Method::Modifiers::after;
+ },
+
+ around => sub {
+ return \&Class::Method::Modifiers::around;
+ },
);
my $exporter = Sub::Exporter::build_exporter({
=head1 VERSION
-Version 0.01 released 10 Jun 08
+Version 0.02 released 11 Jun 08
=head1 SYNOPSIS
has 'z' => (is => 'rw', isa => 'Int');
- # not implemented yet :)
- #after 'clear' => sub {
- # my $self = shift;
- # $self->z(0);
- #};
+ after 'clear' => sub {
+ my $self = shift;
+ $self->z(0);
+ };
=head1 DESCRIPTION
Compatibility with Moose has been the utmost concern. Fewer than 1% of the
tests fail when run against Moose instead of Mouse. Mouse code coverage is also
-over 99%. Even the error messages are taken from Moose.
+over 99%. Even the error messages are taken from Moose. The Mouse code just
+runs the test suite 3x-4x faster.
The idea is that, if you need the extra power, you should be able to run
-C<s/Mouse/Moose/g> on your codebase and have nothing break.
+C<s/Mouse/Moose/g> on your codebase and have nothing break. To that end,
+nothingmuch has written L<Squirrel> (part of this distribution) which will act
+as Mouse unless Moose is loaded, in which case it will act as Moose.
Mouse also has the blessings of Moose's author, stevan.