This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug preprocessor/41445] Debug information is wrong with and without --save-temps.
- From: "jakub at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 23 Sep 2009 12:32:20 -0000
- Subject: [Bug preprocessor/41445] Debug information is wrong with and without --save-temps.
- References: <bug-41445-17506@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from jakub at gcc dot gnu dot org 2009-09-23 12:32 -------
Confirmed. Can be reproduced even with just:
#define A(a,b)
A(1,
2) int i;
int j;
Here int i; is on the 3rd line, but -E generates
# 1 "h.c"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "h.c"
int i;
int j;
The extra line to adjust lines for the two line function-line macro use is
added only after hitting newline after int i;, not already before those tokens.
So int j; has correct line locus, but int i; doesn't. Column numbers clearly
can't be maintained the same between normal and -save-temps compilation, that's
a lost case, but perhaps at least line numbers could be kept.
--
jakub at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |tromey at gcc dot gnu dot
| |org
GCC build triplet|i686-linux-gnu |
GCC target triplet|arm-none-linux-gnueabi |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41445