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): use complete words in error message fo...



details:   https://anonhg.NetBSD.org/src/rev/64ecb5eeadb4
branches:  trunk
changeset: 945296:64ecb5eeadb4
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Oct 25 16:15:48 2020 +0000

description:
make(1): use complete words in error message for .for loop

diffstat:

 usr.bin/make/for.c                  |  6 +++---
 usr.bin/make/unit-tests/forloop.exp |  2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

diffs (39 lines):

diff -r f52377fbade0 -r 64ecb5eeadb4 usr.bin/make/for.c
--- a/usr.bin/make/for.c        Sun Oct 25 16:14:08 2020 +0000
+++ b/usr.bin/make/for.c        Sun Oct 25 16:15:48 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: for.c,v 1.106 2020/10/25 16:14:08 rillig Exp $ */
+/*     $NetBSD: for.c,v 1.107 2020/10/25 16:15:48 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.106 2020/10/25 16:14:08 rillig Exp $");
+MAKE_RCSID("$NetBSD: for.c,v 1.107 2020/10/25 16:15:48 rillig Exp $");
 
 /* The .for loop substitutes the items as ${:U<value>...}, which means
  * that characters that break this syntax must be backslash-escaped. */
@@ -260,7 +260,7 @@
            nitems % (nvars = new_for->vars.len)) {
            Parse_Error(PARSE_FATAL,
                        "Wrong number of words (%zu) in .for substitution list"
-                       " with %zu vars", nitems, nvars);
+                       " with %zu variables", nitems, nvars);
            /*
             * Return 'success' so that the body of the .for loop is
             * accumulated.
diff -r f52377fbade0 -r 64ecb5eeadb4 usr.bin/make/unit-tests/forloop.exp
--- a/usr.bin/make/unit-tests/forloop.exp       Sun Oct 25 16:14:08 2020 +0000
+++ b/usr.bin/make/unit-tests/forloop.exp       Sun Oct 25 16:15:48 2020 +0000
@@ -13,7 +13,7 @@
 a=ONE b="TWO AND THREE"
 a=FOUR b="FIVE"
 We expect an error next:
-make: "forloop.mk" line 46: Wrong number of words (9) in .for substitution list with 2 vars
+make: "forloop.mk" line 46: Wrong number of words (9) in .for substitution list with 2 variables
 make: Fatal errors encountered -- cannot continue
 make: stopped in unit-tests
 OK



Home | Main Index | Thread Index | Old Index