TorontoJim has asked for the wisdom of the Perl Monks concerning the following question:
$spinner->count('benchLoop', __FILE__, __LINE__);
While I have this on line 93 of the physical file, Perl __LINE__ is reporting line 95. THere is nothing else on that line, there is no modification of the value in the sub handling it. __FILE__ is reported correctly.
Any idea why __LINE__ would be consistently off by 2?
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Perl's __LINE__ off by 2
by Corion (Patriarch) on Aug 25, 2025 at 10:33 UTC | |
Re: Perl's __LINE__ off by 2
by choroba (Cardinal) on Aug 25, 2025 at 10:17 UTC | |
Re: Perl's __LINE__ off by 2
by TorontoJim (Beadle) on Aug 25, 2025 at 09:37 UTC | |
Re: Perl's __LINE__ off by 2 (Introspection)
by LanX (Saint) on Aug 25, 2025 at 22:53 UTC | |
by ysth (Canon) on Aug 26, 2025 at 04:05 UTC | |
by LanX (Saint) on Aug 26, 2025 at 10:20 UTC | |
by ysth (Canon) on Aug 26, 2025 at 16:22 UTC | |
by LanX (Saint) on Aug 26, 2025 at 16:43 UTC | |
by LanX (Saint) on Aug 26, 2025 at 16:10 UTC |