diff options
author | Thiago Farina <tfarina@chromium.org> | 2015-12-04 22:31:19 (GMT) |
---|---|---|
committer | Thiago Farina <tfarina@chromium.org> | 2015-12-04 22:31:19 (GMT) |
commit | 336814c4ecb7993b994567527c27e0915dc207fb (patch) | |
tree | 0717eac4ec9d296b442d29d536b558d958347353 | |
parent | 9d7213e43dcc66f2dccee3e6a97aacd700947671 (diff) | |
download | Ninja-336814c4ecb7993b994567527c27e0915dc207fb.zip Ninja-336814c4ecb7993b994567527c27e0915dc207fb.tar.gz Ninja-336814c4ecb7993b994567527c27e0915dc207fb.tar.bz2 |
make use of Bindings typedef
Looks like we declared this typedef but never used it.
It seems we just forgot to use it so this patch makes uses of it now.
Otherwise we could just delete it.
-rw-r--r-- | src/eval_env.cc | 2 | ||||
-rw-r--r-- | src/eval_env.h | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/eval_env.cc b/src/eval_env.cc index e991d21..937a673 100644 --- a/src/eval_env.cc +++ b/src/eval_env.cc @@ -55,7 +55,7 @@ void Rule::AddBinding(const string& key, const EvalString& val) { } const EvalString* Rule::GetBinding(const string& key) const { - map<string, EvalString>::const_iterator i = bindings_.find(key); + Bindings::const_iterator i = bindings_.find(key); if (i == bindings_.end()) return NULL; return &i->second; diff --git a/src/eval_env.h b/src/eval_env.h index 28c4d16..999ce42 100644 --- a/src/eval_env.h +++ b/src/eval_env.h @@ -57,7 +57,6 @@ struct Rule { const string& name() const { return name_; } - typedef map<string, EvalString> Bindings; void AddBinding(const string& key, const EvalString& val); static bool IsReservedBinding(const string& var); @@ -69,7 +68,8 @@ struct Rule { friend struct ManifestParser; string name_; - map<string, EvalString> bindings_; + typedef map<string, EvalString> Bindings; + Bindings bindings_; }; /// An Env which contains a mapping of variables to values |