xref: /netbsd-src/tests/usr.bin/indent/opt_ts.c (revision 47306038c7d906b62edca1fd252c0e0d0772f5a0)
1 /* $NetBSD: opt_ts.c,v 1.3 2022/04/24 09:04:12 rillig Exp $ */
2 
3 /*
4  * Tests for the option '-ts', which specifies the width of a single
5  * tabulator.
6  */
7 
8 /*
9  * Since in this test, a tab is only worth 4 spaces, the indentation needs
10  * more tabs to reach the indentation of 8 and the alignment at 16.
11  */
12 //indent input
13 int variable;
14 
15 void
function(void)16 function(void)
17 {
18 	int local_variable;
19 	char local_variable;
20 }
21 //indent end
22 
23 //indent run -ts4
24 int				variable;
25 
26 void
function(void)27 function(void)
28 {
29 		int				local_variable;
30 		char			local_variable;
31 }
32 //indent end
33