Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/usr.bin/indent tests/indent: test more single-line com...



details:   https://anonhg.NetBSD.org/src/rev/910c0242f282
branches:  trunk
changeset: 1024222:910c0242f282
user:      rillig <rillig%NetBSD.org@localhost>
date:      Tue Oct 12 20:52:02 2021 +0000

description:
tests/indent: test more single-line comments

diffstat:

 tests/usr.bin/indent/token-comment.0        |  12 +++++++++++-
 tests/usr.bin/indent/token-comment.0.stdout |  25 ++++++++++++++++++++++++-
 2 files changed, 35 insertions(+), 2 deletions(-)

diffs (65 lines):

diff -r 0ec8a05cce08 -r 910c0242f282 tests/usr.bin/indent/token-comment.0
--- a/tests/usr.bin/indent/token-comment.0      Tue Oct 12 19:57:53 2021 +0000
+++ b/tests/usr.bin/indent/token-comment.0      Tue Oct 12 20:52:02 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: token-comment.0,v 1.9 2021/10/12 19:05:22 rillig Exp $ */
+/* $NetBSD: token-comment.0,v 1.10 2021/10/12 20:52:02 rillig Exp $ */
 /* $FreeBSD$ */
 
 /*
@@ -15,6 +15,16 @@
 /* 456789 123456789 123456789 123456789 123456789 123456789 123456789 12345678 */
 /* 456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 */
 
+/* $ In the following comments, the line length is measured after formatting. */
+/* x                                                   . line length 75*/
+/* x                                                   .. line length 76*/
+/* x                                                   ... line length 77*/
+/* x                                                   .... line length 78*/
+/* x                                                   ..... line length 79*/
+/* x                                                   ...... line length 80*/
+/* x                                                   ....... line length 81*/
+/* x                                                   ........ line length 82*/
+
 /* This is a traditional C block comment. */
 
 // This is a C99 line comment.
diff -r 0ec8a05cce08 -r 910c0242f282 tests/usr.bin/indent/token-comment.0.stdout
--- a/tests/usr.bin/indent/token-comment.0.stdout       Tue Oct 12 19:57:53 2021 +0000
+++ b/tests/usr.bin/indent/token-comment.0.stdout       Tue Oct 12 20:52:02 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: token-comment.0.stdout,v 1.11 2021/10/12 19:05:22 rillig Exp $ */
+/* $NetBSD: token-comment.0.stdout,v 1.12 2021/10/12 20:52:02 rillig Exp $ */
 /* $FreeBSD$ */
 
 /*
@@ -24,6 +24,29 @@
  * 123456789
  */
 
+/* x                                                   . line length 75 */
+/* x                                                   .. line length 76 */
+/* $ FIXME: the following comment is short enough for a single line. */
+/*
+ * x                                                   ... line length 77
+ */
+/* $ FIXME: the following comment is short enough for a single line. */
+/*
+ * x                                                   .... line length 78
+ */
+/*
+ * x                                                   ..... line length 79
+ */
+/*
+ * x                                                   ...... line length 80
+ */
+/*
+ * x                                                   ....... line length 81
+ */
+/*
+ * x                                                   ........ line length 82
+ */
+
 /* This is a traditional C block comment. */
 
 // This is a C99 line comment.



Home | Main Index | Thread Index | Old Index