xref: /netbsd-src/tests/usr.bin/xlint/lint1/msg_085.c (revision 039b010016da489b3c993f4814255a8bc72125df)
1 /*	$NetBSD: msg_085.c,v 1.8 2023/08/02 18:51:25 rillig Exp $	*/
2 # 3 "msg_085.c"
3 
4 // Test for message: dubious tag declaration '%s %s' [85]
5 
6 /*
7  * Declarations of structs/unions/enums in parameter lists are allowed
8  * but useless.
9  */
10 
11 /* lint1-extra-flags: -X 351 */
12 
13 /* expect+1: warning: dubious tag declaration 'struct in_parameter' [85] */
14 void declare_struct(struct in_parameter *);
15 /* expect+1: warning: dubious tag declaration 'union in_parameter' [85] */
16 void declare_union(union in_parameter *);
17 /* expect+1: warning: dubious tag declaration 'enum in_parameter' [85] */
18 void declare_enum(enum in_parameter *);
19 
20 /* expect+1: warning: struct 'ok' never defined [233] */
21 struct ok;
22 extern int ok(struct ok *);
23