aboutsummaryrefslogtreecommitdiff
path: root/build/file.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2015-08-14 15:48:34 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2015-08-14 15:48:34 +0200
commit47bf5cd6a167730ee06a1c7cffeae6540f67dde0 (patch)
tree7c9c07d33b41be75d1a5d6ec40c153beda2a2a19 /build/file.cxx
parentf62ff2e840fd92a03b4a3298de938d426f8b5c7a (diff)
Rework meta/operation registration
We now have global tables for meta/operation. Plus each can then be enabled on the per-project basis.
Diffstat (limited to 'build/file.cxx')
-rw-r--r--build/file.cxx16
1 files changed, 7 insertions, 9 deletions
diff --git a/build/file.cxx b/build/file.cxx
index 305c13a..e5deecf 100644
--- a/build/file.cxx
+++ b/build/file.cxx
@@ -118,19 +118,17 @@ namespace build
{
scope& rs (scopes.insert (out_root, true).first);
- // Enter built-in meta-operation and operation names. Note that
- // the order of registration should match the id constants; see
- // <operation> for details. Loading of modules (via the src
- // bootstrap; see below) can result in additional names being
- // added.
+ // Enter built-in meta-operation and operation names. Loading of
+ // modules (via the src bootstrap; see below) can result in
+ // additional meta/operations being added.
//
if (rs.meta_operations.empty ())
{
- assert (rs.meta_operations.insert (perform) == perform_id);
+ rs.meta_operations.insert (perform_id, perform);
- assert (rs.operations.insert (default_) == default_id);
- assert (rs.operations.insert (update) == update_id);
- assert (rs.operations.insert (clean) == clean_id);
+ rs.operations.insert (default_id, default_);
+ rs.operations.insert (update_id, update);
+ rs.operations.insert (clean_id, clean);
}
// If this is already a root scope, verify that things are