Mon Mar 15 15:39:13 2021 UTC ()
make: change debug log for variable evaluation flags to lowercase

This makes them easier distinguishable from variable names since the
latter are usually uppercase.

No functional change outside debug mode.


(rillig)
diff -r1.205 -r1.206 src/usr.bin/make/nonints.h
diff -r1.885 -r1.886 src/usr.bin/make/var.c
diff -r1.3 -r1.4 src/usr.bin/make/unit-tests/deptgt-makeflags.exp
diff -r1.4 -r1.5 src/usr.bin/make/unit-tests/directive-export-impl.exp
diff -r1.4 -r1.5 src/usr.bin/make/unit-tests/varmod-defined.exp
diff -r1.5 -r1.6 src/usr.bin/make/unit-tests/directive-unexport-env.exp
diff -r1.5 -r1.6 src/usr.bin/make/unit-tests/var-op-append.exp
diff -r1.7 -r1.8 src/usr.bin/make/unit-tests/var-eval-short.exp
diff -r1.7 -r1.8 src/usr.bin/make/unit-tests/varmod-match-escape.exp
diff -r1.17 -r1.18 src/usr.bin/make/unit-tests/vardebug.exp
diff -r1.12 -r1.13 src/usr.bin/make/unit-tests/varmod-indirect.exp
diff -r1.12 -r1.13 src/usr.bin/make/unit-tests/varname.exp
diff -r1.9 -r1.10 src/usr.bin/make/unit-tests/varname-dot-shell.exp
diff -r1.9 -r1.10 src/usr.bin/make/unit-tests/varname-empty.exp

cvs diff -r1.205 -r1.206 src/usr.bin/make/Attic/nonints.h (expand / switch to unified diff)

--- src/usr.bin/make/Attic/nonints.h 2021/03/15 12:15:03 1.205
+++ src/usr.bin/make/Attic/nonints.h 2021/03/15 15:39:13 1.206
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: nonints.h,v 1.205 2021/03/15 12:15:03 rillig Exp $ */ 1/* $NetBSD: nonints.h,v 1.206 2021/03/15 15:39:13 rillig Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 1988, 1989, 1990, 1993 4 * Copyright (c) 1988, 1989, 1990, 1993
5 * The Regents of the University of California. All rights reserved. 5 * The Regents of the University of California. All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to Berkeley by 7 * This code is derived from software contributed to Berkeley by
8 * Adam de Boor. 8 * Adam de Boor.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -331,27 +331,27 @@ typedef struct VarEvalFlags { @@ -331,27 +331,27 @@ typedef struct VarEvalFlags {
331 * CFLAGS := -I.. $(CFLAGS) 331 * CFLAGS := -I.. $(CFLAGS)
332 * # If .INCLUDES (an undocumented special variable, by the 332 * # If .INCLUDES (an undocumented special variable, by the
333 * # way) is still undefined, the updated CFLAGS becomes 333 * # way) is still undefined, the updated CFLAGS becomes
334 * # "-I.. $(.INCLUDES)". 334 * # "-I.. $(.INCLUDES)".
335 */ 335 */
336 Boolean keepUndef: 1; 336 Boolean keepUndef: 1;
337 337
338 /* 338 /*
339 * Without this padding, GCC 9.3.0 on NetBSD 9.99.80 generates larger 339 * Without this padding, GCC 9.3.0 on NetBSD 9.99.80 generates larger
340 * code than necessary (1.2 kB), masking out the unused bits from the 340 * code than necessary (1.2 kB), masking out the unused bits from the
341 * int (since that is the default representation of Boolean in make), 341 * int (since that is the default representation of Boolean in make),
342 * even for initializers consisting entirely of constants. 342 * even for initializers consisting entirely of constants.
343 */ 343 */
344 Boolean : 1; 344 Boolean : 0;
345} VarEvalFlags; 345} VarEvalFlags;
346 346
347#define VARE_PARSE_ONLY (VarEvalFlags) { FALSE, FALSE, FALSE, FALSE } 347#define VARE_PARSE_ONLY (VarEvalFlags) { FALSE, FALSE, FALSE, FALSE }
348#define VARE_WANTRES (VarEvalFlags) { TRUE, FALSE, FALSE, FALSE } 348#define VARE_WANTRES (VarEvalFlags) { TRUE, FALSE, FALSE, FALSE }
349#define VARE_UNDEFERR (VarEvalFlags) { TRUE, TRUE, FALSE, FALSE } 349#define VARE_UNDEFERR (VarEvalFlags) { TRUE, TRUE, FALSE, FALSE }
350#define VARE_KEEP_DOLLAR_UNDEF (VarEvalFlags) { TRUE, FALSE, TRUE, TRUE } 350#define VARE_KEEP_DOLLAR_UNDEF (VarEvalFlags) { TRUE, FALSE, TRUE, TRUE }
351 351
352typedef enum VarSetFlags { 352typedef enum VarSetFlags {
353 VAR_SET_NONE = 0, 353 VAR_SET_NONE = 0,
354 354
355 /* do not export */ 355 /* do not export */
356 VAR_SET_NO_EXPORT = 1 << 0, 356 VAR_SET_NO_EXPORT = 1 << 0,
357 357

cvs diff -r1.885 -r1.886 src/usr.bin/make/var.c (expand / switch to unified diff)

--- src/usr.bin/make/var.c 2021/03/15 12:15:03 1.885
+++ src/usr.bin/make/var.c 2021/03/15 15:39:13 1.886
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: var.c,v 1.885 2021/03/15 12:15:03 rillig Exp $ */ 1/* $NetBSD: var.c,v 1.886 2021/03/15 15:39:13 rillig Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 1988, 1989, 1990, 1993 4 * Copyright (c) 1988, 1989, 1990, 1993
5 * The Regents of the University of California. All rights reserved. 5 * The Regents of the University of California. All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to Berkeley by 7 * This code is derived from software contributed to Berkeley by
8 * Adam de Boor. 8 * Adam de Boor.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -130,27 +130,27 @@ @@ -130,27 +130,27 @@
130#include <regex.h> 130#include <regex.h>
131#endif 131#endif
132#include <errno.h> 132#include <errno.h>
133#include <inttypes.h> 133#include <inttypes.h>
134#include <limits.h> 134#include <limits.h>
135#include <time.h> 135#include <time.h>
136 136
137#include "make.h" 137#include "make.h"
138#include "dir.h" 138#include "dir.h"
139#include "job.h" 139#include "job.h"
140#include "metachar.h" 140#include "metachar.h"
141 141
142/* "@(#)var.c 8.3 (Berkeley) 3/19/94" */ 142/* "@(#)var.c 8.3 (Berkeley) 3/19/94" */
143MAKE_RCSID("$NetBSD: var.c,v 1.885 2021/03/15 12:15:03 rillig Exp $"); 143MAKE_RCSID("$NetBSD: var.c,v 1.886 2021/03/15 15:39:13 rillig Exp $");
144 144
145typedef enum VarFlags { 145typedef enum VarFlags {
146 VFL_NONE = 0, 146 VFL_NONE = 0,
147 147
148 /* 148 /*
149 * The variable's value is currently being used by Var_Parse or 149 * The variable's value is currently being used by Var_Parse or
150 * Var_Subst. This marker is used to avoid endless recursion. 150 * Var_Subst. This marker is used to avoid endless recursion.
151 */ 151 */
152 VFL_IN_USE = 1 << 0, 152 VFL_IN_USE = 1 << 0,
153 153
154 /* 154 /*
155 * The variable comes from the environment. 155 * The variable comes from the environment.
156 * These variables are not registered in any GNode, therefore they 156 * These variables are not registered in any GNode, therefore they
@@ -257,57 +257,45 @@ typedef struct VarPatternFlags { @@ -257,57 +257,45 @@ typedef struct VarPatternFlags {
257 Boolean anchorStart: 1; 257 Boolean anchorStart: 1;
258 /* Match at end of word ('$') */ 258 /* Match at end of word ('$') */
259 Boolean anchorEnd: 1; 259 Boolean anchorEnd: 1;
260} VarPatternFlags; 260} VarPatternFlags;
261 261
262/* SepBuf builds a string from words interleaved with separators. */ 262/* SepBuf builds a string from words interleaved with separators. */
263typedef struct SepBuf { 263typedef struct SepBuf {
264 Buffer buf; 264 Buffer buf;
265 Boolean needSep; 265 Boolean needSep;
266 /* Usually ' ', but see the ':ts' modifier. */ 266 /* Usually ' ', but see the ':ts' modifier. */
267 char sep; 267 char sep;
268} SepBuf; 268} SepBuf;
269 269
270enum { 
271 VarEvalFlags_ToStringSize = sizeof 
272 "VARE_UNDEFERR|VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF" 
273}; 
274 
275MAKE_INLINE char * 
276str_append(char *dst, const char *src) 
277{ 
278 size_t len = strlen(src); 
279 memcpy(dst, src, len); 
280 return dst + len; 
281} 
282 
283static const char * 270static const char *
284VarEvalFlags_ToString(char *buf, VarEvalFlags eflags) 271VarEvalFlags_ToString(VarEvalFlags eflags)
285{ 272{
286 char *p = buf; 273 if (!eflags.wantRes) {
287 274 assert(!eflags.undefErr);
288 /* TODO: WANTRES should be mentioned before UNDEFERR */ 275 assert(!eflags.keepDollar && !eflags.keepUndef);
289 if (eflags.undefErr) 276 return "parse-only";
290 p = str_append(p, "VARE_UNDEFERR|"); 277 }
291 if (eflags.wantRes) 278 if (eflags.undefErr) {
292 p = str_append(p, "VARE_WANTRES|"); 279 assert(!eflags.keepDollar && !eflags.keepUndef);
 280 return "eval-defined";
 281 }
 282 if (eflags.keepDollar && eflags.keepUndef)
 283 return "eval-keep-dollar-and-undefined";
293 if (eflags.keepDollar) 284 if (eflags.keepDollar)
294 p = str_append(p, "VARE_KEEP_DOLLAR|"); 285 return "eval-keep-dollar";
295 if (eflags.keepUndef) 286 if (eflags.keepUndef)
296 p = str_append(p, "VARE_KEEP_UNDEF|"); 287 return "eval-keep-undefined";
297 if (p == buf) 288 return "eval";
298 return "none"; 
299 p[-1] = '\0'; 
300 return buf; 
301} 289}
302 290
303/* 291/*
304 * This lets us tell if we have replaced the original environ 292 * This lets us tell if we have replaced the original environ
305 * (which we cannot free). 293 * (which we cannot free).
306 */ 294 */
307char **savedEnv = NULL; 295char **savedEnv = NULL;
308 296
309/* 297/*
310 * Special return value for Var_Parse, indicating a parse error. It may be 298 * Special return value for Var_Parse, indicating a parse error. It may be
311 * caused by an undefined variable, a syntax error in a modifier or 299 * caused by an undefined variable, a syntax error in a modifier or
312 * something entirely different. 300 * something entirely different.
313 */ 301 */
@@ -3608,53 +3596,51 @@ ApplyModifier_SunShell(const char **pp,  @@ -3608,53 +3596,51 @@ ApplyModifier_SunShell(const char **pp,
3608 if (errfmt != NULL) 3596 if (errfmt != NULL)
3609 Error(errfmt, expr->value.str); 3597 Error(errfmt, expr->value.str);
3610 Expr_SetValueOwn(expr, output); 3598 Expr_SetValueOwn(expr, output);
3611 } 3599 }
3612 3600
3613 return AMR_OK; 3601 return AMR_OK;
3614} 3602}
3615#endif 3603#endif
3616 3604
3617static void 3605static void
3618LogBeforeApply(const ApplyModifiersState *st, const char *mod) 3606LogBeforeApply(const ApplyModifiersState *st, const char *mod)
3619{ 3607{
3620 const Expr *expr = st->expr; 3608 const Expr *expr = st->expr;
3621 char eflags_str[VarEvalFlags_ToStringSize]; 
3622 char vflags_str[VarFlags_ToStringSize]; 3609 char vflags_str[VarFlags_ToStringSize];
3623 Boolean is_single_char = mod[0] != '\0' && IsDelimiter(mod[1], st); 3610 Boolean is_single_char = mod[0] != '\0' && IsDelimiter(mod[1], st);
3624 3611
3625 /* At this point, only the first character of the modifier can 3612 /* At this point, only the first character of the modifier can
3626 * be used since the end of the modifier is not yet known. */ 3613 * be used since the end of the modifier is not yet known. */
3627 debug_printf("Applying ${%s:%c%s} to \"%s\" (%s, %s, %s)\n", 3614 debug_printf("Applying ${%s:%c%s} to \"%s\" (%s, %s, %s)\n",
3628 expr->var->name.str, mod[0], is_single_char ? "" : "...", 3615 expr->var->name.str, mod[0], is_single_char ? "" : "...",
3629 expr->value.str, 3616 expr->value.str,
3630 VarEvalFlags_ToString(eflags_str, expr->eflags), 3617 VarEvalFlags_ToString(expr->eflags),
3631 VarFlags_ToString(vflags_str, expr->var->flags), 3618 VarFlags_ToString(vflags_str, expr->var->flags),
3632 ExprDefined_Name[expr->defined]); 3619 ExprDefined_Name[expr->defined]);
3633} 3620}
3634 3621
3635static void 3622static void
3636LogAfterApply(const ApplyModifiersState *st, const char *p, const char *mod) 3623LogAfterApply(const ApplyModifiersState *st, const char *p, const char *mod)
3637{ 3624{
3638 const Expr *expr = st->expr; 3625 const Expr *expr = st->expr;
3639 const char *value = expr->value.str; 3626 const char *value = expr->value.str;
3640 char eflags_str[VarEvalFlags_ToStringSize]; 
3641 char vflags_str[VarFlags_ToStringSize]; 3627 char vflags_str[VarFlags_ToStringSize];
3642 const char *quot = value == var_Error ? "" : "\""; 3628 const char *quot = value == var_Error ? "" : "\"";
3643 3629
3644 debug_printf("Result of ${%s:%.*s} is %s%s%s (%s, %s, %s)\n", 3630 debug_printf("Result of ${%s:%.*s} is %s%s%s (%s, %s, %s)\n",
3645 expr->var->name.str, (int)(p - mod), mod, 3631 expr->var->name.str, (int)(p - mod), mod,
3646 quot, value == var_Error ? "error" : value, quot, 3632 quot, value == var_Error ? "error" : value, quot,
3647 VarEvalFlags_ToString(eflags_str, expr->eflags), 3633 VarEvalFlags_ToString(expr->eflags),
3648 VarFlags_ToString(vflags_str, expr->var->flags), 3634 VarFlags_ToString(vflags_str, expr->var->flags),
3649 ExprDefined_Name[expr->defined]); 3635 ExprDefined_Name[expr->defined]);
3650} 3636}
3651 3637
3652static ApplyModifierResult 3638static ApplyModifierResult
3653ApplyModifier(const char **pp, ApplyModifiersState *st) 3639ApplyModifier(const char **pp, ApplyModifiersState *st)
3654{ 3640{
3655 switch (**pp) { 3641 switch (**pp) {
3656 case '!': 3642 case '!':
3657 return ApplyModifier_ShellCommand(pp, st); 3643 return ApplyModifier_ShellCommand(pp, st);
3658 case ':': 3644 case ':':
3659 return ApplyModifier_Assign(pp, st); 3645 return ApplyModifier_Assign(pp, st);
3660 case '?': 3646 case '?':
@@ -4328,44 +4314,43 @@ Var_Parse(const char **pp, GNode *scope, @@ -4328,44 +4314,43 @@ Var_Parse(const char **pp, GNode *scope,
4328 /* TRUE if have modifiers for the variable. */ 4314 /* TRUE if have modifiers for the variable. */
4329 Boolean haveModifier; 4315 Boolean haveModifier;
4330 /* Starting character if variable in parens or braces. */ 4316 /* Starting character if variable in parens or braces. */
4331 char startc; 4317 char startc;
4332 /* Ending character if variable in parens or braces. */ 4318 /* Ending character if variable in parens or braces. */
4333 char endc; 4319 char endc;
4334 /* 4320 /*
4335 * TRUE if the variable is local and we're expanding it in a 4321 * TRUE if the variable is local and we're expanding it in a
4336 * non-local scope. This is done to support dynamic sources. 4322 * non-local scope. This is done to support dynamic sources.
4337 * The result is just the expression, unaltered. 4323 * The result is just the expression, unaltered.
4338 */ 4324 */
4339 Boolean dynamic; 4325 Boolean dynamic;
4340 const char *extramodifiers; 4326 const char *extramodifiers;
4341 char eflags_str[VarEvalFlags_ToStringSize]; 
4342 Var *v; 4327 Var *v;
4343 4328
4344 Expr expr = { 4329 Expr expr = {
4345 NULL, 4330 NULL,
4346#if defined(lint) 4331#if defined(lint)
4347 /* NetBSD lint cannot fully parse C99 struct initializers. */ 4332 /* NetBSD lint cannot fully parse C99 struct initializers. */
4348 { NULL, NULL }, 4333 { NULL, NULL },
4349#else 4334#else
4350 FStr_InitRefer(NULL), 4335 FStr_InitRefer(NULL),
4351#endif 4336#endif
4352 eflags, 4337 eflags,
4353 scope, 4338 scope,
4354 DEF_REGULAR 4339 DEF_REGULAR
4355 }; 4340 };
4356 4341
4357 DEBUG2(VAR, "Var_Parse: %s with %s\n", start, 4342 DEBUG2(VAR, "Var_Parse: %s (%s)\n", start,
4358 VarEvalFlags_ToString(eflags_str, eflags)); 4343 VarEvalFlags_ToString(eflags));
4359 4344
4360 *out_val = FStr_InitRefer(NULL); 4345 *out_val = FStr_InitRefer(NULL);
4361 extramodifiers = NULL; /* extra modifiers to apply first */ 4346 extramodifiers = NULL; /* extra modifiers to apply first */
4362 dynamic = FALSE; 4347 dynamic = FALSE;
4363 4348
4364 /* 4349 /*
4365 * Appease GCC, which thinks that the variable might not be 4350 * Appease GCC, which thinks that the variable might not be
4366 * initialized. 4351 * initialized.
4367 */ 4352 */
4368 endc = '\0'; 4353 endc = '\0';
4369 4354
4370 startc = p[1]; 4355 startc = p[1];
4371 if (startc != '(' && startc != '{') { 4356 if (startc != '(' && startc != '{') {

cvs diff -r1.3 -r1.4 src/usr.bin/make/unit-tests/deptgt-makeflags.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/deptgt-makeflags.exp 2020/11/08 02:31:24 1.3
+++ src/usr.bin/make/unit-tests/deptgt-makeflags.exp 2021/03/15 15:39:13 1.4
@@ -1,10 +1,10 @@ @@ -1,10 +1,10 @@
1Global:delete DOLLAR (not found) 1Global:delete DOLLAR (not found)
2Command:DOLLAR = $$$$ 2Command:DOLLAR = $$$$
3Global:.MAKEOVERRIDES = VAR DOLLAR 3Global:.MAKEOVERRIDES = VAR DOLLAR
4CondParser_Eval: ${DOLLAR} != "\$\$" 4CondParser_Eval: ${DOLLAR} != "\$\$"
5Var_Parse: ${DOLLAR} != "\$\$" with VARE_UNDEFERR|VARE_WANTRES 5Var_Parse: ${DOLLAR} != "\$\$" (eval-defined)
6lhs = "$$", rhs = "$$", op = != 6lhs = "$$", rhs = "$$", op = !=
7Global:.MAKEFLAGS = -r -k -D VAR -D VAR -d cv -d 7Global:.MAKEFLAGS = -r -k -D VAR -D VAR -d cv -d
8Global:.MAKEFLAGS = -r -k -D VAR -D VAR -d cv -d 0 8Global:.MAKEFLAGS = -r -k -D VAR -D VAR -d cv -d 0
9make: Unterminated quoted string [make VAR=initial UNBALANCED='] 9make: Unterminated quoted string [make VAR=initial UNBALANCED=']
10exit status 0 10exit status 0

cvs diff -r1.4 -r1.5 src/usr.bin/make/unit-tests/directive-export-impl.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/directive-export-impl.exp 2021/02/16 16:28:41 1.4
+++ src/usr.bin/make/unit-tests/directive-export-impl.exp 2021/03/15 15:39:13 1.5
@@ -1,56 +1,56 @@ @@ -1,56 +1,56 @@
1ParseReadLine (21): 'UT_VAR= <${REF}>' 1ParseReadLine (21): 'UT_VAR= <${REF}>'
2Global:UT_VAR = <${REF}> 2Global:UT_VAR = <${REF}>
3ParseReadLine (28): '.export UT_VAR' 3ParseReadLine (28): '.export UT_VAR'
4Global:.MAKE.EXPORTED = UT_VAR 4Global:.MAKE.EXPORTED = UT_VAR
5ParseReadLine (32): ': ${UT_VAR:N*}' 5ParseReadLine (32): ': ${UT_VAR:N*}'
6Var_Parse: ${UT_VAR:N*} with VARE_UNDEFERR|VARE_WANTRES 6Var_Parse: ${UT_VAR:N*} (eval-defined)
7Var_Parse: ${REF}> with VARE_UNDEFERR|VARE_WANTRES 7Var_Parse: ${REF}> (eval-defined)
8Applying ${UT_VAR:N...} to "<>" (VARE_UNDEFERR|VARE_WANTRES, VFL_EXPORTED|VFL_REEXPORT, regular) 8Applying ${UT_VAR:N...} to "<>" (eval-defined, VFL_EXPORTED|VFL_REEXPORT, regular)
9Pattern[UT_VAR] for [<>] is [*] 9Pattern[UT_VAR] for [<>] is [*]
10ModifyWords: split "<>" into 1 words 10ModifyWords: split "<>" into 1 words
11Result of ${UT_VAR:N*} is "" (VARE_UNDEFERR|VARE_WANTRES, VFL_EXPORTED|VFL_REEXPORT, regular) 11Result of ${UT_VAR:N*} is "" (eval-defined, VFL_EXPORTED|VFL_REEXPORT, regular)
12ParseDoDependency(: ) 12ParseDoDependency(: )
13CondParser_Eval: ${:!echo "\$UT_VAR"!} != "<>" 13CondParser_Eval: ${:!echo "\$UT_VAR"!} != "<>"
14Var_Parse: ${:!echo "\$UT_VAR"!} != "<>" with VARE_UNDEFERR|VARE_WANTRES 14Var_Parse: ${:!echo "\$UT_VAR"!} != "<>" (eval-defined)
15Applying ${:!...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 15Applying ${:!...} to "" (eval-defined, none, undefined)
16Modifier part: "echo "$UT_VAR"" 16Modifier part: "echo "$UT_VAR""
17Var_Parse: ${.MAKE.EXPORTED:O:u} with VARE_WANTRES 17Var_Parse: ${.MAKE.EXPORTED:O:u} (eval)
18Applying ${.MAKE.EXPORTED:O} to "UT_VAR" (VARE_WANTRES, none, regular) 18Applying ${.MAKE.EXPORTED:O} to "UT_VAR" (eval, none, regular)
19Result of ${.MAKE.EXPORTED:O} is "UT_VAR" (VARE_WANTRES, none, regular) 19Result of ${.MAKE.EXPORTED:O} is "UT_VAR" (eval, none, regular)
20Applying ${.MAKE.EXPORTED:u} to "UT_VAR" (VARE_WANTRES, none, regular) 20Applying ${.MAKE.EXPORTED:u} to "UT_VAR" (eval, none, regular)
21Result of ${.MAKE.EXPORTED:u} is "UT_VAR" (VARE_WANTRES, none, regular) 21Result of ${.MAKE.EXPORTED:u} is "UT_VAR" (eval, none, regular)
22Var_Parse: ${UT_VAR} with VARE_WANTRES 22Var_Parse: ${UT_VAR} (eval)
23Var_Parse: ${REF}> with VARE_WANTRES 23Var_Parse: ${REF}> (eval)
24Result of ${:!echo "\$UT_VAR"!} is "<>" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 24Result of ${:!echo "\$UT_VAR"!} is "<>" (eval-defined, none, defined)
25lhs = "<>", rhs = "<>", op = != 25lhs = "<>", rhs = "<>", op = !=
26ParseReadLine (49): ': ${UT_VAR:N*}' 26ParseReadLine (49): ': ${UT_VAR:N*}'
27Var_Parse: ${UT_VAR:N*} with VARE_UNDEFERR|VARE_WANTRES 27Var_Parse: ${UT_VAR:N*} (eval-defined)
28Var_Parse: ${REF}> with VARE_UNDEFERR|VARE_WANTRES 28Var_Parse: ${REF}> (eval-defined)
29Applying ${UT_VAR:N...} to "<>" (VARE_UNDEFERR|VARE_WANTRES, VFL_EXPORTED|VFL_REEXPORT, regular) 29Applying ${UT_VAR:N...} to "<>" (eval-defined, VFL_EXPORTED|VFL_REEXPORT, regular)
30Pattern[UT_VAR] for [<>] is [*] 30Pattern[UT_VAR] for [<>] is [*]
31ModifyWords: split "<>" into 1 words 31ModifyWords: split "<>" into 1 words
32Result of ${UT_VAR:N*} is "" (VARE_UNDEFERR|VARE_WANTRES, VFL_EXPORTED|VFL_REEXPORT, regular) 32Result of ${UT_VAR:N*} is "" (eval-defined, VFL_EXPORTED|VFL_REEXPORT, regular)
33ParseDoDependency(: ) 33ParseDoDependency(: )
34ParseReadLine (53): 'REF= defined' 34ParseReadLine (53): 'REF= defined'
35Global:REF = defined 35Global:REF = defined
36CondParser_Eval: ${:!echo "\$UT_VAR"!} != "<defined>" 36CondParser_Eval: ${:!echo "\$UT_VAR"!} != "<defined>"
37Var_Parse: ${:!echo "\$UT_VAR"!} != "<defined>" with VARE_UNDEFERR|VARE_WANTRES 37Var_Parse: ${:!echo "\$UT_VAR"!} != "<defined>" (eval-defined)
38Applying ${:!...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 38Applying ${:!...} to "" (eval-defined, none, undefined)
39Modifier part: "echo "$UT_VAR"" 39Modifier part: "echo "$UT_VAR""
40Var_Parse: ${.MAKE.EXPORTED:O:u} with VARE_WANTRES 40Var_Parse: ${.MAKE.EXPORTED:O:u} (eval)
41Applying ${.MAKE.EXPORTED:O} to "UT_VAR" (VARE_WANTRES, none, regular) 41Applying ${.MAKE.EXPORTED:O} to "UT_VAR" (eval, none, regular)
42Result of ${.MAKE.EXPORTED:O} is "UT_VAR" (VARE_WANTRES, none, regular) 42Result of ${.MAKE.EXPORTED:O} is "UT_VAR" (eval, none, regular)
43Applying ${.MAKE.EXPORTED:u} to "UT_VAR" (VARE_WANTRES, none, regular) 43Applying ${.MAKE.EXPORTED:u} to "UT_VAR" (eval, none, regular)
44Result of ${.MAKE.EXPORTED:u} is "UT_VAR" (VARE_WANTRES, none, regular) 44Result of ${.MAKE.EXPORTED:u} is "UT_VAR" (eval, none, regular)
45Var_Parse: ${UT_VAR} with VARE_WANTRES 45Var_Parse: ${UT_VAR} (eval)
46Var_Parse: ${REF}> with VARE_WANTRES 46Var_Parse: ${REF}> (eval)
47Result of ${:!echo "\$UT_VAR"!} is "<defined>" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 47Result of ${:!echo "\$UT_VAR"!} is "<defined>" (eval-defined, none, defined)
48lhs = "<defined>", rhs = "<defined>", op = != 48lhs = "<defined>", rhs = "<defined>", op = !=
49ParseReadLine (61): 'all:' 49ParseReadLine (61): 'all:'
50ParseDoDependency(all:) 50ParseDoDependency(all:)
51Global:.ALLTARGETS = all 51Global:.ALLTARGETS = all
52ParseReadLine (62): '.MAKEFLAGS: -d0' 52ParseReadLine (62): '.MAKEFLAGS: -d0'
53ParseDoDependency(.MAKEFLAGS: -d0) 53ParseDoDependency(.MAKEFLAGS: -d0)
54Global:.MAKEFLAGS = -r -k -d cpv -d 54Global:.MAKEFLAGS = -r -k -d cpv -d
55Global:.MAKEFLAGS = -r -k -d cpv -d 0 55Global:.MAKEFLAGS = -r -k -d cpv -d 0
56exit status 0 56exit status 0

cvs diff -r1.4 -r1.5 src/usr.bin/make/unit-tests/varmod-defined.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/varmod-defined.exp 2021/02/15 18:23:32 1.4
+++ src/usr.bin/make/unit-tests/varmod-defined.exp 2021/03/15 15:39:13 1.5
@@ -1,23 +1,23 @@ @@ -1,23 +1,23 @@
1Global:8_DOLLARS = $$$$$$$$ 1Global:8_DOLLARS = $$$$$$$$
2Global:VAR =  2Global:VAR =
3Var_Parse: ${8_DOLLARS} with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 3Var_Parse: ${8_DOLLARS} (eval-keep-dollar-and-undefined)
4Global:VAR = $$$$$$$$ 4Global:VAR = $$$$$$$$
5Var_Parse: ${VAR:D${8_DOLLARS}} with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 5Var_Parse: ${VAR:D${8_DOLLARS}} (eval-keep-dollar-and-undefined)
6Applying ${VAR:D...} to "$$$$$$$$" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, regular) 6Applying ${VAR:D...} to "$$$$$$$$" (eval-keep-dollar-and-undefined, none, regular)
7Var_Parse: ${8_DOLLARS}} with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 7Var_Parse: ${8_DOLLARS}} (eval-keep-dollar-and-undefined)
8Result of ${VAR:D${8_DOLLARS}} is "$$$$$$$$" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, regular) 8Result of ${VAR:D${8_DOLLARS}} is "$$$$$$$$" (eval-keep-dollar-and-undefined, none, regular)
9Global:VAR = $$$$$$$$ 9Global:VAR = $$$$$$$$
10Var_Parse: ${VAR:@var@${8_DOLLARS}@} with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 10Var_Parse: ${VAR:@var@${8_DOLLARS}@} (eval-keep-dollar-and-undefined)
11Applying ${VAR:@...} to "$$$$$$$$" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, regular) 11Applying ${VAR:@...} to "$$$$$$$$" (eval-keep-dollar-and-undefined, none, regular)
12Modifier part: "var" 12Modifier part: "var"
13Modifier part: "${8_DOLLARS}" 13Modifier part: "${8_DOLLARS}"
14ModifyWords: split "$$$$$$$$" into 1 words 14ModifyWords: split "$$$$$$$$" into 1 words
15Global:var = $$$$$$$$ 15Global:var = $$$$$$$$
16Var_Parse: ${8_DOLLARS} with VARE_WANTRES|VARE_KEEP_UNDEF 16Var_Parse: ${8_DOLLARS} (eval-keep-undefined)
17ModifyWord_Loop: in "$$$$$$$$", replace "var" with "${8_DOLLARS}" to "$$$$" 17ModifyWord_Loop: in "$$$$$$$$", replace "var" with "${8_DOLLARS}" to "$$$$"
18Global:delete var 18Global:delete var
19Result of ${VAR:@var@${8_DOLLARS}@} is "$$$$" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, regular) 19Result of ${VAR:@var@${8_DOLLARS}@} is "$$$$" (eval-keep-dollar-and-undefined, none, regular)
20Global:VAR = $$$$ 20Global:VAR = $$$$
21Global:.MAKEFLAGS = -r -k -d v -d 21Global:.MAKEFLAGS = -r -k -d v -d
22Global:.MAKEFLAGS = -r -k -d v -d 0 22Global:.MAKEFLAGS = -r -k -d v -d 0
23exit status 0 23exit status 0

cvs diff -r1.5 -r1.6 src/usr.bin/make/unit-tests/directive-unexport-env.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/directive-unexport-env.exp 2021/02/15 18:23:32 1.5
+++ src/usr.bin/make/unit-tests/directive-unexport-env.exp 2021/03/15 15:39:13 1.6
@@ -1,18 +1,18 @@ @@ -1,18 +1,18 @@
1make: "directive-unexport-env.mk" line 13: Unknown directive "unexport-en" 1make: "directive-unexport-env.mk" line 13: Unknown directive "unexport-en"
2make: "directive-unexport-env.mk" line 15: Unknown directive "unexport-environment" 2make: "directive-unexport-env.mk" line 15: Unknown directive "unexport-environment"
3Global:UT_EXPORTED = value 3Global:UT_EXPORTED = value
4Global:UT_UNEXPORTED = value 4Global:UT_UNEXPORTED = value
5Global:.MAKE.EXPORTED = UT_EXPORTED 5Global:.MAKE.EXPORTED = UT_EXPORTED
6make: "directive-unexport-env.mk" line 21: The directive .unexport-env does not take arguments 6make: "directive-unexport-env.mk" line 21: The directive .unexport-env does not take arguments
7Var_Parse: ${.MAKE.EXPORTED:O:u} with VARE_WANTRES 7Var_Parse: ${.MAKE.EXPORTED:O:u} (eval)
8Applying ${.MAKE.EXPORTED:O} to "UT_EXPORTED" (VARE_WANTRES, none, regular) 8Applying ${.MAKE.EXPORTED:O} to "UT_EXPORTED" (eval, none, regular)
9Result of ${.MAKE.EXPORTED:O} is "UT_EXPORTED" (VARE_WANTRES, none, regular) 9Result of ${.MAKE.EXPORTED:O} is "UT_EXPORTED" (eval, none, regular)
10Applying ${.MAKE.EXPORTED:u} to "UT_EXPORTED" (VARE_WANTRES, none, regular) 10Applying ${.MAKE.EXPORTED:u} to "UT_EXPORTED" (eval, none, regular)
11Result of ${.MAKE.EXPORTED:u} is "UT_EXPORTED" (VARE_WANTRES, none, regular) 11Result of ${.MAKE.EXPORTED:u} is "UT_EXPORTED" (eval, none, regular)
12Unexporting "UT_EXPORTED" 12Unexporting "UT_EXPORTED"
13Global:delete .MAKE.EXPORTED 13Global:delete .MAKE.EXPORTED
14Global:.MAKEFLAGS = -r -k -d v -d 14Global:.MAKEFLAGS = -r -k -d v -d
15Global:.MAKEFLAGS = -r -k -d v -d 0 15Global:.MAKEFLAGS = -r -k -d v -d 0
16make: Fatal errors encountered -- cannot continue 16make: Fatal errors encountered -- cannot continue
17make: stopped in unit-tests 17make: stopped in unit-tests
18exit status 1 18exit status 1

cvs diff -r1.5 -r1.6 src/usr.bin/make/unit-tests/var-op-append.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/var-op-append.exp 2021/02/15 18:23:32 1.5
+++ src/usr.bin/make/unit-tests/var-op-append.exp 2021/03/15 15:39:13 1.6
@@ -1,7 +1,7 @@ @@ -1,7 +1,7 @@
1Var_Parse: ${:U\$\$\$\$\$\$\$\$} with VARE_WANTRES 1Var_Parse: ${:U\$\$\$\$\$\$\$\$} (eval)
2Applying ${:U...} to "" (VARE_WANTRES, none, undefined) 2Applying ${:U...} to "" (eval, none, undefined)
3Result of ${:U\$\$\$\$\$\$\$\$} is "$$$$$$$$" (VARE_WANTRES, none, defined) 3Result of ${:U\$\$\$\$\$\$\$\$} is "$$$$$$$$" (eval, none, defined)
4Global:VAR.$$$$$$$$ = dollars 4Global:VAR.$$$$$$$$ = dollars
5Global:.MAKEFLAGS = -r -k -d v -d 5Global:.MAKEFLAGS = -r -k -d v -d
6Global:.MAKEFLAGS = -r -k -d v -d 0 6Global:.MAKEFLAGS = -r -k -d v -d 0
7exit status 0 7exit status 0

cvs diff -r1.7 -r1.8 src/usr.bin/make/unit-tests/var-eval-short.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/var-eval-short.exp 2021/03/14 20:41:39 1.7
+++ src/usr.bin/make/unit-tests/var-eval-short.exp 2021/03/15 15:39:13 1.8
@@ -1,27 +1,27 @@ @@ -1,27 +1,27 @@
1make: "var-eval-short.mk" line 77: Invalid time value: ${FAIL}} 1make: "var-eval-short.mk" line 77: Invalid time value: ${FAIL}}
2make: "var-eval-short.mk" line 77: Malformed conditional (0 && ${:Uword:gmtime=${FAIL}}) 2make: "var-eval-short.mk" line 77: Malformed conditional (0 && ${:Uword:gmtime=${FAIL}})
3make: "var-eval-short.mk" line 91: Invalid time value: ${FAIL}} 3make: "var-eval-short.mk" line 91: Invalid time value: ${FAIL}}
4make: "var-eval-short.mk" line 91: Malformed conditional (0 && ${:Uword:localtime=${FAIL}}) 4make: "var-eval-short.mk" line 91: Malformed conditional (0 && ${:Uword:localtime=${FAIL}})
5CondParser_Eval: 0 && ${0:?${FAIL}then:${FAIL}else} 5CondParser_Eval: 0 && ${0:?${FAIL}then:${FAIL}else}
6Var_Parse: ${0:?${FAIL}then:${FAIL}else} with none 6Var_Parse: ${0:?${FAIL}then:${FAIL}else} (parse-only)
7Applying ${0:?...} to "" (none, none, undefined) 7Applying ${0:?...} to "" (parse-only, none, undefined)
8Modifier part: "${FAIL}then" 8Modifier part: "${FAIL}then"
9Modifier part: "${FAIL}else" 9Modifier part: "${FAIL}else"
10Result of ${0:?${FAIL}then:${FAIL}else} is "" (none, none, defined) 10Result of ${0:?${FAIL}then:${FAIL}else} is "" (parse-only, none, defined)
11ParseReadLine (156): 'DEFINED= defined' 11ParseReadLine (156): 'DEFINED= defined'
12Global:DEFINED = defined 12Global:DEFINED = defined
13CondParser_Eval: 0 && ${DEFINED:L:?${FAIL}then:${FAIL}else} 13CondParser_Eval: 0 && ${DEFINED:L:?${FAIL}then:${FAIL}else}
14Var_Parse: ${DEFINED:L:?${FAIL}then:${FAIL}else} with none 14Var_Parse: ${DEFINED:L:?${FAIL}then:${FAIL}else} (parse-only)
15Applying ${DEFINED:L} to "defined" (none, none, regular) 15Applying ${DEFINED:L} to "defined" (parse-only, none, regular)
16Result of ${DEFINED:L} is "defined" (none, none, regular) 16Result of ${DEFINED:L} is "defined" (parse-only, none, regular)
17Applying ${DEFINED:?...} to "defined" (none, none, regular) 17Applying ${DEFINED:?...} to "defined" (parse-only, none, regular)
18Modifier part: "${FAIL}then" 18Modifier part: "${FAIL}then"
19Modifier part: "${FAIL}else" 19Modifier part: "${FAIL}else"
20Result of ${DEFINED:?${FAIL}then:${FAIL}else} is "defined" (none, none, regular) 20Result of ${DEFINED:?${FAIL}then:${FAIL}else} is "defined" (parse-only, none, regular)
21ParseReadLine (159): '.MAKEFLAGS: -d0' 21ParseReadLine (159): '.MAKEFLAGS: -d0'
22ParseDoDependency(.MAKEFLAGS: -d0) 22ParseDoDependency(.MAKEFLAGS: -d0)
23Global:.MAKEFLAGS = -r -k -d cpv -d 23Global:.MAKEFLAGS = -r -k -d cpv -d
24Global:.MAKEFLAGS = -r -k -d cpv -d 0 24Global:.MAKEFLAGS = -r -k -d cpv -d 0
25make: Fatal errors encountered -- cannot continue 25make: Fatal errors encountered -- cannot continue
26make: stopped in unit-tests 26make: stopped in unit-tests
27exit status 1 27exit status 1

cvs diff -r1.7 -r1.8 src/usr.bin/make/unit-tests/varmod-match-escape.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/varmod-match-escape.exp 2021/02/15 18:23:32 1.7
+++ src/usr.bin/make/unit-tests/varmod-match-escape.exp 2021/03/15 15:39:13 1.8
@@ -1,61 +1,61 @@ @@ -1,61 +1,61 @@
1Global:SPECIALS = \: : \\ * \* 1Global:SPECIALS = \: : \\ * \*
2CondParser_Eval: ${SPECIALS:M${:U}\:} != ${SPECIALS:M\:${:U}} 2CondParser_Eval: ${SPECIALS:M${:U}\:} != ${SPECIALS:M\:${:U}}
3Var_Parse: ${SPECIALS:M${:U}\:} != ${SPECIALS:M\:${:U}} with VARE_UNDEFERR|VARE_WANTRES 3Var_Parse: ${SPECIALS:M${:U}\:} != ${SPECIALS:M\:${:U}} (eval-defined)
4Applying ${SPECIALS:M...} to "\: : \\ * \*" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 4Applying ${SPECIALS:M...} to "\: : \\ * \*" (eval-defined, none, regular)
5Var_Parse: ${:U}\: with VARE_UNDEFERR|VARE_WANTRES 5Var_Parse: ${:U}\: (eval-defined)
6Applying ${:U} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 6Applying ${:U} to "" (eval-defined, none, undefined)
7Result of ${:U} is "" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 7Result of ${:U} is "" (eval-defined, none, defined)
8Pattern[SPECIALS] for [\: : \\ * \*] is [\:] 8Pattern[SPECIALS] for [\: : \\ * \*] is [\:]
9ModifyWords: split "\: : \\ * \*" into 5 words 9ModifyWords: split "\: : \\ * \*" into 5 words
10VarMatch [\:] [\:] 10VarMatch [\:] [\:]
11VarMatch [:] [\:] 11VarMatch [:] [\:]
12VarMatch [\\] [\:] 12VarMatch [\\] [\:]
13VarMatch [*] [\:] 13VarMatch [*] [\:]
14VarMatch [\*] [\:] 14VarMatch [\*] [\:]
15Result of ${SPECIALS:M${:U}\:} is ":" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 15Result of ${SPECIALS:M${:U}\:} is ":" (eval-defined, none, regular)
16Var_Parse: ${SPECIALS:M\:${:U}} with VARE_UNDEFERR|VARE_WANTRES 16Var_Parse: ${SPECIALS:M\:${:U}} (eval-defined)
17Applying ${SPECIALS:M...} to "\: : \\ * \*" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 17Applying ${SPECIALS:M...} to "\: : \\ * \*" (eval-defined, none, regular)
18Var_Parse: ${:U} with VARE_UNDEFERR|VARE_WANTRES 18Var_Parse: ${:U} (eval-defined)
19Applying ${:U} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 19Applying ${:U} to "" (eval-defined, none, undefined)
20Result of ${:U} is "" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 20Result of ${:U} is "" (eval-defined, none, defined)
21Pattern[SPECIALS] for [\: : \\ * \*] is [:] 21Pattern[SPECIALS] for [\: : \\ * \*] is [:]
22ModifyWords: split "\: : \\ * \*" into 5 words 22ModifyWords: split "\: : \\ * \*" into 5 words
23VarMatch [\:] [:] 23VarMatch [\:] [:]
24VarMatch [:] [:] 24VarMatch [:] [:]
25VarMatch [\\] [:] 25VarMatch [\\] [:]
26VarMatch [*] [:] 26VarMatch [*] [:]
27VarMatch [\*] [:] 27VarMatch [\*] [:]
28Result of ${SPECIALS:M\:${:U}} is ":" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 28Result of ${SPECIALS:M\:${:U}} is ":" (eval-defined, none, regular)
29lhs = ":", rhs = ":", op = != 29lhs = ":", rhs = ":", op = !=
30Global:VALUES = : :: :\: 30Global:VALUES = : :: :\:
31CondParser_Eval: ${VALUES:M\:${:U\:}} != ${VALUES:M${:U\:}\:} 31CondParser_Eval: ${VALUES:M\:${:U\:}} != ${VALUES:M${:U\:}\:}
32Var_Parse: ${VALUES:M\:${:U\:}} != ${VALUES:M${:U\:}\:} with VARE_UNDEFERR|VARE_WANTRES 32Var_Parse: ${VALUES:M\:${:U\:}} != ${VALUES:M${:U\:}\:} (eval-defined)
33Applying ${VALUES:M...} to ": :: :\:" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 33Applying ${VALUES:M...} to ": :: :\:" (eval-defined, none, regular)
34Var_Parse: ${:U:} with VARE_UNDEFERR|VARE_WANTRES 34Var_Parse: ${:U:} (eval-defined)
35Applying ${:U} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 35Applying ${:U} to "" (eval-defined, none, undefined)
36Result of ${:U} is "" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 36Result of ${:U} is "" (eval-defined, none, defined)
37Pattern[VALUES] for [: :: :\:] is [:] 37Pattern[VALUES] for [: :: :\:] is [:]
38ModifyWords: split ": :: :\:" into 3 words 38ModifyWords: split ": :: :\:" into 3 words
39VarMatch [:] [:] 39VarMatch [:] [:]
40VarMatch [::] [:] 40VarMatch [::] [:]
41VarMatch [:\:] [:] 41VarMatch [:\:] [:]
42Result of ${VALUES:M\:${:U\:}} is ":" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 42Result of ${VALUES:M\:${:U\:}} is ":" (eval-defined, none, regular)
43Var_Parse: ${VALUES:M${:U\:}\:} with VARE_UNDEFERR|VARE_WANTRES 43Var_Parse: ${VALUES:M${:U\:}\:} (eval-defined)
44Applying ${VALUES:M...} to ": :: :\:" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 44Applying ${VALUES:M...} to ": :: :\:" (eval-defined, none, regular)
45Var_Parse: ${:U\:}\: with VARE_UNDEFERR|VARE_WANTRES 45Var_Parse: ${:U\:}\: (eval-defined)
46Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 46Applying ${:U...} to "" (eval-defined, none, undefined)
47Result of ${:U\:} is ":" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 47Result of ${:U\:} is ":" (eval-defined, none, defined)
48Pattern[VALUES] for [: :: :\:] is [:\:] 48Pattern[VALUES] for [: :: :\:] is [:\:]
49ModifyWords: split ": :: :\:" into 3 words 49ModifyWords: split ": :: :\:" into 3 words
50VarMatch [:] [:\:] 50VarMatch [:] [:\:]
51VarMatch [::] [:\:] 51VarMatch [::] [:\:]
52VarMatch [:\:] [:\:] 52VarMatch [:\:] [:\:]
53Result of ${VALUES:M${:U\:}\:} is "::" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 53Result of ${VALUES:M${:U\:}\:} is "::" (eval-defined, none, regular)
54lhs = ":", rhs = "::", op = != 54lhs = ":", rhs = "::", op = !=
55make: "varmod-match-escape.mk" line 42: warning: XXX: Oops 55make: "varmod-match-escape.mk" line 42: warning: XXX: Oops
56Global:.MAKEFLAGS = -r -k -d cv -d 56Global:.MAKEFLAGS = -r -k -d cv -d
57Global:.MAKEFLAGS = -r -k -d cv -d 0 57Global:.MAKEFLAGS = -r -k -d cv -d 0
58make: "varmod-match-escape.mk" line 67: Dollar followed by nothing 58make: "varmod-match-escape.mk" line 67: Dollar followed by nothing
59make: Fatal errors encountered -- cannot continue 59make: Fatal errors encountered -- cannot continue
60make: stopped in unit-tests 60make: stopped in unit-tests
61exit status 1 61exit status 1

cvs diff -r1.17 -r1.18 src/usr.bin/make/unit-tests/vardebug.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/vardebug.exp 2021/02/23 15:19:41 1.17
+++ src/usr.bin/make/unit-tests/vardebug.exp 2021/03/15 15:39:13 1.18
@@ -1,86 +1,86 @@ @@ -1,86 +1,86 @@
1Global:delete FROM_CMDLINE (not found) 1Global:delete FROM_CMDLINE (not found)
2Command:FROM_CMDLINE =  2Command:FROM_CMDLINE =
3Global:.MAKEOVERRIDES = FROM_CMDLINE 3Global:.MAKEOVERRIDES = FROM_CMDLINE
4Global:VAR = added 4Global:VAR = added
5Global:VAR = overwritten 5Global:VAR = overwritten
6Global:delete VAR 6Global:delete VAR
7Global:delete VAR (not found) 7Global:delete VAR (not found)
8Var_Parse: ${:U} with VARE_WANTRES 8Var_Parse: ${:U} (eval)
9Applying ${:U} to "" (VARE_WANTRES, none, undefined) 9Applying ${:U} to "" (eval, none, undefined)
10Result of ${:U} is "" (VARE_WANTRES, none, defined) 10Result of ${:U} is "" (eval, none, defined)
11Var_Set("${:U}", "empty name", ...) name expands to empty string - ignored 11Var_Set("${:U}", "empty name", ...) name expands to empty string - ignored
12Var_Parse: ${:U} with VARE_WANTRES 12Var_Parse: ${:U} (eval)
13Applying ${:U} to "" (VARE_WANTRES, none, undefined) 13Applying ${:U} to "" (eval, none, undefined)
14Result of ${:U} is "" (VARE_WANTRES, none, defined) 14Result of ${:U} is "" (eval, none, defined)
15Var_Append("${:U}", "empty name", ...) name expands to empty string - ignored 15Var_Append("${:U}", "empty name", ...) name expands to empty string - ignored
16Global:FROM_CMDLINE = overwritten ignored! 16Global:FROM_CMDLINE = overwritten ignored!
17Global:VAR = 1 17Global:VAR = 1
18Global:VAR = 1 2 18Global:VAR = 1 2
19Global:VAR = 1 2 3 19Global:VAR = 1 2 3
20Var_Parse: ${VAR:M[2]} with VARE_UNDEFERR|VARE_WANTRES 20Var_Parse: ${VAR:M[2]} (eval-defined)
21Applying ${VAR:M...} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 21Applying ${VAR:M...} to "1 2 3" (eval-defined, none, regular)
22Pattern[VAR] for [1 2 3] is [[2]] 22Pattern[VAR] for [1 2 3] is [[2]]
23ModifyWords: split "1 2 3" into 3 words 23ModifyWords: split "1 2 3" into 3 words
24VarMatch [1] [[2]] 24VarMatch [1] [[2]]
25VarMatch [2] [[2]] 25VarMatch [2] [[2]]
26VarMatch [3] [[2]] 26VarMatch [3] [[2]]
27Result of ${VAR:M[2]} is "2" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 27Result of ${VAR:M[2]} is "2" (eval-defined, none, regular)
28Var_Parse: ${VAR:N[2]} with VARE_UNDEFERR|VARE_WANTRES 28Var_Parse: ${VAR:N[2]} (eval-defined)
29Applying ${VAR:N...} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 29Applying ${VAR:N...} to "1 2 3" (eval-defined, none, regular)
30Pattern[VAR] for [1 2 3] is [[2]] 30Pattern[VAR] for [1 2 3] is [[2]]
31ModifyWords: split "1 2 3" into 3 words 31ModifyWords: split "1 2 3" into 3 words
32Result of ${VAR:N[2]} is "1 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 32Result of ${VAR:N[2]} is "1 3" (eval-defined, none, regular)
33Var_Parse: ${VAR:S,2,two,} with VARE_UNDEFERR|VARE_WANTRES 33Var_Parse: ${VAR:S,2,two,} (eval-defined)
34Applying ${VAR:S...} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 34Applying ${VAR:S...} to "1 2 3" (eval-defined, none, regular)
35Modifier part: "2" 35Modifier part: "2"
36Modifier part: "two" 36Modifier part: "two"
37ModifyWords: split "1 2 3" into 3 words 37ModifyWords: split "1 2 3" into 3 words
38Result of ${VAR:S,2,two,} is "1 two 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 38Result of ${VAR:S,2,two,} is "1 two 3" (eval-defined, none, regular)
39Var_Parse: ${VAR:Q} with VARE_UNDEFERR|VARE_WANTRES 39Var_Parse: ${VAR:Q} (eval-defined)
40Applying ${VAR:Q} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 40Applying ${VAR:Q} to "1 2 3" (eval-defined, none, regular)
41Result of ${VAR:Q} is "1\ 2\ 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 41Result of ${VAR:Q} is "1\ 2\ 3" (eval-defined, none, regular)
42Var_Parse: ${VAR:tu:tl:Q} with VARE_UNDEFERR|VARE_WANTRES 42Var_Parse: ${VAR:tu:tl:Q} (eval-defined)
43Applying ${VAR:t...} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 43Applying ${VAR:t...} to "1 2 3" (eval-defined, none, regular)
44Result of ${VAR:tu} is "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 44Result of ${VAR:tu} is "1 2 3" (eval-defined, none, regular)
45Applying ${VAR:t...} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 45Applying ${VAR:t...} to "1 2 3" (eval-defined, none, regular)
46Result of ${VAR:tl} is "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 46Result of ${VAR:tl} is "1 2 3" (eval-defined, none, regular)
47Applying ${VAR:Q} to "1 2 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 47Applying ${VAR:Q} to "1 2 3" (eval-defined, none, regular)
48Result of ${VAR:Q} is "1\ 2\ 3" (VARE_UNDEFERR|VARE_WANTRES, none, regular) 48Result of ${VAR:Q} is "1\ 2\ 3" (eval-defined, none, regular)
49Var_Parse: ${:Uvalue:${:UM*e}:Mvalu[e]} with VARE_UNDEFERR|VARE_WANTRES 49Var_Parse: ${:Uvalue:${:UM*e}:Mvalu[e]} (eval-defined)
50Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 50Applying ${:U...} to "" (eval-defined, none, undefined)
51Result of ${:Uvalue} is "value" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 51Result of ${:Uvalue} is "value" (eval-defined, none, defined)
52Var_Parse: ${:UM*e}:Mvalu[e]} with VARE_UNDEFERR|VARE_WANTRES 52Var_Parse: ${:UM*e}:Mvalu[e]} (eval-defined)
53Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 53Applying ${:U...} to "" (eval-defined, none, undefined)
54Result of ${:UM*e} is "M*e" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 54Result of ${:UM*e} is "M*e" (eval-defined, none, defined)
55Indirect modifier "M*e" from "${:UM*e}" 55Indirect modifier "M*e" from "${:UM*e}"
56Applying ${:M...} to "value" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 56Applying ${:M...} to "value" (eval-defined, none, defined)
57Pattern[] for [value] is [*e] 57Pattern[] for [value] is [*e]
58ModifyWords: split "value" into 1 words 58ModifyWords: split "value" into 1 words
59VarMatch [value] [*e] 59VarMatch [value] [*e]
60Result of ${:M*e} is "value" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 60Result of ${:M*e} is "value" (eval-defined, none, defined)
61Applying ${:M...} to "value" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 61Applying ${:M...} to "value" (eval-defined, none, defined)
62Pattern[] for [value] is [valu[e]] 62Pattern[] for [value] is [valu[e]]
63ModifyWords: split "value" into 1 words 63ModifyWords: split "value" into 1 words
64VarMatch [value] [valu[e]] 64VarMatch [value] [valu[e]]
65Result of ${:Mvalu[e]} is "value" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 65Result of ${:Mvalu[e]} is "value" (eval-defined, none, defined)
66Var_Parse: ${:UVAR} with VARE_WANTRES 66Var_Parse: ${:UVAR} (eval)
67Applying ${:U...} to "" (VARE_WANTRES, none, undefined) 67Applying ${:U...} to "" (eval, none, undefined)
68Result of ${:UVAR} is "VAR" (VARE_WANTRES, none, defined) 68Result of ${:UVAR} is "VAR" (eval, none, defined)
69Global:delete VAR 69Global:delete VAR
70Var_Parse: ${:Uvariable:unknown} with VARE_UNDEFERR|VARE_WANTRES 70Var_Parse: ${:Uvariable:unknown} (eval-defined)
71Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 71Applying ${:U...} to "" (eval-defined, none, undefined)
72Result of ${:Uvariable} is "variable" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 72Result of ${:Uvariable} is "variable" (eval-defined, none, defined)
73Applying ${:u...} to "variable" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 73Applying ${:u...} to "variable" (eval-defined, none, defined)
74make: "vardebug.mk" line 44: Unknown modifier "unknown" 74make: "vardebug.mk" line 44: Unknown modifier "unknown"
75Result of ${:unknown} is error (VARE_UNDEFERR|VARE_WANTRES, none, defined) 75Result of ${:unknown} is error (eval-defined, none, defined)
76make: "vardebug.mk" line 44: Malformed conditional (${:Uvariable:unknown}) 76make: "vardebug.mk" line 44: Malformed conditional (${:Uvariable:unknown})
77Var_Parse: ${UNDEFINED} with VARE_UNDEFERR|VARE_WANTRES 77Var_Parse: ${UNDEFINED} (eval-defined)
78make: "vardebug.mk" line 53: Malformed conditional (${UNDEFINED}) 78make: "vardebug.mk" line 53: Malformed conditional (${UNDEFINED})
79Global:delete .SHELL (not found) 79Global:delete .SHELL (not found)
80Command:.SHELL = </path/to/shell> 80Command:.SHELL = </path/to/shell>
81Command:.SHELL = overwritten ignored (read-only) 81Command:.SHELL = overwritten ignored (read-only)
82Global:.MAKEFLAGS = -r -k -d v -d 82Global:.MAKEFLAGS = -r -k -d v -d
83Global:.MAKEFLAGS = -r -k -d v -d 0 83Global:.MAKEFLAGS = -r -k -d v -d 0
84make: Fatal errors encountered -- cannot continue 84make: Fatal errors encountered -- cannot continue
85make: stopped in unit-tests 85make: stopped in unit-tests
86exit status 1 86exit status 1

cvs diff -r1.12 -r1.13 src/usr.bin/make/unit-tests/varmod-indirect.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/varmod-indirect.exp 2021/02/23 15:19:41 1.12
+++ src/usr.bin/make/unit-tests/varmod-indirect.exp 2021/03/15 15:39:13 1.13
@@ -2,60 +2,60 @@ make: "varmod-indirect.mk" line 19: Unkn @@ -2,60 +2,60 @@ make: "varmod-indirect.mk" line 19: Unkn
2make: "varmod-indirect.mk" line 52: Unknown modifier "${" 2make: "varmod-indirect.mk" line 52: Unknown modifier "${"
3make: "varmod-indirect.mk" line 55: warning: FIXME: this expression should have resulted in a parse error rather than returning the unparsed portion of the expression. 3make: "varmod-indirect.mk" line 55: warning: FIXME: this expression should have resulted in a parse error rather than returning the unparsed portion of the expression.
4make: "varmod-indirect.mk" line 140: before 4make: "varmod-indirect.mk" line 140: before
5make: "varmod-indirect.mk" line 140: after 5make: "varmod-indirect.mk" line 140: after
6make: "varmod-indirect.mk" line 146: before 6make: "varmod-indirect.mk" line 146: before
7make: "varmod-indirect.mk" line 146: after 7make: "varmod-indirect.mk" line 146: after
8make: "varmod-indirect.mk" line 152: before 8make: "varmod-indirect.mk" line 152: before
9make: "varmod-indirect.mk" line 152: after 9make: "varmod-indirect.mk" line 152: after
10make: "varmod-indirect.mk" line 156: Unknown modifier "Z" 10make: "varmod-indirect.mk" line 156: Unknown modifier "Z"
11make: "varmod-indirect.mk" line 157: before 11make: "varmod-indirect.mk" line 157: before
12make: "varmod-indirect.mk" line 157: after 12make: "varmod-indirect.mk" line 157: after
13ParseReadLine (166): '_:= before ${UNDEF} after' 13ParseReadLine (166): '_:= before ${UNDEF} after'
14Global:_ =  14Global:_ =
15Var_Parse: ${UNDEF} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 15Var_Parse: ${UNDEF} after (eval-keep-dollar-and-undefined)
16Global:_ = before ${UNDEF} after 16Global:_ = before ${UNDEF} after
17ParseReadLine (169): '_:= before ${UNDEF:${:US,a,a,}} after' 17ParseReadLine (169): '_:= before ${UNDEF:${:US,a,a,}} after'
18Var_Parse: ${UNDEF:${:US,a,a,}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 18Var_Parse: ${UNDEF:${:US,a,a,}} after (eval-keep-dollar-and-undefined)
19Var_Parse: ${:US,a,a,}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 19Var_Parse: ${:US,a,a,}} after (eval-keep-dollar-and-undefined)
20Applying ${:U...} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 20Applying ${:U...} to "" (eval-keep-dollar-and-undefined, none, undefined)
21Result of ${:US,a,a,} is "S,a,a," (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, defined) 21Result of ${:US,a,a,} is "S,a,a," (eval-keep-dollar-and-undefined, none, defined)
22Indirect modifier "S,a,a," from "${:US,a,a,}" 22Indirect modifier "S,a,a," from "${:US,a,a,}"
23Applying ${UNDEF:S...} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 23Applying ${UNDEF:S...} to "" (eval-keep-dollar-and-undefined, none, undefined)
24Modifier part: "a" 24Modifier part: "a"
25Modifier part: "a" 25Modifier part: "a"
26ModifyWords: split "" into 1 words 26ModifyWords: split "" into 1 words
27Result of ${UNDEF:S,a,a,} is "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 27Result of ${UNDEF:S,a,a,} is "" (eval-keep-dollar-and-undefined, none, undefined)
28Var_Parse: ${:US,a,a,}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 28Var_Parse: ${:US,a,a,}} after (eval-keep-dollar-and-undefined)
29Applying ${:U...} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 29Applying ${:U...} to "" (eval-keep-dollar-and-undefined, none, undefined)
30Result of ${:US,a,a,} is "S,a,a," (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, defined) 30Result of ${:US,a,a,} is "S,a,a," (eval-keep-dollar-and-undefined, none, defined)
31Global:_ = before ${UNDEF:S,a,a,} after 31Global:_ = before ${UNDEF:S,a,a,} after
32ParseReadLine (179): '_:= before ${UNDEF:${:U}} after' 32ParseReadLine (179): '_:= before ${UNDEF:${:U}} after'
33Var_Parse: ${UNDEF:${:U}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 33Var_Parse: ${UNDEF:${:U}} after (eval-keep-dollar-and-undefined)
34Var_Parse: ${:U}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 34Var_Parse: ${:U}} after (eval-keep-dollar-and-undefined)
35Applying ${:U} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 35Applying ${:U} to "" (eval-keep-dollar-and-undefined, none, undefined)
36Result of ${:U} is "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, defined) 36Result of ${:U} is "" (eval-keep-dollar-and-undefined, none, defined)
37Indirect modifier "" from "${:U}" 37Indirect modifier "" from "${:U}"
38Var_Parse: ${:U}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 38Var_Parse: ${:U}} after (eval-keep-dollar-and-undefined)
39Applying ${:U} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 39Applying ${:U} to "" (eval-keep-dollar-and-undefined, none, undefined)
40Result of ${:U} is "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, defined) 40Result of ${:U} is "" (eval-keep-dollar-and-undefined, none, defined)
41Global:_ = before ${UNDEF:} after 41Global:_ = before ${UNDEF:} after
42ParseReadLine (184): '_:= before ${UNDEF:${:UZ}} after' 42ParseReadLine (184): '_:= before ${UNDEF:${:UZ}} after'
43Var_Parse: ${UNDEF:${:UZ}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 43Var_Parse: ${UNDEF:${:UZ}} after (eval-keep-dollar-and-undefined)
44Var_Parse: ${:UZ}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 44Var_Parse: ${:UZ}} after (eval-keep-dollar-and-undefined)
45Applying ${:U...} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 45Applying ${:U...} to "" (eval-keep-dollar-and-undefined, none, undefined)
46Result of ${:UZ} is "Z" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, defined) 46Result of ${:UZ} is "Z" (eval-keep-dollar-and-undefined, none, defined)
47Indirect modifier "Z" from "${:UZ}" 47Indirect modifier "Z" from "${:UZ}"
48Applying ${UNDEF:Z} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 48Applying ${UNDEF:Z} to "" (eval-keep-dollar-and-undefined, none, undefined)
49make: "varmod-indirect.mk" line 184: Unknown modifier "Z" 49make: "varmod-indirect.mk" line 184: Unknown modifier "Z"
50Result of ${UNDEF:Z} is error (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 50Result of ${UNDEF:Z} is error (eval-keep-dollar-and-undefined, none, undefined)
51Var_Parse: ${:UZ}} after with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 51Var_Parse: ${:UZ}} after (eval-keep-dollar-and-undefined)
52Applying ${:U...} to "" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, undefined) 52Applying ${:U...} to "" (eval-keep-dollar-and-undefined, none, undefined)
53Result of ${:UZ} is "Z" (VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF, none, defined) 53Result of ${:UZ} is "Z" (eval-keep-dollar-and-undefined, none, defined)
54Global:_ = before ${UNDEF:Z} after 54Global:_ = before ${UNDEF:Z} after
55ParseReadLine (186): '.MAKEFLAGS: -d0' 55ParseReadLine (186): '.MAKEFLAGS: -d0'
56ParseDoDependency(.MAKEFLAGS: -d0) 56ParseDoDependency(.MAKEFLAGS: -d0)
57Global:.MAKEFLAGS = -r -k -d 0 -d pv -d 57Global:.MAKEFLAGS = -r -k -d 0 -d pv -d
58Global:.MAKEFLAGS = -r -k -d 0 -d pv -d 0 58Global:.MAKEFLAGS = -r -k -d 0 -d pv -d 0
59make: Fatal errors encountered -- cannot continue 59make: Fatal errors encountered -- cannot continue
60make: stopped in unit-tests 60make: stopped in unit-tests
61exit status 1 61exit status 1

cvs diff -r1.12 -r1.13 src/usr.bin/make/unit-tests/varname.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/varname.exp 2021/02/15 18:23:32 1.12
+++ src/usr.bin/make/unit-tests/varname.exp 2021/03/15 15:39:13 1.13
@@ -1,24 +1,24 @@ @@ -1,24 +1,24 @@
1Global:VAR{{{}}} = 3 braces 1Global:VAR{{{}}} = 3 braces
2Var_Parse: ${VAR{{{}}}}" != "3 braces" with VARE_WANTRES 2Var_Parse: ${VAR{{{}}}}" != "3 braces" (eval)
3Global:VARNAME = VAR((( 3Global:VARNAME = VAR(((
4Var_Parse: ${VARNAME} with VARE_WANTRES 4Var_Parse: ${VARNAME} (eval)
5Global:VAR((( = 3 open parentheses 5Global:VAR((( = 3 open parentheses
6Var_Parse: ${VAR(((}}}}" != "3 open parentheses}}}" with VARE_WANTRES 6Var_Parse: ${VAR(((}}}}" != "3 open parentheses}}}" (eval)
7Var_Parse: ${:UVAR(((}= try1 with VARE_UNDEFERR|VARE_WANTRES 7Var_Parse: ${:UVAR(((}= try1 (eval-defined)
8Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 8Applying ${:U...} to "" (eval-defined, none, undefined)
9Result of ${:UVAR(((} is "VAR(((" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 9Result of ${:UVAR(((} is "VAR(((" (eval-defined, none, defined)
10Global:.ALLTARGETS = VAR(((=) 10Global:.ALLTARGETS = VAR(((=)
11make: "varname.mk" line 30: No closing parenthesis in archive specification 11make: "varname.mk" line 30: No closing parenthesis in archive specification
12make: "varname.mk" line 30: Error in archive specification: "VAR" 12make: "varname.mk" line 30: Error in archive specification: "VAR"
13Var_Parse: ${:UVAR\(\(\(}= try2 with VARE_UNDEFERR|VARE_WANTRES 13Var_Parse: ${:UVAR\(\(\(}= try2 (eval-defined)
14Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 14Applying ${:U...} to "" (eval-defined, none, undefined)
15Result of ${:UVAR\(\(\(} is "VAR\(\(\(" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 15Result of ${:UVAR\(\(\(} is "VAR\(\(\(" (eval-defined, none, defined)
16Global:.ALLTARGETS = VAR(((=) VAR\(\(\(= 16Global:.ALLTARGETS = VAR(((=) VAR\(\(\(=
17make: "varname.mk" line 35: Invalid line type 17make: "varname.mk" line 35: Invalid line type
18Var_Parse: ${VARNAME} with VARE_WANTRES 18Var_Parse: ${VARNAME} (eval)
19Global:VAR((( = try3 19Global:VAR((( = try3
20Global:.MAKEFLAGS = -r -k -d v -d 20Global:.MAKEFLAGS = -r -k -d v -d
21Global:.MAKEFLAGS = -r -k -d v -d 0 21Global:.MAKEFLAGS = -r -k -d v -d 0
22make: Fatal errors encountered -- cannot continue 22make: Fatal errors encountered -- cannot continue
23make: stopped in unit-tests 23make: stopped in unit-tests
24exit status 1 24exit status 1

cvs diff -r1.9 -r1.10 src/usr.bin/make/unit-tests/varname-dot-shell.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/varname-dot-shell.exp 2020/12/28 00:46:24 1.9
+++ src/usr.bin/make/unit-tests/varname-dot-shell.exp 2021/03/15 15:39:13 1.10
@@ -1,32 +1,32 @@ @@ -1,32 +1,32 @@
1ParseReadLine (10): 'ORIG_SHELL:= ${.SHELL}' 1ParseReadLine (10): 'ORIG_SHELL:= ${.SHELL}'
2Global:ORIG_SHELL =  2Global:ORIG_SHELL =
3Var_Parse: ${.SHELL} with VARE_WANTRES|VARE_KEEP_DOLLAR|VARE_KEEP_UNDEF 3Var_Parse: ${.SHELL} (eval-keep-dollar-and-undefined)
4Global:delete .SHELL (not found) 4Global:delete .SHELL (not found)
5Command:.SHELL = (details omitted) 5Command:.SHELL = (details omitted)
6Global:ORIG_SHELL = (details omitted) 6Global:ORIG_SHELL = (details omitted)
7ParseReadLine (12): '.SHELL= overwritten' 7ParseReadLine (12): '.SHELL= overwritten'
8Global:.SHELL = overwritten 8Global:.SHELL = overwritten
9CondParser_Eval: ${.SHELL} != ${ORIG_SHELL} 9CondParser_Eval: ${.SHELL} != ${ORIG_SHELL}
10Var_Parse: ${.SHELL} != ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES 10Var_Parse: ${.SHELL} != ${ORIG_SHELL} (eval-defined)
11Var_Parse: ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES 11Var_Parse: ${ORIG_SHELL} (eval-defined)
12lhs = "(details omitted)", rhs = "(details omitted)", op = != 12lhs = "(details omitted)", rhs = "(details omitted)", op = !=
13ParseReadLine (19): '.MAKEFLAGS: .SHELL+=appended' 13ParseReadLine (19): '.MAKEFLAGS: .SHELL+=appended'
14ParseDoDependency(.MAKEFLAGS: .SHELL+=appended) 14ParseDoDependency(.MAKEFLAGS: .SHELL+=appended)
15Ignoring append to .SHELL since it is read-only 15Ignoring append to .SHELL since it is read-only
16CondParser_Eval: ${.SHELL} != ${ORIG_SHELL} 16CondParser_Eval: ${.SHELL} != ${ORIG_SHELL}
17Var_Parse: ${.SHELL} != ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES 17Var_Parse: ${.SHELL} != ${ORIG_SHELL} (eval-defined)
18Var_Parse: ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES 18Var_Parse: ${ORIG_SHELL} (eval-defined)
19lhs = "(details omitted)", rhs = "(details omitted)", op = != 19lhs = "(details omitted)", rhs = "(details omitted)", op = !=
20ParseReadLine (27): '.undef .SHELL' 20ParseReadLine (27): '.undef .SHELL'
21Global:delete .SHELL 21Global:delete .SHELL
22ParseReadLine (28): '.SHELL= newly overwritten' 22ParseReadLine (28): '.SHELL= newly overwritten'
23Global:.SHELL = newly overwritten 23Global:.SHELL = newly overwritten
24CondParser_Eval: ${.SHELL} != ${ORIG_SHELL} 24CondParser_Eval: ${.SHELL} != ${ORIG_SHELL}
25Var_Parse: ${.SHELL} != ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES 25Var_Parse: ${.SHELL} != ${ORIG_SHELL} (eval-defined)
26Var_Parse: ${ORIG_SHELL} with VARE_UNDEFERR|VARE_WANTRES 26Var_Parse: ${ORIG_SHELL} (eval-defined)
27lhs = "(details omitted)", rhs = "(details omitted)", op = != 27lhs = "(details omitted)", rhs = "(details omitted)", op = !=
28ParseReadLine (33): '.MAKEFLAGS: -d0' 28ParseReadLine (33): '.MAKEFLAGS: -d0'
29ParseDoDependency(.MAKEFLAGS: -d0) 29ParseDoDependency(.MAKEFLAGS: -d0)
30Global:.MAKEFLAGS = -r -k -d cpv -d 30Global:.MAKEFLAGS = -r -k -d cpv -d
31Global:.MAKEFLAGS = -r -k -d cpv -d 0 31Global:.MAKEFLAGS = -r -k -d cpv -d 0
32exit status 0 32exit status 0

cvs diff -r1.9 -r1.10 src/usr.bin/make/unit-tests/varname-empty.exp (expand / switch to unified diff)

--- src/usr.bin/make/unit-tests/varname-empty.exp 2021/02/15 18:23:32 1.9
+++ src/usr.bin/make/unit-tests/varname-empty.exp 2021/03/15 15:39:13 1.10
@@ -1,47 +1,47 @@ @@ -1,47 +1,47 @@
1Var_Parse: ${:U} with VARE_WANTRES 1Var_Parse: ${:U} (eval)
2Applying ${:U} to "" (VARE_WANTRES, none, undefined) 2Applying ${:U} to "" (eval, none, undefined)
3Result of ${:U} is "" (VARE_WANTRES, none, defined) 3Result of ${:U} is "" (eval, none, defined)
4Var_Set("${:U}", "cmdline-u", ...) name expands to empty string - ignored 4Var_Set("${:U}", "cmdline-u", ...) name expands to empty string - ignored
5Var_Set("", "cmdline-plain", ...) name expands to empty string - ignored 5Var_Set("", "cmdline-plain", ...) name expands to empty string - ignored
6Global:.CURDIR = <curdir> 6Global:.CURDIR = <curdir>
7Var_Parse: ${MAKE_OBJDIR_CHECK_WRITABLE:U} with VARE_WANTRES 7Var_Parse: ${MAKE_OBJDIR_CHECK_WRITABLE:U} (eval)
8Applying ${MAKE_OBJDIR_CHECK_WRITABLE:U} to "" (VARE_WANTRES, none, undefined) 8Applying ${MAKE_OBJDIR_CHECK_WRITABLE:U} to "" (eval, none, undefined)
9Result of ${MAKE_OBJDIR_CHECK_WRITABLE:U} is "" (VARE_WANTRES, none, defined) 9Result of ${MAKE_OBJDIR_CHECK_WRITABLE:U} is "" (eval, none, defined)
10Global:.OBJDIR = <curdir> 10Global:.OBJDIR = <curdir>
11Global:delete .PATH (not found) 11Global:delete .PATH (not found)
12Global:.PATH = . 12Global:.PATH = .
13Global:.PATH = . <curdir> 13Global:.PATH = . <curdir>
14Global:.TARGETS =  14Global:.TARGETS =
15Internal:MAKEFILE = varname-empty.mk 15Internal:MAKEFILE = varname-empty.mk
16Global:.MAKE.MAKEFILES = varname-empty.mk 16Global:.MAKE.MAKEFILES = varname-empty.mk
17Global:.PARSEFILE = varname-empty.mk 17Global:.PARSEFILE = varname-empty.mk
18Global:delete .INCLUDEDFROMDIR (not found) 18Global:delete .INCLUDEDFROMDIR (not found)
19Global:delete .INCLUDEDFROMFILE (not found) 19Global:delete .INCLUDEDFROMFILE (not found)
20Var_Set("", "default", ...) name expands to empty string - ignored 20Var_Set("", "default", ...) name expands to empty string - ignored
21Var_Set("", "assigned", ...) name expands to empty string - ignored 21Var_Set("", "assigned", ...) name expands to empty string - ignored
22SetVar: variable name is empty - ignored 22SetVar: variable name is empty - ignored
23Var_Set("", "", ...) name expands to empty string - ignored 23Var_Set("", "", ...) name expands to empty string - ignored
24Var_Set("", "subst", ...) name expands to empty string - ignored 24Var_Set("", "subst", ...) name expands to empty string - ignored
25Var_Set("", "shell-output", ...) name expands to empty string - ignored 25Var_Set("", "shell-output", ...) name expands to empty string - ignored
26Var_Parse: ${:Ufallback} != "fallback" with VARE_UNDEFERR|VARE_WANTRES 26Var_Parse: ${:Ufallback} != "fallback" (eval-defined)
27Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 27Applying ${:U...} to "" (eval-defined, none, undefined)
28Result of ${:Ufallback} is "fallback" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 28Result of ${:Ufallback} is "fallback" (eval-defined, none, defined)
29Var_Parse: ${:U} with VARE_WANTRES 29Var_Parse: ${:U} (eval)
30Applying ${:U} to "" (VARE_WANTRES, none, undefined) 30Applying ${:U} to "" (eval, none, undefined)
31Result of ${:U} is "" (VARE_WANTRES, none, defined) 31Result of ${:U} is "" (eval, none, defined)
32Var_Set("${:U}", "assigned indirectly", ...) name expands to empty string - ignored 32Var_Set("${:U}", "assigned indirectly", ...) name expands to empty string - ignored
33Var_Parse: ${:Ufallback} != "fallback" with VARE_UNDEFERR|VARE_WANTRES 33Var_Parse: ${:Ufallback} != "fallback" (eval-defined)
34Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 34Applying ${:U...} to "" (eval-defined, none, undefined)
35Result of ${:Ufallback} is "fallback" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 35Result of ${:Ufallback} is "fallback" (eval-defined, none, defined)
36Var_Parse: ${:U} with VARE_WANTRES 36Var_Parse: ${:U} (eval)
37Applying ${:U} to "" (VARE_WANTRES, none, undefined) 37Applying ${:U} to "" (eval, none, undefined)
38Result of ${:U} is "" (VARE_WANTRES, none, defined) 38Result of ${:U} is "" (eval, none, defined)
39Var_Append("${:U}", "appended indirectly", ...) name expands to empty string - ignored 39Var_Append("${:U}", "appended indirectly", ...) name expands to empty string - ignored
40Var_Parse: ${:Ufallback} != "fallback" with VARE_UNDEFERR|VARE_WANTRES 40Var_Parse: ${:Ufallback} != "fallback" (eval-defined)
41Applying ${:U...} to "" (VARE_UNDEFERR|VARE_WANTRES, none, undefined) 41Applying ${:U...} to "" (eval-defined, none, undefined)
42Result of ${:Ufallback} is "fallback" (VARE_UNDEFERR|VARE_WANTRES, none, defined) 42Result of ${:Ufallback} is "fallback" (eval-defined, none, defined)
43Global:.MAKEFLAGS = -r -d v -d 43Global:.MAKEFLAGS = -r -d v -d
44Global:.MAKEFLAGS = -r -d v -d 0 44Global:.MAKEFLAGS = -r -d v -d 0
45out: fallback 45out: fallback
46out: 1 2 3 46out: 1 2 3
47exit status 0 47exit status 0