diff options
author | Paolo Carlini <paolo.carlini@oracle.com> | 2011-10-19 12:46:42 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2011-10-19 12:46:42 +0000 |
commit | 9b6ab3c0591fd583915861cfd1d27183873221e8 (patch) | |
tree | 7d68d5cff8568aca5f5dada00e5cd8fc09885a9e /gcc/cp/parser.c | |
parent | 7f9a3dcd7d1981f6ef2d3ab7ab51b200715b8193 (diff) | |
download | gcc-9b6ab3c0591fd583915861cfd1d27183873221e8.zip gcc-9b6ab3c0591fd583915861cfd1d27183873221e8.tar.gz gcc-9b6ab3c0591fd583915861cfd1d27183873221e8.tar.bz2 |
re PR c++/38761 (%s substituted with regular word can't be properly translated)
2011-10-19 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/38761
PR c++/40872
* decl.c (duplicate_decls, make_typename_type, grokdeclarator): Use
G_() in error message strings to facilitate translation.
* semantics.c (finish_id_expression): Likewise.
* parser.c (cp_parser_nested_name_specifier_opt,
cp_parser_parameter_declaration): Likewise.
From-SVN: r180185
Diffstat (limited to 'gcc/cp/parser.c')
-rw-r--r-- | gcc/cp/parser.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c index a237b87..8d138fb 100644 --- a/gcc/cp/parser.c +++ b/gcc/cp/parser.c @@ -4752,8 +4752,8 @@ cp_parser_nested_name_specifier_opt (cp_parser *parser, && (TREE_CODE (TYPENAME_TYPE_FULLNAME (new_scope)) == TEMPLATE_ID_EXPR))) permerror (input_location, TYPE_P (new_scope) - ? "%qT is not a template" - : "%qD is not a template", + ? G_("%qT is not a template") + : G_("%qD is not a template"), new_scope); /* If it is a class scope, try to complete it; we are about to be looking up names inside the class. */ @@ -16810,17 +16810,20 @@ cp_parser_parameter_declaration (cp_parser *parser, if (id_declarator && id_declarator->kind == cdk_id) error_at (declarator_token_start->location, - template_parm_p - ? "template parameter pack %qD" - " cannot have a default argument" - : "parameter pack %qD cannot have a default argument", + template_parm_p + ? G_("template parameter pack %qD " + "cannot have a default argument") + : G_("parameter pack %qD cannot have " + "a default argument"), id_declarator->u.id.unqualified_name); else error_at (declarator_token_start->location, - template_parm_p - ? "template parameter pack cannot have a default argument" - : "parameter pack cannot have a default argument"); - + template_parm_p + ? G_("template parameter pack cannot have " + "a default argument") + : G_("parameter pack cannot have a " + "default argument")); + default_argument = NULL_TREE; } } |