From 7c8e544b520cc46c174a952e63ccd2d71002516d Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Wed, 20 May 2020 14:51:58 +0300 Subject: Partially implement dump(ostream,script::lines) --- libbuild2/build/script/parser+line.test.testscript | 9 +++++++++ libbuild2/build/script/parser.test.cxx | 12 ++++++++++++ 2 files changed, 21 insertions(+) (limited to 'libbuild2/build') diff --git a/libbuild2/build/script/parser+line.test.testscript b/libbuild2/build/script/parser+line.test.testscript index df4e77b..fe38249 100644 --- a/libbuild2/build/script/parser+line.test.testscript +++ b/libbuild2/build/script/parser+line.test.testscript @@ -37,3 +37,12 @@ $* <| foo 'bar' "baz" '' "" EOI #\ + +#\ + libbuild2/lexer+quoting.test.testscript + + : tmp + : + $* <'f"oo" "foo$"' + +#\ diff --git a/libbuild2/build/script/parser.test.cxx b/libbuild2/build/script/parser.test.cxx index b5afd47..ab9935d 100644 --- a/libbuild2/build/script/parser.test.cxx +++ b/libbuild2/build/script/parser.test.cxx @@ -72,6 +72,18 @@ namespace build2 // argv[0] [-l] // argv[0] -d // + // In the first form read the script from stdin and trace the script + // execution to stdout using the custom print runner. + // + // In the second form read the script from stdin, parse it and dump the + // resulting lines to stdout. + // + // -l + // Print the script line number for each executed expression. + // + // -d + // Dump the parsed script to sdout. + // int main (int argc, char* argv[]) { -- cgit v1.1