d_c99_decls_after_stmt.c revision 1.7
1/*	$NetBSD: d_c99_decls_after_stmt.c,v 1.7 2023/08/02 18:51:25 rillig Exp $	*/
2# 3 "d_c99_decls_after_stmt.c"
3
4/*
5 * Before cgram.y 1.50 from 2011-10-04, lint complained about syntax errors
6 * at the second 'int'.
7 *
8 * https://gnats.netbsd.org/45417
9 */
10
11/* lint1-extra-flags: -X 351 */
12
13void
14two_groups_of_decl_plus_stmt(void)
15{
16	int i = 0;
17	i += 1;
18
19	int j = 0;
20	j += 1;
21}
22
23typedef int int_t;
24
25int
26second_decl_stmt_uses_a_typedef(void)
27{
28	int i = 0;
29	i += 1;
30
31	int_t j = 0;
32	j += 1;
33
34	return 0;
35}
36
37void
38function_with_parameter(int i)
39{
40	i += 1;
41
42	int j = 0;
43	j += 1;
44}
45