summaryrefslogtreecommitdiff
path: root/usr.bin/make/cond.c
diff options
context:
space:
mode:
authorrillig <rillig@NetBSD.org>2021-01-19 17:49:13 +0000
committerrillig <rillig@NetBSD.org>2021-01-19 17:49:13 +0000
commitc5cdcf83d6bd6a67cd29d4c3da03cf6eb794dde3 (patch)
tree9d0ac8e86e2c004d7a83902961245518866844f9 /usr.bin/make/cond.c
parent8a82e20990b297064df0445b283a2c9103b7cb10 (diff)
make(1): demonstrate wrong return value in CondParser_Term
Diffstat (limited to 'usr.bin/make/cond.c')
-rw-r--r--usr.bin/make/cond.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/usr.bin/make/cond.c b/usr.bin/make/cond.c
index 1a8aba637fe..80329e62ffd 100644
--- a/usr.bin/make/cond.c
+++ b/usr.bin/make/cond.c
@@ -1,4 +1,4 @@
-/* $NetBSD: cond.c,v 1.235 2021/01/10 21:20:46 rillig Exp $ */
+/* $NetBSD: cond.c,v 1.236 2021/01/19 17:49:13 rillig Exp $ */
/*
* Copyright (c) 1988, 1989, 1990 The Regents of the University of California.
@@ -95,7 +95,7 @@
#include "dir.h"
/* "@(#)cond.c 8.2 (Berkeley) 1/2/94" */
-MAKE_RCSID("$NetBSD: cond.c,v 1.235 2021/01/10 21:20:46 rillig Exp $");
+MAKE_RCSID("$NetBSD: cond.c,v 1.236 2021/01/19 17:49:13 rillig Exp $");
/*
* The parsing of conditional expressions is based on this grammar:
@@ -949,6 +949,12 @@ CondParser_Term(CondParser *par, Boolean doEval)
t = TOK_TRUE;
}
}
+
+ /*
+ * FIXME: Can at least return TOK_AND, TOK_OR, TOK_RPAREN, maybe
+ * others as well.
+ */
+ /* TODO: assert(t == TOK_ERROR); */
return t;
}