[libmoox-late-perl] 03/07: move roles examples to separate section
Intrigeri
intrigeri at moszumanska.debian.org
Thu Aug 14 11:13:37 UTC 2014
This is an automated email from the git hooks/post-receive script.
intrigeri pushed a commit to tag 0.007
in repository libmoox-late-perl.
commit f98913c4925e98690a146e7208f58ee33f43a65d
Author: Toby Inkster <mail at tobyinkster.co.uk>
Date: Wed Dec 26 14:23:24 2012 +0000
move roles examples to separate section
---
lib/MooX/late.pm | 32 ++++++++++++++++++++++----------
1 file changed, 22 insertions(+), 10 deletions(-)
diff --git a/lib/MooX/late.pm b/lib/MooX/late.pm
index f2ca2cf..29897c1 100644
--- a/lib/MooX/late.pm
+++ b/lib/MooX/late.pm
@@ -394,16 +394,7 @@ or, without L<MooX>:
use MooX::late;
has bar => (is => 'ro', isa => 'Str');
-or, for MooX::Role:
-
- package MyRole;
- use MooX::Role qw(late);
-
-or, inside L<Package::Variant>:
-
- use Package::Variant
- importing => ['MooX::Role' => ['late'],],
- subs => [ qw(has with) ];
+(Examples for Moo roles in section below.)
=head1 DESCRIPTION
@@ -454,6 +445,27 @@ Moo behave exactly identically to Moose. It's just going after the low-hanging
fruit. So it does four things right now, and I promise that future versions
will never do more than seven.
+=head2 Use in Moo::Roles
+
+MooX::late should work in Moo::Roles, with no particular caveats.
+
+ package MyRole;
+ use MooX::Role qw(late);
+
+or, without L<MooX>:
+
+ package MyRole;
+ use Moo::Role;
+ use MooX::late;
+
+L<Package::Variant> can be used to build the Moo equivalent of
+parameterized roles. MooX::late should work in roles built with
+Package::Variant.
+
+ use Package::Variant
+ importing => ['MooX::Role' => ['late']],
+ subs => [ qw(has with) ];
+
=head1 BUGS
Please report any bugs to
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmoox-late-perl.git
More information about the Pkg-perl-cvs-commits
mailing list