aboutsummaryrefslogtreecommitdiff
path: root/unit-tests/lexer/driver.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2017-03-16 10:35:32 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2017-03-16 18:15:18 +0200
commitece4003beebd23082a5fd7a324de40c5572161d1 (patch)
tree44597a24266b31e55b27b7393d2d20c729603d95 /unit-tests/lexer/driver.cxx
parentd2b324a72fdf16fcd68e6ba7ca0280aa95de4b71 (diff)
Add support for passing parameters to (meta-) operations
Diffstat (limited to 'unit-tests/lexer/driver.cxx')
-rw-r--r--unit-tests/lexer/driver.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/unit-tests/lexer/driver.cxx b/unit-tests/lexer/driver.cxx
index e9ccd63..41366ec 100644
--- a/unit-tests/lexer/driver.cxx
+++ b/unit-tests/lexer/driver.cxx
@@ -36,6 +36,7 @@ namespace build2
else if (a == "value") m = lexer_mode::value;
else if (a == "attribute") m = lexer_mode::attribute;
else if (a == "eval") m = lexer_mode::eval;
+ else if (a == "buildspec") m = lexer_mode::buildspec;
else assert (false);
break;
}
@@ -56,6 +57,9 @@ namespace build2
//
for (token t (l.next ()); t.type != token_type::eos; t = l.next ())
{
+ if (t.separated && t.type != token_type::newline)
+ cout << ' ';
+
// Print each token on a separate line without quoting operators.
//
t.printer (cout, t, false);