Beefy Boxes and Bandwidth Generously Provided by pair Networks Cowboy Neal with Hat
We don't bite newbies here... much
 
PerlMonks  

Re^2: Using the Perl Debugger (-d)

by sgt (Deacon)
on Jan 25, 2007 at 13:32 UTC ( [id://596588]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re: Using the Perl Debugger (-d)
in thread Using the Perl Debugger (-d)

Smart::Comments don't really clutter the code...

cheers --stephan

Replies are listed 'Best First'.
Re^3: Using the Perl Debugger (-d)
by BerntB (Deacon) on Jan 25, 2007 at 13:36 UTC
    You posted that when I was over to CPAN to get the link. :-)
      Next time say "[cpan://Smart::Comments]" :-)
Re^3: Using the Perl Debugger (-d)
by nferraz (Monk) on Jan 26, 2007 at 12:12 UTC

    I love Smart::Comments! Basically, it requires you to write debug comments like this:

    sub foo { ### entering foo my $x = shift; ### x: $x return $x + 1; } ### starting... my $y = foo(42); ### y: $y ### finish exit;

    As you can see, they're just simple comments, until you use Smart::Comments, when they'll magically print the following output to STDERR:

    ### starting... ### entering foo ### x: 42 ### y: 43 ### finish

    The best part is that, when you disable Smart::Comments, they will sit quietly there -- just like comments they are -- documenting your code, but not being executed.

    Simple, useful... smart!!! :)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://596588]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.