summaryrefslogtreecommitdiff
path: root/tests/usr.bin/xlint/lint1/msg_111.c
blob: 72e87dc1a9f9047b7fa2d9d1a63857ca7703dfbf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/*	$NetBSD: msg_111.c,v 1.3 2022/06/16 16:58:36 rillig Exp $	*/
# 3 "msg_111.c"

/* Test for message: unacceptable operand of '%s' [111] */

/* lint1-flags: -tw -aa -chapbrzgF */

struct s {
	int member;
};

void
illegal_member_access()
{
	/* expect+2: warning: left operand of '.' must be struct or union, not 'function() returning void' [103] */
	/* expect+1: error: unacceptable operand of '.' [111] */
	return illegal_member_access.member;
}