This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH][V2] dwarf.exp: Allow generating a stub .debug_line section
- From: Petr Machata <pmachata at redhat dot com>
- To: Doug Evans <dje at google dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 30 Mar 2015 21:48:03 +0200
- Subject: Re: [PATCH][V2] dwarf.exp: Allow generating a stub .debug_line section
- Authentication-results: sourceware.org; auth=none
- References: <87619mkpil dot fsf at redhat dot com> <21785 dot 37797 dot 271814 dot 469027 at ruffy2 dot mtv dot corp dot google dot com>
Doug Evans <dje@google.com> writes:
> > + if { "$label" != "" } {
> > + $label:
> > + }
>
> Should this be:
>
> if { "$label" != "" } {
> _emit "$label:"
> }
No, it's calling the function named "$label:". To define the label that
the user supplied. Would this make it clearer?
--- a/gdb/testsuite/lib/dwarf.exp
+++ b/gdb/testsuite/lib/dwarf.exp
@@ -1165,6 +1165,7 @@ namespace eval Dwarf {
_section $section
if { "$label" != "" } {
+ # Define the user-provided label at this point.
$label:
}
Thanks,
Petr