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: [PATCH 2/2] [MSP430] Fix issues handling .persistent attribute (PR 78818)


On 18 May 2017 at 16:46, Martin Sebor <msebor@gmail.com> wrote:
> +  if (!message && TREE_NAME_EQ (name, ATTR_PERSIST) && !TREE_STATIC (*
> node)
> +      && !TREE_PUBLIC (* node) && !DECL_EXTERNAL (* node))
> +    message = "%qE attribute has no effect on automatic variables";
>
> In code like this (both existing and new) where the format string
> is being assigned to a pointer that is then passed to one of the
> diagnostic functions, I believe the string literal needs to wrapped
> in G_() so that it can be translated.

Attached patch with the string wrapped in G_().

I'll update the other diagnostic strings without G_() in a separate patch.

Thanks,
Jozef

Attachment: 0002-MSP430-Emit-warning-when-persistent-attribute-is-use.patch
Description: Binary data


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