This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA [PR objc/29200][diagnostic] Make diagnostics translation friendly


Am Freitag, den 03.04.2009, 11:16 +0200 schrieb Andreas Schwab:
> David Ayers <ayers@fsfe.org> writes:
> 
> > This is a diagnostics bug fix to improve the ability to translate
> > certain strings in the Objective-C frontend.  Certain strings are being
> > constructed in a local function:
> >
> > static void
> > warn_with_method (const char *message, int mtype, tree method)
> > {
> >   /* Add a readable method name to the warning.  */
> >   warning (0, "%J%s %<%c%s%>", method,
> >            _(message), mtype, gen_method_decl (method));
> > }
> >
> > The _() around MESSAGE is introduced by this patch. To repeat the quite
> > above: I've verified that currently all calls to warn_with_method supply
> > a constant string as the message parameter so that the translation can
> > be called from within warn_with_method.
> 
> You need to rename the parameter message to msgid (or something else
> ending in msgid) so that gcc/po/exgettext can recognize the function
> properly as one that takes translatable strings.

Thank you very much!  Could someone point me to the documentation on how
to get these messages actually end up in the relevant files?

I'll try to figure out how to translate the the strings and test whether
they will then show up in my German locale.

Cheers,
David



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]