msg_259_ilp32.c revision 1.4
1/*	$NetBSD: msg_259_ilp32.c,v 1.4 2021/08/31 19:26:23 rillig Exp $	*/
2# 3 "msg_259_ilp32.c"
3
4// Test for message: argument #%d is converted from '%s' to '%s' due to prototype [259]
5
6/*
7 * See also msg_297, but that requires the flags -a -p -P, which are not
8 * enabled in the default NetBSD build.
9 */
10
11/* lint1-only-if: ilp32 */
12/* lint1-extra-flags: -h */
13
14void farg_char(char);
15void farg_int(int);
16void farg_long(long);
17
18void
19example(char c, int i, long l)
20{
21	farg_char(c);
22	farg_int(c);
23	/* expect+1: from 'char' to 'long' due to prototype [259] */
24	farg_long(c);
25
26	farg_char(i);		/* XXX: why no warning? */
27	farg_int(i);
28	/* expect+1: from 'int' to 'long' due to prototype [259] */
29	farg_long(i);
30
31	farg_char(l);		/* XXX: why no warning? */
32	/* expect+1: from 'long' to 'int' due to prototype [259] */
33	farg_int(l);
34	farg_long(l);
35}
36