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): clean up comments in .for handling



details:   https://anonhg.NetBSD.org/src/rev/aad011f8fc0f
branches:  trunk
changeset: 941634:aad011f8fc0f
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Oct 25 16:18:02 2020 +0000

description:
make(1): clean up comments in .for handling

diffstat:

 usr.bin/make/for.c |  11 +++--------
 1 files changed, 3 insertions(+), 8 deletions(-)

diffs (34 lines):

diff -r 597edc80a0bc -r aad011f8fc0f usr.bin/make/for.c
--- a/usr.bin/make/for.c        Sun Oct 25 16:15:48 2020 +0000
+++ b/usr.bin/make/for.c        Sun Oct 25 16:18:02 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: for.c,v 1.107 2020/10/25 16:15:48 rillig Exp $ */
+/*     $NetBSD: for.c,v 1.108 2020/10/25 16:18:02 rillig Exp $ */
 
 /*
  * Copyright (c) 1992, The Regents of the University of California.
@@ -60,7 +60,7 @@
 #include    "make.h"
 
 /*     "@(#)for.c      8.1 (Berkeley) 6/6/93"  */
-MAKE_RCSID("$NetBSD: for.c,v 1.107 2020/10/25 16:15:48 rillig Exp $");
+MAKE_RCSID("$NetBSD: for.c,v 1.108 2020/10/25 16:18:02 rillig Exp $");
 
 /* The .for loop substitutes the items as ${:U<value>...}, which means
  * that characters that break this syntax must be backslash-escaped. */
@@ -178,14 +178,9 @@
     For *new_for;
     const char *p;
 
-    /* Skip the '.' and any following whitespace */
-    p = line + 1;
+    p = line + 1;              /* skip the '.' */
     cpp_skip_whitespace(&p);
 
-    /*
-     * If we are not in a for loop quickly determine if the statement is
-     * a for.
-     */
     if (!IsFor(p)) {
        if (IsEndfor(p)) {
            Parse_Error(PARSE_FATAL, "for-less endfor");



Home | Main Index | Thread Index | Old Index