Subject: | pure-perl croak syntax when Carp not yet loaded |
Date: | Thu, 21 Aug 2008 08:50:05 +1000 |
To: | bug-list-moreutils [...] rt.cpan.org |
From: | Kevin Ryde <user42 [...] zip.com.au> |
With perl 5.10.0 and list-moreutils 0.22 the following program
BEGIN { $ENV{LIST_MOREUTILS_PP} = 1; }
use List::MoreUtils;
gets errors
String found where operator expected at (eval 1) line 206, near "Carp::croak "each_arrayref: argument is not an array reference\n""
(Do you need to predeclare Carp::croak?)
String found where operator expected at (eval 1) line 226, near "Carp::croak "each_array: unknown argument '$method' passed to iterator.""
(Do you need to predeclare Carp::croak?)
I wonder if Carp::croak in each_arrayref() needs some parens in case
Carp is not yet loaded.