| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | /* $NetBSD: opt_bbb.c,v 1.9 2023/06/17 22:09:24 rillig Exp $ */ | | 1 | /* $NetBSD: opt_bbb.c,v 1.10 2023/06/18 07:29:36 rillig Exp $ */ |
2 | | | 2 | |
3 | /* | | 3 | /* |
4 | * Tests for the options '-bbb' and '-nbbb'. | | 4 | * Tests for the options '-bbb' and '-nbbb'. |
5 | * | | 5 | * |
6 | * The option '-bbb' forces a blank line before every block comment. | | 6 | * The option '-bbb' forces a blank line before every block comment. |
7 | * | | 7 | * |
8 | * The option '-nbbb' keeps everything as is. | | 8 | * The option '-nbbb' keeps everything as is. |
9 | */ | | 9 | */ |
10 | | | 10 | |
11 | //indent input | | 11 | //indent input |
12 | /* | | 12 | /* |
13 | * This is a block comment. | | 13 | * This is a block comment. |
14 | */ | | 14 | */ |
| @@ -61,29 +61,44 @@ void function_declaration(void); | | | @@ -61,29 +61,44 @@ void function_declaration(void); |
61 | void | | 61 | void |
62 | function_definition(void) | | 62 | function_definition(void) |
63 | { | | 63 | { |
64 | } | | 64 | } |
65 | //indent end | | 65 | //indent end |
66 | | | 66 | |
67 | //indent run-equals-input -nbbb | | 67 | //indent run-equals-input -nbbb |
68 | | | 68 | |
69 | | | 69 | |
70 | //indent input | | 70 | //indent input |
71 | { | | 71 | { |
72 | label: /* not a block comment */ | | 72 | label: /* not a block comment */ |
73 | stmt; /* not a block comment */ | | 73 | stmt; /* not a block comment */ |
| | | 74 | label: /* |
| | | 75 | * This is not a block comment, as it goes to the right. |
| | | 76 | */ |
| | | 77 | stmt; /* |
| | | 78 | * This is not a block comment, as it goes to |
| | | 79 | * the right. |
| | | 80 | */ |
74 | /** | | 81 | /** |
75 | * block comment | | 82 | * This is a block comment. |
76 | */ | | 83 | */ |
77 | } | | 84 | } |
78 | //indent end | | 85 | //indent end |
79 | | | 86 | |
80 | //indent run -bbb | | 87 | //indent run -bbb |
81 | { | | 88 | { |
82 | label: /* not a block comment */ | | 89 | label: /* not a block comment */ |
83 | stmt; /* not a block comment */ | | 90 | stmt; /* not a block comment */ |
84 | | | 91 | |
| | | 92 | // $ TODO: No blank line before this comment. |
| | | 93 | label: /* This is not a block comment, as it goes to |
| | | 94 | * the right. */ |
| | | 95 | |
| | | 96 | // $ TODO: No blank line before this comment. |
| | | 97 | stmt; /* This is not a block comment, as it goes to |
| | | 98 | * the right. */ |
| | | 99 | |
85 | /** | | 100 | /** |
86 | * block comment | | 101 | * This is a block comment. |
87 | */ | | 102 | */ |
88 | } | | 103 | } |
89 | //indent end | | 104 | //indent end |