aboutsummaryrefslogtreecommitdiff
path: root/build2/scope.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2019-03-07 14:30:28 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2019-03-07 14:30:28 +0200
commit9400ddfc949025abddb04344624fba3945562d33 (patch)
treed67200faeaa9500f79117b46542b93ec745ef58d /build2/scope.cxx
parent1845141809aa91b03718066a6f46863885a6a887 (diff)
Move bunch of root scope-only data members to root_extra
Diffstat (limited to 'build2/scope.cxx')
-rw-r--r--build2/scope.cxx8
1 files changed, 7 insertions, 1 deletions
diff --git a/build2/scope.cxx b/build2/scope.cxx
index ce6945e..bae9818 100644
--- a/build2/scope.cxx
+++ b/build2/scope.cxx
@@ -424,8 +424,13 @@ namespace build2
// Check the cache.
//
+ variable_override_cache& cache (
+ inner_proj == global_scope
+ ? global_override_cache
+ : inner_proj->root_extra->override_cache);
+
pair<value&, ulock> entry (
- inner_proj->override_cache.insert (
+ cache.insert (
make_pair (&var, inner_vars),
stem,
0, // Overrides are immutable.
@@ -792,6 +797,7 @@ namespace build2
}
scope* scope::global_;
+ scope::variable_override_cache scope::global_override_cache;
// scope_map
//