From 9bf93c1ab73ee3cd2b763285fc5fc5456e972854 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 11 Jan 2017 10:14:23 +0200 Subject: Implement support for narrowing down tests (config.test) --- build2/cc/module.cxx | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'build2/cc/module.cxx') diff --git a/build2/cc/module.cxx b/build2/cc/module.cxx index 40bd454..e63f740 100644 --- a/build2/cc/module.cxx +++ b/build2/cc/module.cxx @@ -55,7 +55,7 @@ namespace build2 // auto p (config::omitted (rs, config_x)); - if (p.first == nullptr) + if (!p.first) { // If someone already loaded cc.core.config then use its toolchain // id and (optional) pattern to guess an appropriate default (e.g., @@ -71,13 +71,11 @@ namespace build2 // user changes the source of the pattern, this one will get updated // as well. // - auto p1 (config::required (rs, - config_x, - d, - false, - cc_loaded ? config::save_commented : 0)); - p.first = &p1.first.get (); - p.second = p1.second; + p = config::required (rs, + config_x, + d, + false, + cc_loaded ? config::save_commented : 0); } // Figure out which compiler we are dealing with, its target, etc. -- cgit v1.1