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: remove redundant checks in processing...



details:   https://anonhg.NetBSD.org/src/rev/fe5519b240a5
branches:  trunk
changeset: 375906:fe5519b240a5
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sat May 20 16:31:31 2023 +0000

description:
indent: remove redundant checks in processing of '}'

No functional change.

diffstat:

 usr.bin/indent/indent.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 813ba8af782e -r fe5519b240a5 usr.bin/indent/indent.c
--- a/usr.bin/indent/indent.c   Sat May 20 14:44:29 2023 +0000
+++ b/usr.bin/indent/indent.c   Sat May 20 16:31:31 2023 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: indent.c,v 1.299 2023/05/20 11:53:53 rillig Exp $      */
+/*     $NetBSD: indent.c,v 1.300 2023/05/20 16:31:31 rillig Exp $      */
 
 /*-
  * SPDX-License-Identifier: BSD-4-Clause
@@ -38,7 +38,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: indent.c,v 1.299 2023/05/20 11:53:53 rillig Exp $");
+__RCSID("$NetBSD: indent.c,v 1.300 2023/05/20 16:31:31 rillig Exp $");
 
 #include <sys/param.h>
 #include <err.h>
@@ -750,7 +750,7 @@ process_rbrace(void)
                ps.in_decl = true;
        }
 
-       if (ps.tos == 2 && code.len == 1 && code.st[0] == '}')
+       if (ps.tos == 2)
                out.line_kind = lk_func_end;
 
        parse(psym_rbrace);



Home | Main Index | Thread Index | Old Index