From: Dave Rolsky Date: Sun, 16 Sep 2012 17:31:02 +0000 (-0500) Subject: Clarify natatime Array helper behavior when given a code ref X-Git-Tag: 2.0800~23 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo%2FMoose.git;a=commitdiff_plain;h=e4fdfb589a1c4b66e5cbb3098d1137e1715a3261 Clarify natatime Array helper behavior when given a code ref --- diff --git a/lib/Moose/Meta/Attribute/Native/Trait/Array.pm b/lib/Moose/Meta/Attribute/Native/Trait/Array.pm index d3c7704..a7046a2 100644 --- a/lib/Moose/Meta/Attribute/Native/Trait/Array.pm +++ b/lib/Moose/Meta/Attribute/Native/Trait/Array.pm @@ -294,9 +294,11 @@ This method accepts one or two arguments. =item * B This method returns an iterator which, on each call, returns C<$n> more items -from the array, in order, like C from L. A coderef -can optionally be provided; it will be called on each group of C<$n> elements -in the array. +from the array, in order, like C from L. + +If you pass a coderef as the second argument, then this code ref will be +called on each group of C<$n> elements in the array until the array is +exhausted. This method accepts one or two arguments.