aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/parser.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp/parser.c')
-rw-r--r--gcc/cp/parser.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c
index 48dbca1..ca9f8b9 100644
--- a/gcc/cp/parser.c
+++ b/gcc/cp/parser.c
@@ -26342,8 +26342,10 @@ cp_parser_enclosed_template_argument_list (cp_parser* parser)
global source location is still on the token before the
'>>', so we need to say explicitly where we want it. */
cp_token *token = cp_lexer_peek_token (parser->lexer);
- error_at (token->location, "%<>>%> should be %<> >%> "
- "within a nested template argument list");
+ gcc_rich_location richloc (token->location);
+ richloc.add_fixit_replace ("> >");
+ error_at_rich_loc (&richloc, "%<>>%> should be %<> >%> "
+ "within a nested template argument list");
token->type = CPP_GREATER;
}