xref: /netbsd-src/tests/usr.bin/indent/lsym_sizeof.c (revision 2718af68c3efc72c9769069b5c7f9ed36f6b9def)
1 /* $NetBSD: lsym_sizeof.c,v 1.3 2021/11/25 18:36:30 rillig Exp $ */
2 /* $FreeBSD$ */
3 
4 /*
5  * Tests for the token lsym_sizeof, which represents the keyword 'sizeof' for
6  * determining the memory size of an object or a type.
7  *
8  * See also:
9  *	opt_bs.c		"blank after sizeof"
10  *	C11 6.5.3.4		"The 'sizeof' and '_Alignof' operators"
11  */
12 
13 #indent input
14 // TODO: add input
15 #indent end
16 
17 #indent run-equals-input
18 
19 
20 /*
21  * After 'sizeof', a type name in parentheses does not start a cast
22  * expression.
23  */
24 #indent input
25 char str[sizeof(int) * CHAR_BIT + 1];
26 #indent end
27 
28 #indent run-equals-input -di0
29