aboutsummaryrefslogtreecommitdiff
path: root/build2/parser
diff options
context:
space:
mode:
Diffstat (limited to 'build2/parser')
-rw-r--r--build2/parser11
1 files changed, 9 insertions, 2 deletions
diff --git a/build2/parser b/build2/parser
index 0962348..af5c500 100644
--- a/build2/parser
+++ b/build2/parser
@@ -56,8 +56,15 @@ namespace build2
// Recursive descent parser.
//
protected:
- void
- clause (token&, token_type&);
+ // If one is true then parse a single (logical) line (logical means it
+ // can actually be several lines, e.g., an if-block). Return false if
+ // nothing has been parsed (i.e., we are on the same token).
+ //
+ // Note that after this function returns, the token is the first token on
+ // the next line (or eos).
+ //
+ bool
+ clause (token&, token_type&, bool one = false);
void
print (token&, token_type&);