http://www.perlmonks.org?node_id=296197


in reply to Re: __FILE__ and __LINE__ for Perl?
in thread __FILE__ and __LINE__ for Perl?

Just to be a little more specific, note that
warn "I'm a warning about something";
does not contain a trailing newline. If your warning message does contain \n as the last character, warn will not include at demo.pl line 47. See perldoc -f warn

--
bm