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): inline Lst_ForEachUntil in MakeStartJobs



details:   https://anonhg.NetBSD.org/src/rev/b48e69ba01bb
branches:  trunk
changeset: 946359:b48e69ba01bb
user:      rillig <rillig%NetBSD.org@localhost>
date:      Tue Nov 24 22:45:24 2020 +0000

description:
make(1): inline Lst_ForEachUntil in MakeStartJobs

diffstat:

 usr.bin/make/make.c |  15 ++++++++++++---
 1 files changed, 12 insertions(+), 3 deletions(-)

diffs (36 lines):

diff -r 2f793ee63a43 -r b48e69ba01bb usr.bin/make/make.c
--- a/usr.bin/make/make.c       Tue Nov 24 22:32:18 2020 +0000
+++ b/usr.bin/make/make.c       Tue Nov 24 22:45:24 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: make.c,v 1.212 2020/11/24 22:32:18 rillig Exp $        */
+/*     $NetBSD: make.c,v 1.213 2020/11/24 22:45:24 rillig Exp $        */
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -102,7 +102,7 @@
 #include "job.h"
 
 /*     "@(#)make.c     8.1 (Berkeley) 6/6/93"  */
-MAKE_RCSID("$NetBSD: make.c,v 1.212 2020/11/24 22:32:18 rillig Exp $");
+MAKE_RCSID("$NetBSD: make.c,v 1.213 2020/11/24 22:45:24 rillig Exp $");
 
 /* Sequence # to detect recursion. */
 static unsigned int checked_seqno = 1;
@@ -945,7 +945,16 @@
             * just before the current first element.
             */
            gn->made = DEFERRED;
-           Lst_ForEachUntil(gn->children, MakeBuildChild, toBeMade->first);
+
+           {
+               GNodeListNode *firstToBeMade = toBeMade->first;
+               GNodeListNode *ln;
+
+               for (ln = gn->children->first; ln != NULL; ln = ln->next)
+                   if (MakeBuildChild(ln->datum, firstToBeMade) != 0)
+                       break;
+           }
+
            /* and drop this node on the floor */
            DEBUG2(MAKE, "dropped %s%s\n", gn->name, gn->cohort_num);
            continue;



Home | Main Index | Thread Index | Old Index