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