summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2013-09-22 17:10:35 -0400
committerPaul Smith <psmith@gnu.org>2013-09-22 17:10:35 -0400
commitfdafd90e37f2cb2b631cd4bf4d759d8c942a1c81 (patch)
tree78751c2d36ded09824d12a3a6365f4fb7f8fb3c7 /tests
parent8a3655751fc41aa04cfd69fd9c9803df0e915a72 (diff)
downloadmake-fdafd90e37f2cb2b631cd4bf4d759d8c942a1c81.tar.gz
[SV 31155] Parse order-only tokens in second expansion results.
Diffstat (limited to 'tests')
-rw-r--r--tests/ChangeLog4
-rw-r--r--tests/scripts/features/se_implicit12
2 files changed, 16 insertions, 0 deletions
diff --git a/tests/ChangeLog b/tests/ChangeLog
index ad746d2a..eaeb7c0e 100644
--- a/tests/ChangeLog
+++ b/tests/ChangeLog
@@ -1,5 +1,9 @@
2013-09-22 Paul Smith <psmith@gnu.org>
+ * scripts/features/se_implicit: Verify that order-only tokens
+ inside second expansion are parsed correctly.
+ Test for Savannah bug #31155.
+
* run_make_tests.pl (set_more_defaults): If we can't find
gnumake.h based on the make program we might be running from a
remote build directory. Parse the Makefile for the right path.
diff --git a/tests/scripts/features/se_implicit b/tests/scripts/features/se_implicit
index 0a31948a..ec09d8da 100644
--- a/tests/scripts/features/se_implicit
+++ b/tests/scripts/features/se_implicit
@@ -244,5 +244,17 @@ sim_%: \
unlink('a');
+# Ensure that order-only tokens embedded in second expansions are parsed
+run_make_test(q!
+.SECONDEXPANSION:
+PREREQS=p1|p2
+P2=p2
+all : foo bar
+f%o: $$(PREREQS) ; @echo '$@' from '$^' and '$|'
+b%r: p1|$$(P2) ; @echo '$@' from '$^' and '$|'
+p% : ; : $@
+!,
+ "", ": p1\n: p2\nfoo from p1 and p2\nbar from p1 and p2\n");
+
# This tells the test driver that the perl test script executed properly.
1;