diff options
author | Per Bothner <per@bothner.com> | 2004-07-14 17:02:30 -0700 |
---|---|---|
committer | Per Bothner <bothner@gcc.gnu.org> | 2004-07-14 17:02:30 -0700 |
commit | aa3c6dc1604edf2119da7cf6d39c6afab3a676d7 (patch) | |
tree | 590981ecbc489c808f0c696cd08606defbd93ffa /gcc/tree.c | |
parent | 368b7a304e674df0e140b6dc164e670650c56486 (diff) | |
download | gcc-aa3c6dc1604edf2119da7cf6d39c6afab3a676d7.zip gcc-aa3c6dc1604edf2119da7cf6d39c6afab3a676d7.tar.gz gcc-aa3c6dc1604edf2119da7cf6d39c6afab3a676d7.tar.bz2 |
input.h: If USE_MAPPED_LOCATION...
* input.h: If USE_MAPPED_LOCATION, define separate expanded_location
structure with extra column field.
* tree.c (expand_location): Also fill in column field.
* gengtype-lex.l: Ignore expanded_location typedef, sinze gengtype
gets confused by the two conditionally-compiled definitions.
From-SVN: r84721
Diffstat (limited to 'gcc/tree.c')
-rw-r--r-- | gcc/tree.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -2760,12 +2760,13 @@ expanded_location expand_location (source_location loc) { expanded_location xloc; - if (loc == 0) { xloc.file = NULL; xloc.line = 0; } + if (loc == 0) { xloc.file = NULL; xloc.line = 0; xloc.column = 0; } else { const struct line_map *map = linemap_lookup (&line_table, loc); xloc.file = map->to_file; xloc.line = SOURCE_LINE (map, loc); + xloc.column = SOURCE_COLUMN (map, loc); }; return xloc; } |