Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/make/unit-tests make(1): move test for .undef into s...



details:   https://anonhg.NetBSD.org/src/rev/d39aae7e52c3
branches:  trunk
changeset: 937703:d39aae7e52c3
user:      rillig <rillig%NetBSD.org@localhost>
date:      Sun Aug 23 19:30:13 2020 +0000

description:
make(1): move test for .undef into separate file

diffstat:

 usr.bin/make/unit-tests/directive-undef.mk |  13 +++++++++++--
 usr.bin/make/unit-tests/varmisc.mk         |  13 +------------
 2 files changed, 12 insertions(+), 14 deletions(-)

diffs (47 lines):

diff -r 068f8cf0c93d -r d39aae7e52c3 usr.bin/make/unit-tests/directive-undef.mk
--- a/usr.bin/make/unit-tests/directive-undef.mk        Sun Aug 23 19:00:19 2020 +0000
+++ b/usr.bin/make/unit-tests/directive-undef.mk        Sun Aug 23 19:30:13 2020 +0000
@@ -1,8 +1,17 @@
-# $NetBSD: directive-undef.mk,v 1.2 2020/08/16 14:25:16 rillig Exp $
+# $NetBSD: directive-undef.mk,v 1.3 2020/08/23 19:30:13 rillig Exp $
 #
 # Tests for the .undef directive.
 
-# TODO: Implementation
+# As of 2020-07-28, .undef only undefines the first variable.
+# All further variable names are silently ignored.
+# See parse.c, string literal "undef".
+1=             1
+2=             2
+3=             3
+.undef 1 2 3
+.if ${1:U_}${2:U_}${3:U_} != _23
+.warning $1$2$3
+.endif
 
 all:
        @:;
diff -r 068f8cf0c93d -r d39aae7e52c3 usr.bin/make/unit-tests/varmisc.mk
--- a/usr.bin/make/unit-tests/varmisc.mk        Sun Aug 23 19:00:19 2020 +0000
+++ b/usr.bin/make/unit-tests/varmisc.mk        Sun Aug 23 19:30:13 2020 +0000
@@ -1,4 +1,4 @@
-# $Id: varmisc.mk,v 1.21 2020/08/08 14:59:59 rillig Exp $
+# $Id: varmisc.mk,v 1.22 2020/08/23 19:30:13 rillig Exp $
 #
 # Miscellaneous variable tests.
 
@@ -211,14 +211,3 @@
 .endfor
        @echo ${UNCLOSED_INDIR_2}
        @echo $@:end
-
-# As of 2020-07-28, .undef only undefines the first variable.
-# All further variable names are silently ignored.
-# See parse.c, string literal "undef".
-1=             1
-2=             2
-3=             3
-.undef 1 2 3
-.if ${1:U_}${2:U_}${3:U_} != _23
-.warning $1$2$3
-.endif



Home | Main Index | Thread Index | Old Index