Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/make make(1): remove unnecessary assignment in Var_P...



details:   https://anonhg.NetBSD.org/src/rev/07347fec3e90
branches:  trunk
changeset: 936727:07347fec3e90
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Aug 02 15:26:49 2020 +0000

description:
make(1): remove unnecessary assignment in Var_Parse

In a variable expression without braces or parentheses, it is not
possible to have modifiers.  Therefore the assigned endc could not have
been used anywhere.

diffstat:

 usr.bin/make/var.c |  7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diffs (34 lines):

diff -r 59e9d4d48f7f -r 07347fec3e90 usr.bin/make/var.c
--- a/usr.bin/make/var.c        Sun Aug 02 15:22:53 2020 +0000
+++ b/usr.bin/make/var.c        Sun Aug 02 15:26:49 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: var.c,v 1.397 2020/08/02 12:43:40 rillig Exp $ */
+/*     $NetBSD: var.c,v 1.398 2020/08/02 15:26:49 rillig Exp $ */
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
  */
 
 #ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: var.c,v 1.397 2020/08/02 12:43:40 rillig Exp $";
+static char rcsid[] = "$NetBSD: var.c,v 1.398 2020/08/02 15:26:49 rillig Exp $";
 #else
 #include <sys/cdefs.h>
 #ifndef lint
 #if 0
 static char sccsid[] = "@(#)var.c      8.3 (Berkeley) 3/19/94";
 #else
-__RCSID("$NetBSD: var.c,v 1.397 2020/08/02 12:43:40 rillig Exp $");
+__RCSID("$NetBSD: var.c,v 1.398 2020/08/02 15:26:49 rillig Exp $");
 #endif
 #endif /* not lint */
 #endif
@@ -3427,7 +3427,6 @@
        } else {
            haveModifier = FALSE;
            tstr = str + 1;
-           endc = str[1];
        }
     } else {
        endc = startc == PROPEN ? PRCLOSE : BRCLOSE;



Home | Main Index | Thread Index | Old Index