aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2022-10-13 09:00:11 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2022-10-13 09:00:11 +0200
commit219e00f3b8caec38a9c8fbb4d70e33455aba5a92 (patch)
treeaf77a460d37589b6ca535cdd8d0100440d9f45a1 /libbuild2/cxx
parent7935281661a3fd50454432fae1bbf4152758137a (diff)
Optimize by going straight to public variable pool where applicable
Diffstat (limited to 'libbuild2/cxx')
-rw-r--r--libbuild2/cxx/init.cxx9
1 files changed, 6 insertions, 3 deletions
diff --git a/libbuild2/cxx/init.cxx b/libbuild2/cxx/init.cxx
index 3a934db..5396056 100644
--- a/libbuild2/cxx/init.cxx
+++ b/libbuild2/cxx/init.cxx
@@ -93,7 +93,7 @@ namespace build2
// Feature flags.
//
- auto& vp (rs.var_pool ());
+ auto& vp (rs.var_pool (true /* public */)); // All qualified.
// Similar to config.cxx.std, config.cxx.features.* overrides
// cxx.features.*.
@@ -469,7 +469,10 @@ namespace build2
// Enter all the variables and initialize the module data.
//
- auto& vp (rs.var_pool ());
+ // All the variables we enter are qualified so go straight for the
+ // public variable pool.
+ //
+ auto& vp (rs.var_pool (true /* public */));
cc::config_data d {
cc::lang::cxx,
@@ -811,7 +814,7 @@ namespace build2
auto& cm (
load_module<config_module> (rs, rs, "cxx.config", loc, extra.hints));
- auto& vp (rs.var_pool ());
+ auto& vp (rs.var_pool (true /* public */)); // All qualified.
bool modules (cast<bool> (rs["cxx.features.modules"]));