summaryrefslogtreecommitdiff
path: root/unit-tests/directive-ifdef.mk
diff options
context:
space:
mode:
Diffstat (limited to 'unit-tests/directive-ifdef.mk')
-rw-r--r--unit-tests/directive-ifdef.mk12
1 files changed, 11 insertions, 1 deletions
diff --git a/unit-tests/directive-ifdef.mk b/unit-tests/directive-ifdef.mk
index 64f073fb5ae1..516e095c464f 100644
--- a/unit-tests/directive-ifdef.mk
+++ b/unit-tests/directive-ifdef.mk
@@ -1,8 +1,18 @@
-# $NetBSD: directive-ifdef.mk,v 1.2 2020/08/16 14:25:16 rillig Exp $
+# $NetBSD: directive-ifdef.mk,v 1.3 2020/11/08 22:38:28 rillig Exp $
#
# Tests for the .ifdef directive.
# TODO: Implementation
+DEFINED= defined
+
+# It looks redundant to have a call to defined() in an .ifdef, but it's
+# possible. The .ifdef only affects plain symbols, not function calls.
+.ifdef defined(DEFINED)
+. info Function calls in .ifdef are possible.
+.else
+. error
+.endif
+
all:
@:;