This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB 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]

[binutils-gdb] format_pieces-selftests.c: Silence ARI warnings


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=1d143c36eedc0f0b124e6aa6fb3b98b1e6ff74b0

commit 1d143c36eedc0f0b124e6aa6fb3b98b1e6ff74b0
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Fri May 18 15:47:56 2018 -0400

    format_pieces-selftests.c: Silence ARI warnings
    
    Silence this:
    
    unittests/format_pieces-selftests.c:51: warning: code: Do not use printf("%ll"), instead use printf("%s",phex()) to dump a `long long' value
    unittests/format_pieces-selftests.c:56: warning: code: Do not use printf("%ll"), instead use printf("%s",phex()) to dump a `long long' value
    
    gdb/ChangeLog:
    
    	* unittests/format_pieces-selftests.c (test_format_specifier):
    	Add ARI comments.

Diff:
---
 gdb/ChangeLog                           | 5 +++++
 gdb/unittests/format_pieces-selftests.c | 4 ++--
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index d4d00f8..57edb23 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2018-05-18  Simon Marchi  <simon.marchi@ericsson.com>
+
+	* unittests/format_pieces-selftests.c (test_format_specifier):
+	Add ARI comments.
+
 2018-05-18  Tom Tromey  <tom@tromey.com>
 
 	* c-typeprint.c (maybe_print_hole): New function.
diff --git a/gdb/unittests/format_pieces-selftests.c b/gdb/unittests/format_pieces-selftests.c
index 6d11a9c..8f63247 100644
--- a/gdb/unittests/format_pieces-selftests.c
+++ b/gdb/unittests/format_pieces-selftests.c
@@ -48,12 +48,12 @@ test_escape_sequences ()
 static void
 test_format_specifier ()
 {
-  check ("Hello %d%llx%%d",
+  check ("Hello %d%llx%%d", /* ARI: %ll */
     {
       format_piece ("Hello ", literal_piece),
       format_piece ("%d", int_arg),
       format_piece ("", literal_piece),
-      format_piece ("%llx", long_long_arg),
+      format_piece ("%llx", long_long_arg), /* ARI: %ll */
       format_piece ("%%d", literal_piece),
     });
 }


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