Source-Changes-HG archive

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

[src/trunk]: src/tests/usr.bin/xlint/lint1 tests/lint: test lowercase fallthr...



details:   https://anonhg.NetBSD.org/src/rev/a32cc235bad9
branches:  trunk
changeset: 1023196:a32cc235bad9
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Aug 29 09:09:53 2021 +0000

description:
tests/lint: test lowercase fallthrough

diffstat:

 tests/usr.bin/xlint/lint1/msg_220.c   |  6 +++++-
 tests/usr.bin/xlint/lint1/msg_220.exp |  1 +
 2 files changed, 6 insertions(+), 1 deletions(-)

diffs (27 lines):

diff -r cf7c95f02311 -r a32cc235bad9 tests/usr.bin/xlint/lint1/msg_220.c
--- a/tests/usr.bin/xlint/lint1/msg_220.c       Sun Aug 29 09:05:35 2021 +0000
+++ b/tests/usr.bin/xlint/lint1/msg_220.c       Sun Aug 29 09:09:53 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: msg_220.c,v 1.5 2021/08/29 09:05:35 rillig Exp $       */
+/*     $NetBSD: msg_220.c,v 1.6 2021/08/29 09:09:53 rillig Exp $       */
 # 3 "msg_220.c"
 
 // Test for message: fallthrough on case statement [220]
@@ -68,5 +68,9 @@
                /* expect+1: warning: fallthrough on case statement [220] */
        case 5:
                println("5");
+               /* fallthrough */
+               /* expect+1: warning: fallthrough on case statement [220] */
+       case 6:
+               println("6");
        }
 }
diff -r cf7c95f02311 -r a32cc235bad9 tests/usr.bin/xlint/lint1/msg_220.exp
--- a/tests/usr.bin/xlint/lint1/msg_220.exp     Sun Aug 29 09:05:35 2021 +0000
+++ b/tests/usr.bin/xlint/lint1/msg_220.exp     Sun Aug 29 09:09:53 2021 +0000
@@ -3,3 +3,4 @@
 msg_220.c(61): warning: fallthrough on case statement [220]
 msg_220.c(65): warning: fallthrough on case statement [220]
 msg_220.c(69): warning: fallthrough on case statement [220]
+msg_220.c(73): warning: fallthrough on case statement [220]



Home | Main Index | Thread Index | Old Index