From: Lev L. <li...@so...> - 2007-03-06 23:34:44
|
Hello, a co-worker has asked why the following snipped doesn't work as imagined: ---------- #!/usr/bin/perl -w use strict; use Log::Log4perl qw(:easy); Log::Log4perl->easy_init( { level => $WARN, file => "STDOUT" }, { level => $INFO, file => ">>info.log" } ); INFO "This is info - should appear on STDOUT"; ---------- his thinking, is that this should not print anything to STDOUT, but rather to info.log, given that STDOUT is reserved for WARN and above. He pointed out the following in the documentation: "As shown above, easy_init() will take any number of different logger definitions as hash references." this is in RE to the Bar::Twix, and :Bar::Mars example - does this only work because of the separate packages that they're defined in? thanks! -lev |