summaryrefslogtreecommitdiffstats
path: root/src/graph.cc
diff options
context:
space:
mode:
authorKonstantin Kharlamov <Hi-Angel@users.noreply.github.com>2019-09-19 21:08:27 (GMT)
committerJan Niklas Hasse <jhasse@bixense.com>2019-09-19 21:08:27 (GMT)
commit8ed4bb844908de8bf2623bd6739da463fe83ef0b (patch)
treed03ca7f34bb2164e92ba86c3cab154482f9883d8 /src/graph.cc
parent61f90e918b608413daf07ffcb5c5c0930416951a (diff)
downloadNinja-8ed4bb844908de8bf2623bd6739da463fe83ef0b.zip
Ninja-8ed4bb844908de8bf2623bd6739da463fe83ef0b.tar.gz
Ninja-8ed4bb844908de8bf2623bd6739da463fe83ef0b.tar.bz2
Small constifications (#1647)
* build: constify EdgeWanted() * build: constify a bit of CommandRunner * graph: constify functions of struct Edge Signed-off-by: Konstantin Kharlamov <Hi-Angel@yandex.ru>
Diffstat (limited to 'src/graph.cc')
-rw-r--r--src/graph.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/graph.cc b/src/graph.cc
index 376b911..b8b870b 100644
--- a/src/graph.cc
+++ b/src/graph.cc
@@ -406,16 +406,16 @@ std::string Edge::GetBinding(const std::string& key) const {
return env.LookupVariable(key);
}
-bool Edge::GetBindingBool(const string& key) {
+bool Edge::GetBindingBool(const string& key) const {
return !GetBinding(key).empty();
}
-string Edge::GetUnescapedDepfile() {
+string Edge::GetUnescapedDepfile() const {
EdgeEnv env(this, EdgeEnv::kDoNotEscape);
return env.LookupVariable("depfile");
}
-string Edge::GetUnescapedDyndep() {
+string Edge::GetUnescapedDyndep() const {
EdgeEnv env(this, EdgeEnv::kDoNotEscape);
return env.LookupVariable("dyndep");
}