Module Name:    src
Committed By:   rillig
Date:           Mon Apr  5 13:14:55 UTC 2021

Modified Files:
        src/usr.bin/make: var.c
        src/usr.bin/make/unit-tests: directive-export-impl.exp
            directive-unexport-env.exp var-eval-short.exp var-op-append.exp
            vardebug.exp varmod-assign.exp varmod-defined.exp
            varmod-indirect.exp varmod-match-escape.exp varname-empty.exp
            varname.exp

Log Message:
make: be more verbose in -dv debug logging

The previous log output was too brief to be understandable.  Give more
hints by describing each part of the expression when evaluating a
modifier.  Distinguish between parse-only mode and eval mode since in
parse-only mode most of the details are irrelevant.


To generate a diff of this commit:
cvs rdiff -u -r1.908 -r1.909 src/usr.bin/make/var.c
cvs rdiff -u -r1.9 -r1.10 \
    src/usr.bin/make/unit-tests/directive-export-impl.exp
cvs rdiff -u -r1.7 -r1.8 \
    src/usr.bin/make/unit-tests/directive-unexport-env.exp \
    src/usr.bin/make/unit-tests/var-op-append.exp
cvs rdiff -u -r1.11 -r1.12 src/usr.bin/make/unit-tests/var-eval-short.exp \
    src/usr.bin/make/unit-tests/varname-empty.exp
cvs rdiff -u -r1.20 -r1.21 src/usr.bin/make/unit-tests/vardebug.exp
cvs rdiff -u -r1.12 -r1.13 src/usr.bin/make/unit-tests/varmod-assign.exp
cvs rdiff -u -r1.6 -r1.7 src/usr.bin/make/unit-tests/varmod-defined.exp
cvs rdiff -u -r1.15 -r1.16 src/usr.bin/make/unit-tests/varmod-indirect.exp
cvs rdiff -u -r1.10 -r1.11 \
    src/usr.bin/make/unit-tests/varmod-match-escape.exp
cvs rdiff -u -r1.14 -r1.15 src/usr.bin/make/unit-tests/varname.exp

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/make/var.c
diff -u src/usr.bin/make/var.c:1.908 src/usr.bin/make/var.c:1.909
--- src/usr.bin/make/var.c:1.908	Mon Apr  5 12:51:35 2021
+++ src/usr.bin/make/var.c	Mon Apr  5 13:14:54 2021
@@ -1,4 +1,4 @@
-/*	$NetBSD: var.c,v 1.908 2021/04/05 12:51:35 rillig Exp $	*/
+/*	$NetBSD: var.c,v 1.909 2021/04/05 13:14:54 rillig Exp $	*/
 
 /*
  * Copyright (c) 1988, 1989, 1990, 1993
@@ -140,7 +140,7 @@
 #include "metachar.h"
 
 /*	"@(#)var.c	8.3 (Berkeley) 3/19/94" */
-MAKE_RCSID("$NetBSD: var.c,v 1.908 2021/04/05 12:51:35 rillig Exp $");
+MAKE_RCSID("$NetBSD: var.c,v 1.909 2021/04/05 13:14:54 rillig Exp $");
 
 /*
  * Variables are defined using one of the VAR=value assignments.  Their
@@ -3661,11 +3661,20 @@ LogBeforeApply(const ModChain *ch, const
 	const Expr *expr = ch->expr;
 	bool is_single_char = mod[0] != '\0' && IsDelimiter(mod[1], ch);
 
-	/* At this point, only the first character of the modifier can
-	 * be used since the end of the modifier is not yet known. */
-	debug_printf("Applying ${%s:%c%s} to \"%s\" (%s, %s)\n",
-	    expr->name, mod[0], is_single_char ? "" : "...",
-	    expr->value.str,
+	/*
+	 * At this point, only the first character of the modifier can
+	 * be used since the end of the modifier is not yet known.
+	 */
+
+	if (!Expr_ShouldEval(expr)) {
+		debug_printf("Parsing modifier ${%s:%c%s}\n",
+		    expr->name, mod[0], is_single_char ? "" : "...");
+		return;
+	}
+
+	debug_printf(
+	    "Evaluating modifier ${%s:%c%s} on value \"%s\" (%s, %s)\n",
+	    expr->name, mod[0], is_single_char ? "" : "...", expr->value.str,
 	    VarEvalMode_Name[expr->emode],
 	    ExprDefined_Name[expr->defined]);
 }

Index: src/usr.bin/make/unit-tests/directive-export-impl.exp
diff -u src/usr.bin/make/unit-tests/directive-export-impl.exp:1.9 src/usr.bin/make/unit-tests/directive-export-impl.exp:1.10
--- src/usr.bin/make/unit-tests/directive-export-impl.exp:1.9	Mon Apr  5 12:51:35 2021
+++ src/usr.bin/make/unit-tests/directive-export-impl.exp	Mon Apr  5 13:14:55 2021
@@ -5,19 +5,19 @@ Global:.MAKE.EXPORTED = UT_VAR
 ParseReadLine (32): ': ${UT_VAR:N*}'
 Var_Parse: ${UT_VAR:N*} (eval-defined)
 Var_Parse: ${REF}> (eval-defined)
-Applying ${UT_VAR:N...} to "<>" (eval-defined, regular)
+Evaluating modifier ${UT_VAR:N...} on value "<>" (eval-defined, regular)
 Pattern for ':N' is "*"
 ModifyWords: split "<>" into 1 words
 Result of ${UT_VAR:N*} is "" (eval-defined, regular)
 ParseDependency(: )
 CondParser_Eval: ${:!echo "\$UT_VAR"!} != "<>"
 Var_Parse: ${:!echo "\$UT_VAR"!} != "<>" (eval-defined)
-Applying ${:!...} to "" (eval-defined, undefined)
+Evaluating modifier ${:!...} on value "" (eval-defined, undefined)
 Modifier part: "echo "$UT_VAR""
 Var_Parse: ${.MAKE.EXPORTED:O:u} (eval)
-Applying ${.MAKE.EXPORTED:O} to "UT_VAR" (eval, regular)
+Evaluating modifier ${.MAKE.EXPORTED:O} on value "UT_VAR" (eval, regular)
 Result of ${.MAKE.EXPORTED:O} is "UT_VAR" (eval, regular)
-Applying ${.MAKE.EXPORTED:u} to "UT_VAR" (eval, regular)
+Evaluating modifier ${.MAKE.EXPORTED:u} on value "UT_VAR" (eval, regular)
 Result of ${.MAKE.EXPORTED:u} is "UT_VAR" (eval, regular)
 Var_Parse: ${UT_VAR} (eval)
 Var_Parse: ${REF}> (eval)
@@ -26,7 +26,7 @@ lhs = "<>", rhs = "<>", op = !=
 ParseReadLine (50): ': ${UT_VAR:N*}'
 Var_Parse: ${UT_VAR:N*} (eval-defined)
 Var_Parse: ${REF}> (eval-defined)
-Applying ${UT_VAR:N...} to "<>" (eval-defined, regular)
+Evaluating modifier ${UT_VAR:N...} on value "<>" (eval-defined, regular)
 Pattern for ':N' is "*"
 ModifyWords: split "<>" into 1 words
 Result of ${UT_VAR:N*} is "" (eval-defined, regular)
@@ -35,12 +35,12 @@ ParseReadLine (54): 'REF=		defined'
 Global:REF = defined
 CondParser_Eval: ${:!echo "\$UT_VAR"!} != "<defined>"
 Var_Parse: ${:!echo "\$UT_VAR"!} != "<defined>" (eval-defined)
-Applying ${:!...} to "" (eval-defined, undefined)
+Evaluating modifier ${:!...} on value "" (eval-defined, undefined)
 Modifier part: "echo "$UT_VAR""
 Var_Parse: ${.MAKE.EXPORTED:O:u} (eval)
-Applying ${.MAKE.EXPORTED:O} to "UT_VAR" (eval, regular)
+Evaluating modifier ${.MAKE.EXPORTED:O} on value "UT_VAR" (eval, regular)
 Result of ${.MAKE.EXPORTED:O} is "UT_VAR" (eval, regular)
-Applying ${.MAKE.EXPORTED:u} to "UT_VAR" (eval, regular)
+Evaluating modifier ${.MAKE.EXPORTED:u} on value "UT_VAR" (eval, regular)
 Result of ${.MAKE.EXPORTED:u} is "UT_VAR" (eval, regular)
 Var_Parse: ${UT_VAR} (eval)
 Var_Parse: ${REF}> (eval)

Index: src/usr.bin/make/unit-tests/directive-unexport-env.exp
diff -u src/usr.bin/make/unit-tests/directive-unexport-env.exp:1.7 src/usr.bin/make/unit-tests/directive-unexport-env.exp:1.8
--- src/usr.bin/make/unit-tests/directive-unexport-env.exp:1.7	Sat Apr  3 22:02:59 2021
+++ src/usr.bin/make/unit-tests/directive-unexport-env.exp	Mon Apr  5 13:14:55 2021
@@ -5,9 +5,9 @@ Global:UT_UNEXPORTED = value
 Global:.MAKE.EXPORTED = UT_EXPORTED
 make: "directive-unexport-env.mk" line 21: The directive .unexport-env does not take arguments
 Var_Parse: ${.MAKE.EXPORTED:O:u} (eval)
-Applying ${.MAKE.EXPORTED:O} to "UT_EXPORTED" (eval, regular)
+Evaluating modifier ${.MAKE.EXPORTED:O} on value "UT_EXPORTED" (eval, regular)
 Result of ${.MAKE.EXPORTED:O} is "UT_EXPORTED" (eval, regular)
-Applying ${.MAKE.EXPORTED:u} to "UT_EXPORTED" (eval, regular)
+Evaluating modifier ${.MAKE.EXPORTED:u} on value "UT_EXPORTED" (eval, regular)
 Result of ${.MAKE.EXPORTED:u} is "UT_EXPORTED" (eval, regular)
 Unexporting "UT_EXPORTED"
 Global:delete .MAKE.EXPORTED
Index: src/usr.bin/make/unit-tests/var-op-append.exp
diff -u src/usr.bin/make/unit-tests/var-op-append.exp:1.7 src/usr.bin/make/unit-tests/var-op-append.exp:1.8
--- src/usr.bin/make/unit-tests/var-op-append.exp:1.7	Sat Apr  3 22:02:59 2021
+++ src/usr.bin/make/unit-tests/var-op-append.exp	Mon Apr  5 13:14:55 2021
@@ -1,5 +1,5 @@
 Var_Parse: ${:U\$\$\$\$\$\$\$\$} (eval)
-Applying ${:U...} to "" (eval, undefined)
+Evaluating modifier ${:U...} on value "" (eval, undefined)
 Result of ${:U\$\$\$\$\$\$\$\$} is "$$$$$$$$" (eval, defined)
 Global:VAR.$$$$$$$$ = dollars
 Global:.MAKEFLAGS =  -r -k -d v -d

Index: src/usr.bin/make/unit-tests/var-eval-short.exp
diff -u src/usr.bin/make/unit-tests/var-eval-short.exp:1.11 src/usr.bin/make/unit-tests/var-eval-short.exp:1.12
--- src/usr.bin/make/unit-tests/var-eval-short.exp:1.11	Sun Apr  4 13:35:26 2021
+++ src/usr.bin/make/unit-tests/var-eval-short.exp	Mon Apr  5 13:14:55 2021
@@ -6,7 +6,7 @@ make: "var-eval-short.mk" line 93: Inval
 make: "var-eval-short.mk" line 93: Malformed conditional (0 && ${:Uword:localtime=${FAIL}})
 CondParser_Eval: 0 && ${0:?${FAIL}then:${FAIL}else}
 Var_Parse: ${0:?${FAIL}then:${FAIL}else} (parse-only)
-Applying ${0:?...} to "" (parse-only, undefined)
+Parsing modifier ${0:?...}
 Modifier part: "${FAIL}then"
 Modifier part: "${FAIL}else"
 Result of ${0:?${FAIL}then:${FAIL}else} is "" (parse-only, defined)
@@ -14,9 +14,9 @@ ParseReadLine (158): 'DEFINED=	defined'
 Global:DEFINED = defined
 CondParser_Eval: 0 && ${DEFINED:L:?${FAIL}then:${FAIL}else}
 Var_Parse: ${DEFINED:L:?${FAIL}then:${FAIL}else} (parse-only)
-Applying ${DEFINED:L} to "defined" (parse-only, regular)
+Parsing modifier ${DEFINED:L}
 Result of ${DEFINED:L} is "defined" (parse-only, regular)
-Applying ${DEFINED:?...} to "defined" (parse-only, regular)
+Parsing modifier ${DEFINED:?...}
 Modifier part: "${FAIL}then"
 Modifier part: "${FAIL}else"
 Result of ${DEFINED:?${FAIL}then:${FAIL}else} is "defined" (parse-only, regular)
Index: src/usr.bin/make/unit-tests/varname-empty.exp
diff -u src/usr.bin/make/unit-tests/varname-empty.exp:1.11 src/usr.bin/make/unit-tests/varname-empty.exp:1.12
--- src/usr.bin/make/unit-tests/varname-empty.exp:1.11	Sat Apr  3 22:02:59 2021
+++ src/usr.bin/make/unit-tests/varname-empty.exp	Mon Apr  5 13:14:55 2021
@@ -1,11 +1,11 @@
 Var_Parse: ${:U} (eval)
-Applying ${:U} to "" (eval, undefined)
+Evaluating modifier ${:U} on value "" (eval, undefined)
 Result of ${:U} is "" (eval, defined)
 Var_Set("${:U}", "cmdline-u", ...) name expands to empty string - ignored
 Var_Set("", "cmdline-plain", ...) name expands to empty string - ignored
 Global:.CURDIR = <curdir>
 Var_Parse: ${MAKE_OBJDIR_CHECK_WRITABLE:U} (eval)
-Applying ${MAKE_OBJDIR_CHECK_WRITABLE:U} to "" (eval, undefined)
+Evaluating modifier ${MAKE_OBJDIR_CHECK_WRITABLE:U} on value "" (eval, undefined)
 Result of ${MAKE_OBJDIR_CHECK_WRITABLE:U} is "" (eval, defined)
 Global:.OBJDIR = <curdir>
 Global:delete .PATH (not found)
@@ -24,21 +24,21 @@ Var_Set("", "", ...) name expands to emp
 Var_Set("", "subst", ...) name expands to empty string - ignored
 Var_Set("", "shell-output", ...) name expands to empty string - ignored
 Var_Parse: ${:Ufallback} != "fallback" (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:Ufallback} is "fallback" (eval-defined, defined)
 Var_Parse: ${:U} (eval)
-Applying ${:U} to "" (eval, undefined)
+Evaluating modifier ${:U} on value "" (eval, undefined)
 Result of ${:U} is "" (eval, defined)
 Var_Set("${:U}", "assigned indirectly", ...) name expands to empty string - ignored
 Var_Parse: ${:Ufallback} != "fallback" (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:Ufallback} is "fallback" (eval-defined, defined)
 Var_Parse: ${:U} (eval)
-Applying ${:U} to "" (eval, undefined)
+Evaluating modifier ${:U} on value "" (eval, undefined)
 Result of ${:U} is "" (eval, defined)
 Var_Append("${:U}", "appended indirectly", ...) name expands to empty string - ignored
 Var_Parse: ${:Ufallback} != "fallback" (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:Ufallback} is "fallback" (eval-defined, defined)
 Global:.MAKEFLAGS =  -r -d v -d
 Global:.MAKEFLAGS =  -r -d v -d 0

Index: src/usr.bin/make/unit-tests/vardebug.exp
diff -u src/usr.bin/make/unit-tests/vardebug.exp:1.20 src/usr.bin/make/unit-tests/vardebug.exp:1.21
--- src/usr.bin/make/unit-tests/vardebug.exp:1.20	Mon Apr  5 12:51:35 2021
+++ src/usr.bin/make/unit-tests/vardebug.exp	Mon Apr  5 13:14:55 2021
@@ -6,11 +6,11 @@ Global:VAR = overwritten
 Global:delete VAR
 Global:delete VAR (not found)
 Var_Parse: ${:U} (eval)
-Applying ${:U} to "" (eval, undefined)
+Evaluating modifier ${:U} on value "" (eval, undefined)
 Result of ${:U} is "" (eval, defined)
 Var_Set("${:U}", "empty name", ...) name expands to empty string - ignored
 Var_Parse: ${:U} (eval)
-Applying ${:U} to "" (eval, undefined)
+Evaluating modifier ${:U} on value "" (eval, undefined)
 Result of ${:U} is "" (eval, defined)
 Var_Append("${:U}", "empty name", ...) name expands to empty string - ignored
 Global:FROM_CMDLINE = overwritten ignored!
@@ -18,54 +18,54 @@ Global:VAR = 1
 Global:VAR = 1 2
 Global:VAR = 1 2 3
 Var_Parse: ${VAR:M[2]} (eval-defined)
-Applying ${VAR:M...} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:M...} on value "1 2 3" (eval-defined, regular)
 Pattern for ':M' is "[2]"
 ModifyWords: split "1 2 3" into 3 words
 Result of ${VAR:M[2]} is "2" (eval-defined, regular)
 Var_Parse: ${VAR:N[2]} (eval-defined)
-Applying ${VAR:N...} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:N...} on value "1 2 3" (eval-defined, regular)
 Pattern for ':N' is "[2]"
 ModifyWords: split "1 2 3" into 3 words
 Result of ${VAR:N[2]} is "1 3" (eval-defined, regular)
 Var_Parse: ${VAR:S,2,two,} (eval-defined)
-Applying ${VAR:S...} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:S...} on value "1 2 3" (eval-defined, regular)
 Modifier part: "2"
 Modifier part: "two"
 ModifyWords: split "1 2 3" into 3 words
 Result of ${VAR:S,2,two,} is "1 two 3" (eval-defined, regular)
 Var_Parse: ${VAR:Q} (eval-defined)
-Applying ${VAR:Q} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:Q} on value "1 2 3" (eval-defined, regular)
 Result of ${VAR:Q} is "1\ 2\ 3" (eval-defined, regular)
 Var_Parse: ${VAR:tu:tl:Q} (eval-defined)
-Applying ${VAR:t...} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:t...} on value "1 2 3" (eval-defined, regular)
 Result of ${VAR:tu} is "1 2 3" (eval-defined, regular)
-Applying ${VAR:t...} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:t...} on value "1 2 3" (eval-defined, regular)
 Result of ${VAR:tl} is "1 2 3" (eval-defined, regular)
-Applying ${VAR:Q} to "1 2 3" (eval-defined, regular)
+Evaluating modifier ${VAR:Q} on value "1 2 3" (eval-defined, regular)
 Result of ${VAR:Q} is "1\ 2\ 3" (eval-defined, regular)
 Var_Parse: ${:Uvalue:${:UM*e}:Mvalu[e]} (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:Uvalue} is "value" (eval-defined, defined)
 Var_Parse: ${:UM*e}:Mvalu[e]} (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:UM*e} is "M*e" (eval-defined, defined)
 Indirect modifier "M*e" from "${:UM*e}"
-Applying ${:M...} to "value" (eval-defined, defined)
+Evaluating modifier ${:M...} on value "value" (eval-defined, defined)
 Pattern for ':M' is "*e"
 ModifyWords: split "value" into 1 words
 Result of ${:M*e} is "value" (eval-defined, defined)
-Applying ${:M...} to "value" (eval-defined, defined)
+Evaluating modifier ${:M...} on value "value" (eval-defined, defined)
 Pattern for ':M' is "valu[e]"
 ModifyWords: split "value" into 1 words
 Result of ${:Mvalu[e]} is "value" (eval-defined, defined)
 Var_Parse: ${:UVAR} (eval)
-Applying ${:U...} to "" (eval, undefined)
+Evaluating modifier ${:U...} on value "" (eval, undefined)
 Result of ${:UVAR} is "VAR" (eval, defined)
 Global:delete VAR
 Var_Parse: ${:Uvariable:unknown} (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:Uvariable} is "variable" (eval-defined, defined)
-Applying ${:u...} to "variable" (eval-defined, defined)
+Evaluating modifier ${:u...} on value "variable" (eval-defined, defined)
 make: "vardebug.mk" line 44: Unknown modifier "unknown"
 Result of ${:unknown} is error (eval-defined, defined)
 make: "vardebug.mk" line 44: Malformed conditional (${:Uvariable:unknown})

Index: src/usr.bin/make/unit-tests/varmod-assign.exp
diff -u src/usr.bin/make/unit-tests/varmod-assign.exp:1.12 src/usr.bin/make/unit-tests/varmod-assign.exp:1.13
--- src/usr.bin/make/unit-tests/varmod-assign.exp:1.12	Sat Apr  3 22:02:59 2021
+++ src/usr.bin/make/unit-tests/varmod-assign.exp	Mon Apr  5 13:14:55 2021
@@ -4,7 +4,7 @@ Var_Parse: ${VARNAME} (eval)
 Global:VAR.${param} = initial-value
 Var_Parse: ${${VARNAME}::=assigned-value} (eval-defined)
 Var_Parse: ${VARNAME}::=assigned-value} (eval-defined)
-Applying ${VAR.${param}::...} to "initial-value" (eval-defined, regular)
+Evaluating modifier ${VAR.${param}::...} on value "initial-value" (eval-defined, regular)
 Modifier part: "assigned-value"
 Global:VAR.${param} = assigned-value
 Result of ${VAR.${param}::=assigned-value} is "" (eval-defined, regular)

Index: src/usr.bin/make/unit-tests/varmod-defined.exp
diff -u src/usr.bin/make/unit-tests/varmod-defined.exp:1.6 src/usr.bin/make/unit-tests/varmod-defined.exp:1.7
--- src/usr.bin/make/unit-tests/varmod-defined.exp:1.6	Sat Apr  3 22:02:59 2021
+++ src/usr.bin/make/unit-tests/varmod-defined.exp	Mon Apr  5 13:14:55 2021
@@ -3,12 +3,12 @@ Global:VAR = 
 Var_Parse: ${8_DOLLARS} (eval-keep-dollar-and-undefined)
 Global:VAR = $$$$$$$$
 Var_Parse: ${VAR:D${8_DOLLARS}} (eval-keep-dollar-and-undefined)
-Applying ${VAR:D...} to "$$$$$$$$" (eval-keep-dollar-and-undefined, regular)
+Evaluating modifier ${VAR:D...} on value "$$$$$$$$" (eval-keep-dollar-and-undefined, regular)
 Var_Parse: ${8_DOLLARS}} (eval-keep-dollar-and-undefined)
 Result of ${VAR:D${8_DOLLARS}} is "$$$$$$$$" (eval-keep-dollar-and-undefined, regular)
 Global:VAR = $$$$$$$$
 Var_Parse: ${VAR:@var@${8_DOLLARS}@} (eval-keep-dollar-and-undefined)
-Applying ${VAR:@...} to "$$$$$$$$" (eval-keep-dollar-and-undefined, regular)
+Evaluating modifier ${VAR:@...} on value "$$$$$$$$" (eval-keep-dollar-and-undefined, regular)
 Modifier part: "var"
 Modifier part: "${8_DOLLARS}"
 ModifyWords: split "$$$$$$$$" into 1 words

Index: src/usr.bin/make/unit-tests/varmod-indirect.exp
diff -u src/usr.bin/make/unit-tests/varmod-indirect.exp:1.15 src/usr.bin/make/unit-tests/varmod-indirect.exp:1.16
--- src/usr.bin/make/unit-tests/varmod-indirect.exp:1.15	Sun Apr  4 10:13:09 2021
+++ src/usr.bin/make/unit-tests/varmod-indirect.exp	Mon Apr  5 13:14:55 2021
@@ -17,39 +17,39 @@ Global:_ = before ${UNDEF} after
 ParseReadLine (169): '_:=	before ${UNDEF:${:US,a,a,}} after'
 Var_Parse: ${UNDEF:${:US,a,a,}} after (eval-keep-dollar-and-undefined)
 Var_Parse: ${:US,a,a,}} after (eval-keep-dollar-and-undefined)
-Applying ${:U...} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-keep-dollar-and-undefined, undefined)
 Result of ${:US,a,a,} is "S,a,a," (eval-keep-dollar-and-undefined, defined)
 Indirect modifier "S,a,a," from "${:US,a,a,}"
-Applying ${UNDEF:S...} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${UNDEF:S...} on value "" (eval-keep-dollar-and-undefined, undefined)
 Modifier part: "a"
 Modifier part: "a"
 ModifyWords: split "" into 1 words
 Result of ${UNDEF:S,a,a,} is "" (eval-keep-dollar-and-undefined, undefined)
 Var_Parse: ${:US,a,a,}} after (eval-keep-dollar-and-undefined)
-Applying ${:U...} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-keep-dollar-and-undefined, undefined)
 Result of ${:US,a,a,} is "S,a,a," (eval-keep-dollar-and-undefined, defined)
 Global:_ = before ${UNDEF:S,a,a,} after
 ParseReadLine (179): '_:=	before ${UNDEF:${:U}} after'
 Var_Parse: ${UNDEF:${:U}} after (eval-keep-dollar-and-undefined)
 Var_Parse: ${:U}} after (eval-keep-dollar-and-undefined)
-Applying ${:U} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${:U} on value "" (eval-keep-dollar-and-undefined, undefined)
 Result of ${:U} is "" (eval-keep-dollar-and-undefined, defined)
 Indirect modifier "" from "${:U}"
 Var_Parse: ${:U}} after (eval-keep-dollar-and-undefined)
-Applying ${:U} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${:U} on value "" (eval-keep-dollar-and-undefined, undefined)
 Result of ${:U} is "" (eval-keep-dollar-and-undefined, defined)
 Global:_ = before ${UNDEF:} after
 ParseReadLine (184): '_:=	before ${UNDEF:${:UZ}} after'
 Var_Parse: ${UNDEF:${:UZ}} after (eval-keep-dollar-and-undefined)
 Var_Parse: ${:UZ}} after (eval-keep-dollar-and-undefined)
-Applying ${:U...} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-keep-dollar-and-undefined, undefined)
 Result of ${:UZ} is "Z" (eval-keep-dollar-and-undefined, defined)
 Indirect modifier "Z" from "${:UZ}"
-Applying ${UNDEF:Z} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${UNDEF:Z} on value "" (eval-keep-dollar-and-undefined, undefined)
 make: "varmod-indirect.mk" line 184: Unknown modifier "Z"
 Result of ${UNDEF:Z} is error (eval-keep-dollar-and-undefined, undefined)
 Var_Parse: ${:UZ}} after (eval-keep-dollar-and-undefined)
-Applying ${:U...} to "" (eval-keep-dollar-and-undefined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-keep-dollar-and-undefined, undefined)
 Result of ${:UZ} is "Z" (eval-keep-dollar-and-undefined, defined)
 Global:_ = before ${UNDEF:Z} after
 ParseReadLine (186): '.MAKEFLAGS: -d0'

Index: src/usr.bin/make/unit-tests/varmod-match-escape.exp
diff -u src/usr.bin/make/unit-tests/varmod-match-escape.exp:1.10 src/usr.bin/make/unit-tests/varmod-match-escape.exp:1.11
--- src/usr.bin/make/unit-tests/varmod-match-escape.exp:1.10	Mon Apr  5 12:51:35 2021
+++ src/usr.bin/make/unit-tests/varmod-match-escape.exp	Mon Apr  5 13:14:55 2021
@@ -1,17 +1,17 @@
 Global:SPECIALS = \: : \\ * \*
 CondParser_Eval: ${SPECIALS:M${:U}\:} != ${SPECIALS:M\:${:U}}
 Var_Parse: ${SPECIALS:M${:U}\:} != ${SPECIALS:M\:${:U}} (eval-defined)
-Applying ${SPECIALS:M...} to "\: : \\ * \*" (eval-defined, regular)
+Evaluating modifier ${SPECIALS:M...} on value "\: : \\ * \*" (eval-defined, regular)
 Var_Parse: ${:U}\: (eval-defined)
-Applying ${:U} to "" (eval-defined, undefined)
+Evaluating modifier ${:U} on value "" (eval-defined, undefined)
 Result of ${:U} is "" (eval-defined, defined)
 Pattern for ':M' is "\:"
 ModifyWords: split "\: : \\ * \*" into 5 words
 Result of ${SPECIALS:M${:U}\:} is ":" (eval-defined, regular)
 Var_Parse: ${SPECIALS:M\:${:U}} (eval-defined)
-Applying ${SPECIALS:M...} to "\: : \\ * \*" (eval-defined, regular)
+Evaluating modifier ${SPECIALS:M...} on value "\: : \\ * \*" (eval-defined, regular)
 Var_Parse: ${:U} (eval-defined)
-Applying ${:U} to "" (eval-defined, undefined)
+Evaluating modifier ${:U} on value "" (eval-defined, undefined)
 Result of ${:U} is "" (eval-defined, defined)
 Pattern for ':M' is ":"
 ModifyWords: split "\: : \\ * \*" into 5 words
@@ -20,17 +20,17 @@ lhs = ":", rhs = ":", op = !=
 Global:VALUES = : :: :\:
 CondParser_Eval: ${VALUES:M\:${:U\:}} != ${VALUES:M${:U\:}\:}
 Var_Parse: ${VALUES:M\:${:U\:}} != ${VALUES:M${:U\:}\:} (eval-defined)
-Applying ${VALUES:M...} to ": :: :\:" (eval-defined, regular)
+Evaluating modifier ${VALUES:M...} on value ": :: :\:" (eval-defined, regular)
 Var_Parse: ${:U:} (eval-defined)
-Applying ${:U} to "" (eval-defined, undefined)
+Evaluating modifier ${:U} on value "" (eval-defined, undefined)
 Result of ${:U} is "" (eval-defined, defined)
 Pattern for ':M' is ":"
 ModifyWords: split ": :: :\:" into 3 words
 Result of ${VALUES:M\:${:U\:}} is ":" (eval-defined, regular)
 Var_Parse: ${VALUES:M${:U\:}\:} (eval-defined)
-Applying ${VALUES:M...} to ": :: :\:" (eval-defined, regular)
+Evaluating modifier ${VALUES:M...} on value ": :: :\:" (eval-defined, regular)
 Var_Parse: ${:U\:}\: (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:U\:} is ":" (eval-defined, defined)
 Pattern for ':M' is ":\:"
 ModifyWords: split ": :: :\:" into 3 words

Index: src/usr.bin/make/unit-tests/varname.exp
diff -u src/usr.bin/make/unit-tests/varname.exp:1.14 src/usr.bin/make/unit-tests/varname.exp:1.15
--- src/usr.bin/make/unit-tests/varname.exp:1.14	Sat Apr  3 22:02:59 2021
+++ src/usr.bin/make/unit-tests/varname.exp	Mon Apr  5 13:14:55 2021
@@ -5,13 +5,13 @@ Var_Parse: ${VARNAME} (eval)
 Global:VAR((( = 3 open parentheses
 Var_Parse: ${VAR(((}}}}" != "3 open parentheses}}}" (eval)
 Var_Parse: ${:UVAR(((}=	try1 (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:UVAR(((} is "VAR(((" (eval-defined, defined)
 Global:.ALLTARGETS =  VAR(((=)
 make: "varname.mk" line 30: No closing parenthesis in archive specification
 make: "varname.mk" line 30: Error in archive specification: "VAR"
 Var_Parse: ${:UVAR\(\(\(}=	try2 (eval-defined)
-Applying ${:U...} to "" (eval-defined, undefined)
+Evaluating modifier ${:U...} on value "" (eval-defined, undefined)
 Result of ${:UVAR\(\(\(} is "VAR\(\(\(" (eval-defined, defined)
 Global:.ALLTARGETS =  VAR(((=) VAR\(\(\(=
 make: "varname.mk" line 35: Invalid line type

Reply via email to