blob: 67a6827186fb96b6f3d2042a89caae195918ad79 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
|
/* $NetBSD: opt_bbb.c,v 1.11 2023/06/18 07:32:33 rillig Exp $ */
/*
* Tests for the options '-bbb' and '-nbbb'.
*
* The option '-bbb' forces a blank line before every block comment.
*
* The option '-nbbb' keeps everything as is.
*/
//indent input
/*
* This is a block comment.
*/
/* This is not a block comment since it is single-line. */
/*
* This is a second block comment.
*/
/* This is not a block comment. */
/*
* Documentation of global_variable.
*/
int global_variable;
/*
* Documentation of function_declaration.
*/
void function_declaration(void);
/*
* Documentation of function_definition.
*/
void
function_definition(void)
{
}
//indent end
//indent run -bbb
/*
* This is a block comment.
*/
/* This is not a block comment since it is single-line. */
/*
* This is a second block comment.
*/
/* This is not a block comment. */
/*
* Documentation of global_variable.
*/
int global_variable;
/*
* Documentation of function_declaration.
*/
void function_declaration(void);
/*
* Documentation of function_definition.
*/
void
function_definition(void)
{
}
//indent end
//indent run-equals-input -nbbb
//indent input
{
label: /* not a block comment */
stmt; /* not a block comment */
label: /*
* This is not a block comment, as it goes to the right.
*/
stmt; /*
* This is not a block comment, as it goes to
* the right.
*/
/**
* This is a block comment.
*/
}
//indent end
//indent run -bbb
{
label: /* not a block comment */
stmt; /* not a block comment */
label: /* This is not a block comment, as it goes to
* the right. */
stmt; /* This is not a block comment, as it goes to
* the right. */
/**
* This is a block comment.
*/
}
//indent end
|