tests/indent: comments with trailing whitespace may fit in a single line

This commit is contained in:
rillig 2023-06-06 05:39:49 +00:00
parent ead98580d5
commit 5bf8b14793
1 changed files with 20 additions and 1 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: lsym_comment.c,v 1.16 2023/06/05 08:22:00 rillig Exp $ */
/* $NetBSD: lsym_comment.c,v 1.17 2023/06/06 05:39:49 rillig Exp $ */
/*
* Tests for the token lsym_comment, which starts a comment.
@ -370,6 +370,25 @@ tab1+++ tab2--- tab3+++ tab4--- tab5+++ tab6--- tab7+++fixed comment*/
//indent end
/*
* TODO: Trailing whitespace in a comment is ignored when determining whether the
* comment fits in a single line.
*/
//indent input
/* 456789 123456789 123456789 12345 */
/* 456789 123456789 123456789 123456 */
//indent end
//indent run -l38
/*
* 456789 123456789 123456789 12345
*/
/*
* 456789 123456789 123456789 123456
*/
//indent end
/*
* The following comments test line breaking when the comment does not end
* with a space. Since indent adds a trailing space to a single-line comment,