1 package Moose::Meta::Method::Accessor::Native::Array::map;
9 $VERSION = eval $VERSION;
10 our $AUTHORITY = 'cpan:STEVAN';
14 with 'Moose::Meta::Method::Accessor::Native::Reader' => {
19 _inline_check_arguments
24 sub _minimum_arguments { 1 }
26 sub _maximum_arguments { 1 }
28 sub _inline_check_arguments {
32 'if (!Params::Util::_CODELIKE($_[0])) {',
33 $self->_inline_throw_error(
34 '"The argument passed to map must be a code reference"',
42 my ($slot_access) = @_;
44 return 'map { $_[0]->() } @{ (' . $slot_access . ') }';