aboutsummaryrefslogtreecommitdiff
path: root/build/parser
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2014-12-15 10:43:16 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2014-12-15 10:43:16 +0200
commit835ed5f7080a98e9ee80ac08d5585ccdbb63fe0e (patch)
tree23eda92dd9df59e698f6d4a1eb24658fb3fcf323 /build/parser
parent257ad3c2c5e633d2fd3f2228021ac3ae8d6d07cb (diff)
Parse directory scopes
Diffstat (limited to 'build/parser')
-rw-r--r--build/parser18
1 files changed, 16 insertions, 2 deletions
diff --git a/build/parser b/build/parser
index 04ef00d..c487015 100644
--- a/build/parser
+++ b/build/parser
@@ -6,6 +6,7 @@
#define BUILD_PARSER
#include <string>
+#include <vector>
#include <iosfwd>
#include <exception>
@@ -32,13 +33,26 @@ namespace build
// Recursive descent parser.
//
private:
+ typedef std::vector<std::string> names;
+
void
- names (token&, token_type&);
+ parse_clause (token&, token_type&);
+
+ names
+ parse_names (token& t, token_type& tt)
+ {
+ names ns;
+ parse_names (t, tt, ns);
+ return ns;
+ }
+
+ void
+ parse_names (token&, token_type&, names&);
// Utilities.
//
private:
- void
+ token_type
next (token&, token_type&);
std::ostream&