aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/script/parser.hxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2020-06-03 16:38:23 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2020-06-04 14:20:33 +0300
commitd280946474568925016359be742b59fd6c000c52 (patch)
tree5b48a599c33f442867dfa32690e141883af0322d /libbuild2/script/parser.hxx
parentf50d0d58c8eb659e803282e19cf15398e3a8e373 (diff)
Properly handle diag directive in build script parser
Diffstat (limited to 'libbuild2/script/parser.hxx')
-rw-r--r--libbuild2/script/parser.hxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/libbuild2/script/parser.hxx b/libbuild2/script/parser.hxx
index b15f632..bec6867 100644
--- a/libbuild2/script/parser.hxx
+++ b/libbuild2/script/parser.hxx
@@ -165,7 +165,8 @@ namespace build2
// Customization hooks.
//
protected:
- // Parse the command's leading name chunk.
+ // Parse the command's leading name chunk. The argument first is true if
+ // this is the first command in the line.
//
// During the execution phase try to parse and translate the leading
// names into the process path and return nullopt if choose not to do
@@ -188,7 +189,7 @@ namespace build2
// recognize and execute certain directives, or some such.
//
virtual optional<process_path>
- parse_program (token&, token_type&, names&);
+ parse_program (token&, token_type&, bool first, names&);
// Set lexer pointers for both the current and the base classes.
//