Module Name:    src
Committed By:   rillig
Date:           Mon Dec 14 21:02:25 UTC 2020

Modified Files:
        src/usr.bin/make/unit-tests: directive-if.exp directive-if.mk

Log Message:
make(1): add tests for parsing .if conditions


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/usr.bin/make/unit-tests/directive-if.exp
cvs rdiff -u -r1.7 -r1.8 src/usr.bin/make/unit-tests/directive-if.mk

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/unit-tests/directive-if.exp
diff -u src/usr.bin/make/unit-tests/directive-if.exp:1.6 src/usr.bin/make/unit-tests/directive-if.exp:1.7
--- src/usr.bin/make/unit-tests/directive-if.exp:1.6	Sun Nov 15 20:20:58 2020
+++ src/usr.bin/make/unit-tests/directive-if.exp	Mon Dec 14 21:02:25 2020
@@ -10,6 +10,8 @@ make: "directive-if.mk" line 57: Quotes 
 make: "directive-if.mk" line 66: Don't do this, always put a space after a directive.
 make: "directive-if.mk" line 70: Don't do this, always put a space after a directive.
 make: "directive-if.mk" line 76: Don't do this, always put a space around comparison operators.
+make: "directive-if.mk" line 82: Don't do this, always put a space after a directive.
+make: "directive-if.mk" line 86: Don't do this, always put a space after a directive.
 make: Fatal errors encountered -- cannot continue
 make: stopped in unit-tests
 exit status 1

Index: src/usr.bin/make/unit-tests/directive-if.mk
diff -u src/usr.bin/make/unit-tests/directive-if.mk:1.7 src/usr.bin/make/unit-tests/directive-if.mk:1.8
--- src/usr.bin/make/unit-tests/directive-if.mk:1.7	Sun Nov 15 20:20:58 2020
+++ src/usr.bin/make/unit-tests/directive-if.mk	Mon Dec 14 21:02:25 2020
@@ -1,4 +1,4 @@
-# $NetBSD: directive-if.mk,v 1.7 2020/11/15 20:20:58 rillig Exp $
+# $NetBSD: directive-if.mk,v 1.8 2020/12/14 21:02:25 rillig Exp $
 #
 # Tests for the .if directive.
 #
@@ -78,4 +78,12 @@
 .  error
 .endif
 
+.if(1)
+.  info Don't do this, always put a space after a directive.
+.endif
+
+.if!0
+.  info Don't do this, always put a space after a directive.
+.endif
+
 all:

Reply via email to