diff options
author | manu <manu@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-04-26 07:14:01 +0000 |
---|---|---|
committer | manu <manu@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-04-26 07:14:01 +0000 |
commit | 3f898bd251b9f56060f078129e9e5034a078d4ee (patch) | |
tree | d3312d2f0112387a0c5c243b879b69fbce449e0f /libcpp | |
parent | 9dd1a0668e5ab10a5943fdd1aee2e1616d7fc7ed (diff) | |
download | gcc-3f898bd251b9f56060f078129e9e5034a078d4ee.tar.gz |
2012-04-26 Manuel López-Ibáñez <manu@gcc.gnu.org>
* tree-diagnostic.c (maybe_unwind_expanded_macro_loc): Fix
comment. Delete unused parameter first_exp_point_map.
(virt_loc_aware_diagnostic_finalizer): Update call.
libcpp/
* line-map.c (linemap_resolve_location): Synchronize comments with
those in line-map.h.
* include/line-map.h (linemap_resolve_location): Fix spelling in
comment.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186860 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libcpp')
-rw-r--r-- | libcpp/ChangeLog | 7 | ||||
-rw-r--r-- | libcpp/include/line-map.h | 2 | ||||
-rw-r--r-- | libcpp/line-map.c | 19 |
3 files changed, 19 insertions, 9 deletions
diff --git a/libcpp/ChangeLog b/libcpp/ChangeLog index 133620b3b70..08878b27811 100644 --- a/libcpp/ChangeLog +++ b/libcpp/ChangeLog @@ -1,3 +1,10 @@ +2012-04-26 Manuel López-Ibáñez <manu@gcc.gnu.org> + + * line-map.c (linemap_resolve_location): Synchronize comments with + those in line-map.h. + * include/line-map.h (linemap_resolve_location): Fix spelling in + comment. + 2012-03-22 Richard Earnshaw <rearnsha@arm.com> * lex.c (search_line_fast): Provide Neon-optimized version for ARM. diff --git a/libcpp/include/line-map.h b/libcpp/include/line-map.h index 4e30742596c..22e2f0fc3c6 100644 --- a/libcpp/include/line-map.h +++ b/libcpp/include/line-map.h @@ -651,7 +651,7 @@ enum location_resolution_kind LRK_SPELLING_LOCATION. If LOC_MAP is not NULL, *LOC_MAP is set to the map encoding the - returned location. Note that if the resturned location wasn't originally + returned location. Note that if the returned location wasn't originally encoded by a map, the *MAP is set to NULL. This can happen if LOC resolves to a location reserved for the client code, like UNKNOWN_LOCATION or BUILTINS_LOCATION in GCC. */ diff --git a/libcpp/line-map.c b/libcpp/line-map.c index d7752bb4e61..106a4b515a7 100644 --- a/libcpp/line-map.c +++ b/libcpp/line-map.c @@ -1015,19 +1015,22 @@ linemap_macro_loc_to_exp_point (struct line_maps *set, * If LRK is set to LRK_MACRO_EXPANSION_POINT ------------------------------- - The virtual location is resolved to the location to the locus of - the expansion point of the macro. + The virtual location is resolved to the first macro expansion point + that led to this macro expansion. * If LRK is set to LRK_SPELLING_LOCATION ------------------------------------- - The virtual location is resolved to the location to the locus where - the token has been spelled in the source. This can follow through - all the macro expansions that led to the token. + The virtual location is resolved to the locus where the token has + been spelled in the source. This can follow through all the macro + expansions that led to the token. - * If LRK is set to LRK_MACRO_PARM_REPLACEMENT_POINT + * If LRK is set to LRK_MACRO_DEFINITION_LOCATION -------------------------------------- + The virtual location is resolved to the locus of the token in the + context of the macro definition. + If LOC is the locus of a token that is an argument of a function-like macro [replacing a parameter in the replacement list of the macro] the virtual location is resolved to the locus of the @@ -1038,8 +1041,8 @@ linemap_macro_loc_to_exp_point (struct line_maps *set, function-like macro, then the function behaves as if LRK was set to LRK_SPELLING_LOCATION. - If MAP is non-NULL, *MAP is set to the map of the resolved - location. Note that if the resturned location wasn't originally + If LOC_MAP is not NULL, *LOC_MAP is set to the map encoding the + returned location. Note that if the returned location wasn't originally encoded by a map, the *MAP is set to NULL. This can happen if LOC resolves to a location reserved for the client code, like UNKNOWN_LOCATION or BUILTINS_LOCATION in GCC. */ |