[gcc r12-10092] AVR: Work around "sequence of 3 consecutive punctuation characters" warning.

Georg-Johann Lay gjl@gcc.gnu.org
Fri Jan 12 13:49:33 GMT 2024


https://gcc.gnu.org/g:90f44ef2a9419a550e954be4146b7d0dcd33c8cf

commit r12-10092-g90f44ef2a9419a550e954be4146b7d0dcd33c8cf
Author: Georg-Johann Lay <avr@gjlay.de>
Date:   Fri Jan 12 14:42:45 2024 +0100

    AVR: Work around "sequence of 3 consecutive punctuation characters" warning.
    
    gcc/
            * config/avr/avr.cc (avr_handle_addr_attribute): Move "..." from
            format string to %s argument.
    
    (cherry picked from commit 549ea1487a534d0eef6a424075264ba542514c3d)

Diff:
---
 gcc/config/avr/avr.cc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/config/avr/avr.cc b/gcc/config/avr/avr.cc
index b5f6c2362b6..1905ac5790c 100644
--- a/gcc/config/avr/avr.cc
+++ b/gcc/config/avr/avr.cc
@@ -10259,8 +10259,8 @@ avr_handle_addr_attribute (tree *node, tree name, tree args,
 	       && (!tree_fits_shwi_p (arg)
 		   || ! IN_RANGE (TREE_INT_CST_LOW (arg), io_start, io_end)))
 	{
-	  warning_at (loc, OPT_Wattributes, "%qE attribute address out of "
-		      "range 0x%x...0x%x", name, (int) io_start, (int) io_end);
+	  warning_at (loc, OPT_Wattributes, "%qE attribute address out of range"
+		      " 0x%x%s0x%x", name, (int) io_start, "...", (int) io_end);
 	  *no_add = true;
 	}
       else


More information about the Gcc-cvs mailing list