msg_228.c revision 1.4
1/*	$NetBSD: msg_228.c,v 1.4 2023/07/07 19:45:22 rillig Exp $	*/
2# 3 "msg_228.c"
3
4/* Test for message: function cannot return const or volatile object [228] */
5
6/* TODO: Also warn in C99 mode and later. */
7/* lint1-flags: -sw -X 351 */
8
9const int
10return_const_int(void)
11/* expect+1: warning: function cannot return const or volatile object [228] */
12{
13	return 3;
14}
15
16volatile int
17return_volatile_int(void)
18/* expect+1: warning: function cannot return const or volatile object [228] */
19{
20	return 3;
21}
22