1 /* $NetBSD: msg_147.c,v 1.5 2023/03/28 14:44:34 rillig Exp $ */
2 # 3 "msg_147.c"
3
4 // Test for message: invalid cast from '%s' to '%s' [147]
5
6 /* lint1-extra-flags: -X 351 */
7
8 // The type name 'int(int)' is a 'function(int) returning int'.
9 void take(int(int));
10
11 /* ARGSUSED */
12 void
call_take(int (* ptr)(int))13 call_take(int (*ptr)(int))
14 {
15 /* expect+1: error: invalid cast from 'pointer to function(int) returning int' to 'function(int) returning int' [147] */
16 take((int(int))ptr);
17 }
18