summaryrefslogtreecommitdiff
path: root/usr.bin/make
diff options
context:
space:
mode:
authorrillig <rillig@NetBSD.org>2022-01-07 19:30:17 +0000
committerrillig <rillig@NetBSD.org>2022-01-07 19:30:17 +0000
commit80ca742ffef39bca0ce0fe0d476bef5a6a346775 (patch)
tree760afd9513d21840839554d4558c0192e8fa9cea /usr.bin/make
parent6d311b848d80aa2b2c0707ad56aed78068f2122e (diff)
tests/make: fix documentation in cond-func.mk
Diffstat (limited to 'usr.bin/make')
-rw-r--r--usr.bin/make/unit-tests/cond-func.exp10
-rw-r--r--usr.bin/make/unit-tests/cond-func.mk9
2 files changed, 10 insertions, 9 deletions
diff --git a/usr.bin/make/unit-tests/cond-func.exp b/usr.bin/make/unit-tests/cond-func.exp
index 8dc0f821a25..d0663ea6864 100644
--- a/usr.bin/make/unit-tests/cond-func.exp
+++ b/usr.bin/make/unit-tests/cond-func.exp
@@ -2,11 +2,11 @@ make: "cond-func.mk" line 36: Missing closing parenthesis for defined()
make: "cond-func.mk" line 51: Missing closing parenthesis for defined()
make: "cond-func.mk" line 54: Missing closing parenthesis for defined()
make: "cond-func.mk" line 94: The empty variable is never defined.
-make: "cond-func.mk" line 102: A plain function name is parsed as !empty(...).
-make: "cond-func.mk" line 109: A plain function name is parsed as !empty(...).
-make: "cond-func.mk" line 119: Symbols may start with a function name.
-make: "cond-func.mk" line 124: Symbols may start with a function name.
-make: "cond-func.mk" line 130: Missing closing parenthesis for defined()
+make: "cond-func.mk" line 103: A plain function name is parsed as defined(...).
+make: "cond-func.mk" line 110: A plain function name is parsed as defined(...).
+make: "cond-func.mk" line 120: Symbols may start with a function name.
+make: "cond-func.mk" line 125: Symbols may start with a function name.
+make: "cond-func.mk" line 131: Missing closing parenthesis for defined()
make: Fatal errors encountered -- cannot continue
make: stopped in unit-tests
exit status 1
diff --git a/usr.bin/make/unit-tests/cond-func.mk b/usr.bin/make/unit-tests/cond-func.mk
index 7036fc294c4..959367f5c6a 100644
--- a/usr.bin/make/unit-tests/cond-func.mk
+++ b/usr.bin/make/unit-tests/cond-func.mk
@@ -1,4 +1,4 @@
-# $NetBSD: cond-func.mk,v 1.10 2021/12/28 22:13:56 rillig Exp $
+# $NetBSD: cond-func.mk,v 1.11 2022/01/07 19:30:17 rillig Exp $
#
# Tests for those parts of the functions in .if conditions that are common
# among several functions.
@@ -94,19 +94,20 @@ ${VARNAME_UNBALANCED_BRACES}= variable name with unbalanced braces
. info The empty variable is never defined.
.endif
-# The plain word 'defined' is interpreted as '!empty(defined)'.
+# The plain word 'defined' is interpreted as 'defined(defined)', see
+# CondParser_ComparisonOrLeaf.
# That variable is not defined (yet).
.if defined
. error
.else
-. info A plain function name is parsed as !empty(...).
+. info A plain function name is parsed as defined(...).
.endif
# If a variable named 'defined' is actually defined, the bare word 'defined'
# is interpreted as 'defined(defined)', and the condition evaluates to true.
defined= # defined but empty
.if defined
-. info A plain function name is parsed as !empty(...).
+. info A plain function name is parsed as defined(...).
.else
. error
.endif