From docs/compiler_faq.pod:
=head2 How do I embed source locations in my code for debugging?
You can do this using either the C<setfile> and C<setline> opcodes or
with C-like C<#line> comments:
#line 27 "my_source.file"
Simply set the source file name or line number whenever it changes.
But note that currently (Parrot 0.3.0) both are ignored in the lexer.
On Aug 3, 2006, at 11:30 AM, Patrick R. Michaud wrote:
On Fri, Jul 21, 2006 at 03:03:07PM -0700, Will Coleda wrote:
# New Ticket Created by Will Coleda
# Please include the string: [perl #39905]
# in the subject line of all future correspondence about this issue.
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=39905 >
Once a .tg file is compiled to a .pir file, any errors in the
embedded PIR are reported against the line number
of the generated PIR file.
Instead, the line numbers should be reported against the original .tg
file.
Is there an imcc pragma for setting the line number to be reported
for an error? Or what's the general approach to getting the generated
PIR file to report the correct line number?
Pm
--
Will "Coke" Coleda
[EMAIL PROTECTED]