Bug 31665 - %s substituted with "built-in"/"library" can't be properly translated
Summary: %s substituted with "built-in"/"library" can't be properly translated
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 4.3.0
: P3 normal
Target Milestone: 4.5.0
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks: trivial_translation_nits
  Show dependency treegraph
 
Reported: 2007-04-23 14:52 UTC by Göran Uddeborg
Modified: 2009-12-18 09:35 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Göran Uddeborg 2007-04-23 14:52:29 UTC
In cp/decl.c there is this code

	      warning (OPT_Wshadow, "shadowing %s function %q#D",
		       DECL_BUILT_IN (olddecl) ? "built-in" : "library",
		       olddecl);

The strings substituted for the first %s are not available for translation, so
this can not be properly translated.  Even if they were, composing a sentence
like this is not in general possible to do for an arbitrary language.
Comment 1 Shujing Zhao 2009-12-18 08:50:53 UTC
Subject: Bug 31665

Author: pzhao
Date: Fri Dec 18 08:50:24 2009
New Revision: 155340

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=155340
Log:
cp/
2009-12-16  Shujing Zhao  <pearly.zhao@oracle.com>

        PR c++/31665
        * decl.c (duplicate_decls, grokdeclarator): Put the
        diagnostics in full sentences for easy translation and wrapped into
        G_().
        * typeck.c (build_x_unary_op): Likewise.

testsuite/
2009-12-16  Shujing Zhao  <pearly.zhao@oracle.com>

        * g++.old-deja/g++.brendan/misc6.C: Make expected dg-error strings
        explicit.


Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/decl.c
    trunk/gcc/cp/typeck.c
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/g++.old-deja/g++.brendan/misc6.C

Comment 2 Paolo Carlini 2009-12-18 09:35:54 UTC
Fixed.