From: Mike S. <log...@pe...> - 2003-05-13 01:53:17
|
On Tue, 13 May 2003 lei...@hp... wrote: > I am not sure if this has been raised before, the sourceforge mail list > browse doesn't have a search function, so I just checked the last 100 > messages. Look at the upper left corner. There's a search field and a select box with the item "This Mailing List": http://sourceforge.net/mailarchive/forum.php?forum_id=10175 > I suppose I would call this more an issue of style - I have issues with any > library that exits on me. I would prefer a library told me 'sorry I cant > help you' and let me decide on the flow from there. > ... > An eval could help - in fact there are many 'workarounds' - but I still feel > calling die is wrong. > > Are there any plans for this behaviour to be revised in the future ?? It's a trade-off to protect against people not checking the return code of init() and then wondering what's wrong. A matter of style, indeed, and negotiable. One area which is tougher to solve is with init_and_watch(). What happens if Log4perl reloads the conf file and somebody has put a syntax error in there? There's no application interaction at this point, no way to catch this error but die. I think this particular issue also drove the decision to die() on a failed init(). -- Mike Mike Schilli log...@pe... http://perlmeister.com http://log4perl.sourceforge.net |