Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re: use deprecated;

by Aristotle (Chancellor)
on Jan 16, 2004 at 15:50 UTC ( #321807=note: print w/ replies, xml ) Need Help??

in reply to use deprecated;

Maybe you could provide the full URL in your POD. :)

I don't like the idea of your debug() — far too hackish a way to enable deprecation warnings. Probably the best option is to use warnings::register instead. Another idea would be a companion module which merely sets a package variable; it could be then both be used from all the usual places as well as autoenabled by adding -Mdeprecated::warn or some such to PERL5OPT.

Are you putting this on CPAN?

Btw, Craft is more or less obsolete, Code Catacombs is where code should be posted. See One Section to rule them all. for a discussion.

Makeshifts last the longest.

Comment on Re: use deprecated;
Replies are listed 'Best First'.
Re: Re: use deprecated;
by halley (Prior) on Jan 16, 2004 at 16:04 UTC
    I wasn't sure if Craft was active anymore, but the whole Monastery is getting pretty catacombish about where to put stuff. I sort of wish it was all just "discussion" or "code." But that's a separate conversation.

    There are a thousand ways to flip the big debug() switch, and this is "sorta" the test that I settled on for the library I manage. I wanted the warnings to be invisible for uninitiated end-users, and to be visible to developers who didn't even know that existed. It's a compromise, but it's all in a separate function. It'd be neat if 5.8.2 adopted it (or even just the concept) and they could do whatever they wanted with debug(), but I just wanted to get the thing done.

    [ e d @ h a l l e y . c c ]

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://321807]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (12)
As of 2015-10-09 13:32 GMT
Find Nodes?
    Voting Booth?

    Does Humor Belong in Programming?

    Results (242 votes), past polls