msg_206.c revision 1.4
1/* $NetBSD: msg_206.c,v 1.4 2021/07/08 18:53:57 rillig Exp $ */ 2# 3 "msg_206.c" 3 4// Test for message: enumeration value(s) not handled in switch [206] 5 6/* lint1-extra-flags: -eh */ 7 8enum number { 9 ONE, TWO, THREE 10}; 11 12void 13test(enum number num) 14{ 15 switch (num) { 16 case ONE: 17 case TWO: 18 break; 19 } 20 /* expect-1: warning: enumeration value(s) not handled in switch [206] */ 21 22 switch (num) { 23 case ONE: 24 case TWO: 25 case THREE: 26 break; 27 } 28} 29