diff options
Diffstat (limited to 'libbuild2/test/script/lexer.test.cxx')
-rw-r--r-- | libbuild2/test/script/lexer.test.cxx | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/libbuild2/test/script/lexer.test.cxx b/libbuild2/test/script/lexer.test.cxx index 1512e58..9c64616 100644 --- a/libbuild2/test/script/lexer.test.cxx +++ b/libbuild2/test/script/lexer.test.cxx @@ -32,9 +32,6 @@ namespace build2 else if (s == "first-token") m = lexer_mode::first_token; else if (s == "second-token") m = lexer_mode::second_token; else if (s == "variable-line") m = lexer_mode::variable_line; - else if (s == "command-expansion") m = lexer_mode::command_expansion; - else if (s == "here-line-single") m = lexer_mode::here_line_single; - else if (s == "here-line-double") m = lexer_mode::here_line_double; else if (s == "description-line") m = lexer_mode::description_line; else if (s == "variable") m = lexer_mode::variable; else assert (false); @@ -46,14 +43,10 @@ namespace build2 // Some modes auto-expire so we need something underneath. // - bool u (m == lexer_mode::first_token || - m == lexer_mode::second_token || - m == lexer_mode::variable_line || - m == lexer_mode::description_line || - m == lexer_mode::variable); + bool u (m != lexer_mode::command_line); path_name in ("<stdin>"); - lexer l (cin, in, u ? lexer_mode::command_line : m); + lexer l (cin, in, lexer_mode::command_line); if (u) l.mode (m); @@ -63,7 +56,7 @@ namespace build2 { // Print each token on a separate line without quoting operators. // - t.printer (cout, t, false); + t.printer (cout, t, print_mode::normal); cout << endl; } } |