bug-gnulib
[Top][All Lists]
Advanced

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

[PATCH] nstrftime: pacify nvc 22.1 unreachable statement


From: Paul Eggert
Subject: [PATCH] nstrftime: pacify nvc 22.1 unreachable statement
Date: Fri, 14 Jan 2022 19:43:42 -0800

* lib/nstrftime.c (__strftime_internal):
Omit unreachable ‘break;’.
---
 ChangeLog       | 4 ++++
 lib/nstrftime.c | 1 -
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 9113099129..d49794f433 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2022-01-14  Paul Eggert  <eggert@cs.ucla.edu>
 
+       nstrftime: pacify nvc 22.1 unreachable statement
+       * lib/nstrftime.c (__strftime_internal):
+       Omit unreachable ‘break;’.
+
        tests: pacify nvc 22.1 unreachable statement
        * tests/test-sys_wait.h (test_sys_wait_macros):
        Widen scope of ‘#if 0’ so that there is not an unreachable ‘break;’.
diff --git a/lib/nstrftime.c b/lib/nstrftime.c
index 3b5433c131..c1dd554247 100644
--- a/lib/nstrftime.c
+++ b/lib/nstrftime.c
@@ -1158,7 +1158,6 @@ __strftime_internal (STREAM_OR_CHAR_T *s, STRFTIME_ARG 
(size_t maxsize)
 
         case L_('q'):           /* GNU extension.  */
           DO_SIGNED_NUMBER (1, false, ((tp->tm_mon * 11) >> 5) + 1);
-          break;
 
         case L_('R'):
           subfmt = L_("%H:%M");
-- 
2.32.0




reply via email to

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