Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"

Re^4: Splitting program into modules

by LanX (Sage)
on Nov 14, 2018 at 13:44 UTC ( #1225784=note: print w/replies, xml ) Need Help??

in reply to Re^3: Splitting program into modules
in thread Splitting program into modules

> Again, it's intrusive;

I wonder why you prefer it that way, there are at least two alternatives

  • running under the debugger and activating the trace option
  • inspecting the stash of the included packages and dynamically monkey patching the subs with tracing wrappers.

Am I missing something?

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery FootballPerl is like chess, only without the dice

Replies are listed 'Best First'.
Re^5: Splitting program into modules
by stevieb (Canon) on Nov 14, 2018 at 14:21 UTC

    I definitely don't prefer it this way. This was a project I started many, many years ago actually. It was one of the very first projects I ever thought of when I started writing Perl, and it took many years to put together. It was more a "can I do this" thing :)

    As a matter of fact, another project I went on for the sake of learning how is monkey patching on the fly with my Mock::Sub and Wrap::Sub, so updating Devel::Trace::Subs is something I definitely could do to remove the actual writing to files. I'll create myself an issue so I don't forget to do this someday.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (2)
As of 2022-05-17 00:19 GMT
Find Nodes?
    Voting Booth?
    Do you prefer to work remotely?

    Results (65 votes). Check out past polls.