Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/indent indent: document feature toggle for debugging...



details:   https://anonhg.NetBSD.org/src/rev/9f6e8f8d1759
branches:  trunk
changeset: 375333:9f6e8f8d1759
user:      rillig <rillig%NetBSD.org@localhost>
date:      Mon May 15 09:00:51 2023 +0000

description:
indent: document feature toggle for debugging output

diffstat:

 usr.bin/indent/debug.c |  13 +++++++++----
 1 files changed, 9 insertions(+), 4 deletions(-)

diffs (40 lines):

diff -r 967e9c59768c -r 9f6e8f8d1759 usr.bin/indent/debug.c
--- a/usr.bin/indent/debug.c    Mon May 15 08:56:39 2023 +0000
+++ b/usr.bin/indent/debug.c    Mon May 15 09:00:51 2023 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: debug.c,v 1.6 2023/05/15 07:57:22 rillig Exp $ */
+/*     $NetBSD: debug.c,v 1.7 2023/05/15 09:00:51 rillig Exp $ */
 
 /*-
  * Copyright (c) 2023 The NetBSD Foundation, Inc.
@@ -30,13 +30,20 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: debug.c,v 1.6 2023/05/15 07:57:22 rillig Exp $");
+__RCSID("$NetBSD: debug.c,v 1.7 2023/05/15 09:00:51 rillig Exp $");
 
 #include <stdarg.h>
 
 #include "indent.h"
 
 #ifdef debug
+
+/*
+ * false       show only the changes to the parser state
+ * true                show unchanged parts of the parser state as well
+ */
+static bool debug_full_parser_state = true;
+
 const char *const lsym_name[] = {
     "eof",
     "preprocessing",
@@ -105,8 +112,6 @@ static const char *in_enum_name[] = {
     "brace",
 };
 
-static bool debug_full_parser_state = true;
-
 void
 debug_printf(const char *fmt, ...)
 {



Home | Main Index | Thread Index | Old Index