bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error vs warning on unsupported escapes


From: Bruno Haible
Subject: Re: Error vs warning on unsupported escapes
Date: Tue, 19 Feb 2008 00:59:43 +0100
User-agent: KMail/1.5.4

Hello,

F Wolff wrote:
> libgettextpo reports an error of severity PO_SEVERITY_ERROR in case of
> unexpected escapes (\a, \b, \r, etc). Both msgfmt -cv and msgunfmt
> doesn't seem to have a real problem with these. The code should easily
> be able to write them out, and the comment in write-po.c suggests that
> we only really want to warn users, not fail.
> 
>             /* We warn about any use of escape sequences beside
>                '\n' and '\t'.  */
>             if (c != 'n' && c != 't')
>               {
>                 char *error_message =
>                   xasprintf (_("\
> internationalized messages should not contain the `\\%c' escape sequence"),
>                              c);
>                 po_xerror (PO_SEVERITY_ERROR, mp, NULL, 0, 0, false,
>                            error_message);
> 
> Would it be worthwhile to change the PO_SEVERITY_ERROR to
> PO_SEVERITY_WARNING instead?

Thanks for reporting and proposing this. This change happens to just have
been implemented three weeks ago; see the ChangeLog file at
  
http://cvs.savannah.gnu.org/viewvc/gettext/gettext-tools/src/ChangeLog?revision=HEAD&root=gettext&view=markup

Bruno





reply via email to

[Prev in Thread] Current Thread [Next in Thread]