New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wrong line number in error message #12573
Comments
From @maukeCreated by @maukeI think the following is a bug in the core but I'm not sure what's going on: if (1) Output: (Expected: ... line 7.) I can reproduce this with only core modules: Output: Here only the last part "... called at try.pl line 5" is wrong. I briefly tried to debug this with PERLDB_OPTS='NonStop=1' perl -d try.pl, but Perl Info
|
From @cpansproutOn Fri Nov 16 19:07:03 2012, mauke- wrote:
Could this be related to #111982? -- Father Chrysostomos |
The RT System itself - Status changed from 'new' to 'open' |
From @maukeOn 17.11.2012 20:13, Father Chrysostomos via RT wrote:
That bug is about some compilation errors (such as an undeclared It doesn't seem to be immediately related because: But maybe there's a deeper connection? |
From @cpansproutOn Sat Nov 17 12:28:28 2012, mauke- wrote:
That was just a hunch, based on a quick reading. It’s probably unrelated. In this case I suspect it has to do with a nextstate op being optimised -- Father Chrysostomos |
From @ikegamiOn Sat, Nov 17, 2012 at 4:12 PM, Father Chrysostomos via RT <
$ perl -MO=Concise -e'if (1) |
From @cpansproutOn Sun Nov 18 18:09:20 2012, ikegami@adaelis.com wrote:
Aha, so it looks as though pp_ctl.c:pp_caller needs to use Debugging without looking at the code seems to be working. :-) -- Father Chrysostomos |
From @cpansproutFixed in 2550212. -- Father Chrysostomos |
@cpansprout - Status changed from 'open' to 'resolved' |
From @cpansproutOn Sun Sep 01 11:43:04 2013, sprout wrote:
Though, actually, there are some cases where it doesn’t work, (e.g., Would it be reasonable to put the entersub op in the context stack (as -- Father Chrysostomos |
@cpansprout - Status changed from 'resolved' to 'open' |
Is this still open? I think I'm hitting it with some of my code. In a script of about 5700 lines, around line 5040 I have something like if( ! $something ) When the message gets printed, the line_number that's logged is the line number for the if() conditional. This doesn't happen everywhere that I do this sort of thing, just occasionally and for no reason that I've managed to spot so far. If there's a NO-OP line inserted between the opening curly brace and the log statement, the line number that's logged is correct. if( ! $something ) Perl on Debian 11.4: $ perl -v This is perl 5, version 28, subversion 1 (v5.28.1) built for i686-linux-gnu-thread-multi-64int |
There are alas multiple versions of the bug. If you check the PRs there is an example I found some time back. I really wish we as a community would focus more effort on fixing issues like this. I've put a fair bit of effort in the last cycle fixing some of the related issues, but there is so much more to do. I really think when we get error message data wring we make perl look bad to newbies, and we frustrate even the oldest and most experienced greybeard. |
Migrated from rt.perl.org#115768 (status was 'open')
Searchable as RT115768$
The text was updated successfully, but these errors were encountered: