As comes up pretty often, people want to trap stuff on STDERR.  I've got
adhoc stuff to do that in TieOut.pm, but I've never really found a good 
place to put it in a module.

Test::Warn seems like its a good spot.  Warnings and stuff going directly
to STDERR are related beasts.  So if Janek wants it, I can patch Test::Warn
to trap STDERR was well as normal warnings.

The question is the interface.  Should warning* just trap STDERR like
any other warning or should there be seperate functions?

I'd argue for the former.  First from a DWIM standpoint, and second
because sometimes you'll be getting both warnings and output to STDERR
from the same code (as just happened to me, prompting this train of
thought) and it would be nice to trap both.

The downside is the two streams are mixed and can't be seperated by
the test without unnecessarily complicating the arguments to warning*.
Dunno how important this is, don't think its very.

Reply via email to