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/bash | |
parent | 36fa3bc49a739a3bb1212a1b37fd2c817d4ee1dc (diff) |
Use scope::insert_rule()
Diffstat (limited to 'libbuild2/bash')
-rw-r--r-- | libbuild2/bash/init.cxx | 28 |
1 files changed, 12 insertions, 16 deletions
diff --git a/libbuild2/bash/init.cxx b/libbuild2/bash/init.cxx index dc1f8f6..ed84265 100644 --- a/libbuild2/bash/init.cxx +++ b/libbuild2/bash/init.cxx @@ -64,25 +64,21 @@ namespace build2 // Register rules. // - { - auto& r (bs.rules); - - r.insert<exe> (perform_update_id, "bash.in", in_rule_); - r.insert<exe> (perform_clean_id, "bash.in", in_rule_); - r.insert<exe> (configure_update_id, "bash.in", in_rule_); + bs.insert_rule<exe> (perform_update_id, "bash.in", in_rule_); + bs.insert_rule<exe> (perform_clean_id, "bash.in", in_rule_); + bs.insert_rule<exe> (configure_update_id, "bash.in", in_rule_); - r.insert<bash> (perform_update_id, "bash.in", in_rule_); - r.insert<bash> (perform_clean_id, "bash.in", in_rule_); - r.insert<bash> (configure_update_id, "bash.in", in_rule_); + bs.insert_rule<bash> (perform_update_id, "bash.in", in_rule_); + bs.insert_rule<bash> (perform_clean_id, "bash.in", in_rule_); + bs.insert_rule<bash> (configure_update_id, "bash.in", in_rule_); - if (install_loaded) - { - r.insert<exe> (perform_install_id, "bash.install", install_rule_); - r.insert<exe> (perform_uninstall_id, "bash.uninstall", install_rule_); + if (install_loaded) + { + bs.insert_rule<exe> (perform_install_id, "bash.install", install_rule_); + bs.insert_rule<exe> (perform_uninstall_id, "bash.uninstall", install_rule_); - r.insert<bash> (perform_install_id, "bash.install", install_rule_); - r.insert<bash> (perform_uninstall_id, "bash.uninstall", install_rule_); - } + bs.insert_rule<bash> (perform_install_id, "bash.install", install_rule_); + bs.insert_rule<bash> (perform_uninstall_id, "bash.uninstall", install_rule_); } return true; |