in reply to Re^2: capturing command output
in thread capturing command output
But besides handling stderr it gives you another layer of indirection.So what? You have any idea how many layers of indirection there are on the open call? Or on the reading? Why is the number of layers of redirection an argument against backticks, but not about open, or the diamond operator?
Here it might actually be useful for logging the call (if it's generated) or storing the output for later inspection (it may not look as expected) or discard stderr or...Sure, but he isn't doing any of that. One can critic any piece of code with "yeah, but if you want to do X in the future, it becomes harder". With arguments like that, you'd never write down a single line of code.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: capturing command output
by pklausner (Scribe) on Jan 26, 2012 at 15:01 UTC | |
by JavaFan (Canon) on Jan 26, 2012 at 15:07 UTC | |
by pklausner (Scribe) on Jan 26, 2012 at 16:21 UTC | |
by JavaFan (Canon) on Jan 26, 2012 at 18:00 UTC | |
by pklausner (Scribe) on Jan 27, 2012 at 13:26 UTC | |
|
In Section
Seekers of Perl Wisdom