diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2020-01-28 08:11:16 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2020-01-28 08:11:16 +0200 |
commit | c0105aad0074aee0efb3ba41f8132496412f8790 (patch) | |
tree | 30fe24cfe2e63c7cacdd7d45d875ca75f35bede2 /libbuild2/config/init.cxx | |
parent | 36fa3bc49a739a3bb1212a1b37fd2c817d4ee1dc (diff) |
Use scope::insert_rule()
Diffstat (limited to 'libbuild2/config/init.cxx')
-rw-r--r-- | libbuild2/config/init.cxx | 22 |
1 files changed, 8 insertions, 14 deletions
diff --git a/libbuild2/config/init.cxx b/libbuild2/config/init.cxx index d48e0a8..56aed15 100644 --- a/libbuild2/config/init.cxx +++ b/libbuild2/config/init.cxx @@ -279,22 +279,16 @@ namespace build2 // libraries imported from /usr/lib). We are registring it on the // global scope similar to builtin rules. // - { - auto& r (rs.global_scope ().rules); - r.insert<mtime_target> ( - configure_id, 0, "config.file", file_rule::instance); - } - { - auto& r (rs.rules); + rs.global_scope ().insert_rule<mtime_target> ( + configure_id, 0, "config.file", file_rule::instance); - //@@ outer - r.insert<alias> (configure_id, 0, "config.alias", alias_rule::instance); + //@@ outer + rs.insert_rule<alias> (configure_id, 0, "config.alias", alias_rule::instance); - // This allows a custom configure rule while doing nothing by default. - // - r.insert<target> (configure_id, 0, "config", noop_rule::instance); - r.insert<file> (configure_id, 0, "config.file", noop_rule::instance); - } + // This allows a custom configure rule while doing nothing by default. + // + rs.insert_rule<target> (configure_id, 0, "config", noop_rule::instance); + rs.insert_rule<file> (configure_id, 0, "config.file", noop_rule::instance); return true; } |