xref: /illumos-gate/usr/src/tools/smatch/src/validation/__func__.c (revision 1b58875ad7966cf2c85ee8e92f3da04f0a3b2f7a)
1 static void f(void)
2 {
3 	char *s1 = __func__;
4 	char arr[2 * (sizeof __func__ == 2) - 1];
5 	char *s2 = __func__ __func__;
6 }
7 /*
8  * check-name: __func__
9  * check-command: sparse -Wall $file
10  *
11  * check-error-start
12 __func__.c:5:29: error: Expected ; at end of declaration
13 __func__.c:5:29: error: got __func__
14  * check-error-end
15  */
16