Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re^2: Beware List::MoreUtils natatime()!

by diotalevi (Canon)
on Feb 10, 2009 at 07:13 UTC ( #742679=note: print w/replies, xml ) Need Help??

in reply to Re: Beware List::MoreUtils natatime()!
in thread Beware List::MoreUtils natatime()!

Your bug sounds like your version is depending on an accident of not-quite recent perls. It used to often "just work" to say Carp::croak '...';. That was accidental and whenever you see an exception like this, just make sure to load Carp in advance of loading the thing you're using.

In your example, do:

$ LIST_MOREUTILS_PP=1 perl -MCarp foo

Replies are listed 'Best First'.
Re^3: Beware List::MoreUtils natatime()!
by JavaFan (Canon) on Feb 10, 2009 at 07:55 UTC
    Looking into the source of List::MoreUtils, I find:
    require Carp; Carp::croak "some message";
    That only works if Carp was already loaded. In older versions of Perl, there was a common pragma (vars?) that loaded it, but that no longer is loaded in 5.10.

    Hence the error. And another reason to not use List::MoreUtils.

      This fix is so trivial, it's not a real reason to avoid it.

      ⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

        The natatime function is so trivial to write, there being a trivial fix is not a real reason to use a broken module.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://742679]
[marto]: good morning all
[Corion]: Hi marto!
[Corion]: I hope you had a good weekend!
[Discipulus]: good morning again monks!
[choroba]: Good morning!
[Corion]: I have a rough plan to release an ImageNet classifier in Perl (well, using pretrained data, but still a nice toy)
Discipulus is going mad with the new win10 client.. tried mv Cortana /dev/null but no succes
[Corion]: Ouch - another pretrained set is available, using images from IMDB and Wikipedia. So I expect interesting results for non-PR images where people are pictured that are not made up

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (4)
As of 2017-09-25 08:29 GMT
Find Nodes?
    Voting Booth?
    During the recent solar eclipse, I:

    Results (277 votes). Check out past polls.