From ad720fabd468974e3909f62a0f4e4e3cf0d03aef Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 15 Apr 2015 11:59:58 +0200 Subject: Initial library support --- build/scope | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'build/scope') diff --git a/build/scope b/build/scope index f9492e6..e4a8a7d 100644 --- a/build/scope +++ b/build/scope @@ -46,10 +46,13 @@ namespace build // public: value_proxy - operator[] (const std::string&); + operator[] (const variable&); value_proxy - operator[] (const variable&); + operator[] (const std::string& name) + { + return operator[] (variable_pool.find (name)); + } const dir_path* src_path_ {nullptr}; // Cached src_{root,base} var value. @@ -92,7 +95,7 @@ namespace build typedef dir_path_map::const_iterator iterator; - scope (): variables (*this) {} + scope (): variables (this) {} iterator i_; scope* parent_; -- cgit v1.1