This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug macros/15611] macros don't work with CWEB
- From: "ccoutant at google dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 14 Jun 2013 17:10:11 +0000
- Subject: [Bug macros/15611] macros don't work with CWEB
- Auto-submitted: auto-generated
- References: <bug-15611-4717 at http dot sourceware dot org/bugzilla/>
http://sourceware.org/bugzilla/show_bug.cgi?id=15611
Cary Coutant <ccoutant at google dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ccoutant at google dot com
--- Comment #1 from Cary Coutant <ccoutant at google dot com> ---
Have you tried the -a option?
(gdb) info macro -a a
Defined at /usr/local/google/home/ccoutant/scratch/macro/macrotest.c:2
#define a(x) b[x]
Without -a, GDB looks for macro definitions only in the current compilation
unit, and it thinks the macro is defined in macrotest.c, while you are
currently in macrotest.w.
I noticed that CTANGLE isn't putting a #line directive in front of the
translated macro definitions, so there's not even an expectation that they
would appear as coming from the original .w source file. That seems like a bug
in CTANGLE.
Nevertheless, when I added the #line directive manually, GCC seems to ignore it
when it generates the macro information in the DWARF (I tested with both the
older .debug_macinfo and the newer .debug_macro). That seems like a bug in GCC.
--
You are receiving this mail because:
You are on the CC list for the bug.