in reply to Find data point generating Error in Perl code
Could you show some example code? Normally, Perl tracks the last file and line read, and will usually add that information to the warning messages:
use warnings; while(<DATA>) { warn if /X/ } __DATA__ foo bar quzX
Should generate a message like "Warning: something's wrong at - line 2, <DATA> line 3.". Might be interesting to try and find out why that's not happening in your case.
But there are ways that you can do this yourself, for example this node shows how to use a __WARN__ %SIG handler to get custom information into warning messages.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Find data point generating Error in Perl code
by kgherman (Novice) on Mar 17, 2015 at 18:20 UTC | |
by AppleFritter (Vicar) on Mar 17, 2015 at 19:07 UTC | |
by Anonymous Monk on Mar 17, 2015 at 19:09 UTC | |
|
Re^2: Find data point generating Error in Perl code
by kgherman (Novice) on Mar 17, 2015 at 18:24 UTC |