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): make code in the :S modifier simpler
details: https://anonhg.NetBSD.org/src/rev/e46cdca55c02
branches: trunk
changeset: 936388:e46cdca55c02
user: rillig <rillig%NetBSD.org@localhost>
date: Sun Jul 26 12:27:09 2020 +0000
description:
make(1): make code in the :S modifier simpler
This code path is covered by the "sequences of letters" in modmisc.mk.
diffstat:
usr.bin/make/var.c | 9 ++++-----
1 files changed, 4 insertions(+), 5 deletions(-)
diffs (36 lines):
diff -r 5ebf8f5b7420 -r e46cdca55c02 usr.bin/make/var.c
--- a/usr.bin/make/var.c Sun Jul 26 12:19:37 2020 +0000
+++ b/usr.bin/make/var.c Sun Jul 26 12:27:09 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: var.c,v 1.310 2020/07/26 12:19:37 rillig Exp $ */
+/* $NetBSD: var.c,v 1.311 2020/07/26 12:27:09 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: var.c,v 1.310 2020/07/26 12:19:37 rillig Exp $";
+static char rcsid[] = "$NetBSD: var.c,v 1.311 2020/07/26 12:27:09 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.310 2020/07/26 12:19:37 rillig Exp $");
+__RCSID("$NetBSD: var.c,v 1.311 2020/07/26 12:27:09 rillig Exp $");
#endif
#endif /* not lint */
#endif
@@ -1298,8 +1298,7 @@
ModifyWord_SubstArgs *args = data;
const VarPatternFlags pflags = args->pflags;
- if ((pflags & (VARP_SUB_ONE | VARP_SUB_MATCHED)) ==
- (VARP_SUB_ONE | VARP_SUB_MATCHED))
+ if ((pflags & VARP_SUB_ONE) && (pflags & VARP_SUB_MATCHED))
goto nosub;
if (args->pflags & VARP_ANCHOR_START) {
Home |
Main Index |
Thread Index |
Old Index