Message ID | 6d81cc37-3cf3-97b1-ae7e-9acb781acd8e@suse.cz |
---|---|
State | New |
Headers | show |
Series | rs6000: wrap const in an error message. | expand |
On 3/22/22 13:50, Martin Liška wrote:
> + warning (0, "passing argument %d of %qE discards %<const%> "
I've just installed version only with one space. Sorry for noise.
Martin
On Tue, Mar 22, 2022 at 01:50:09PM +0100, Martin Liška wrote: > Pushed as obvious. > - warning (0, "passing argument %d of %qE discards const qualifier > " > - "from pointer target type", n + 1, fndecl); > + warning (0, "passing argument %d of %qE discards %<const%> " > + "qualifier from pointer target type", n + 1, fndecl); Please use %qs instead? Segher
diff --git a/gcc/config/rs6000/rs6000-c.cc b/gcc/config/rs6000/rs6000-c.cc index 3b62b499df2..f73b98f8051 100644 --- a/gcc/config/rs6000/rs6000-c.cc +++ b/gcc/config/rs6000/rs6000-c.cc @@ -1788,8 +1788,8 @@ altivec_resolve_overloaded_builtin (location_t loc, tree fndecl, { if (TYPE_READONLY (TREE_TYPE (type)) && !TYPE_READONLY (TREE_TYPE (decl_type))) - warning (0, "passing argument %d of %qE discards const qualifier " - "from pointer target type", n + 1, fndecl); + warning (0, "passing argument %d of %qE discards %<const%> " + "qualifier from pointer target type", n + 1, fndecl); type = build_qualified_type (TREE_TYPE (type), 0); type = build_pointer_type (type); arg = fold_convert (type, arg);