Alex
Now I'm able to distinguish separately:
-syntax errors (missing colons etc.) via $SIG{__DIE__} = &syserror; -system errors via $SIG{__DIE__} = &syserror; -system warnings (useless use of etc.) via $SIG{__WARN__} = &syswarn; -user-defined warnings (warn("foo";) via ::warn -die statements if it occurs within eval block message will printed out and the program runs further else message will printed out and the program will be aborted due to exception
In order to hide stderr for perlmate you have to write in perlmate.rb
class PerlMate < ScriptMate def filter_stderr(str) "" end end
I don't use your 'sub id' except for 'sub warn'. Here everything should be clear. Otherwise I trust Perl's error messages more than 'caller($level);'. Esp. for the case if Perl's message contains more than one link like Carp::longmess() it often does.
Comments?
This code is up to now very redundant. It's only for testing!
-Hans