diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2015-08-03 13:10:28 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2015-08-03 13:10:28 +0200 |
commit | 0db17bfec8b3b6c436f3c9c346d17d98458c3654 (patch) | |
tree | c9dcd1d7678972b0a40450b21a7d23dd6ec1121b /build/algorithm | |
parent | 3a2efbc3d33c70aa5d0a87c9a1d16b458541bdde (diff) |
match_only and dependents count rework, part 1
Diffstat (limited to 'build/algorithm')
-rw-r--r-- | build/algorithm | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/build/algorithm b/build/algorithm index 1171f9d..99e6c2b 100644 --- a/build/algorithm +++ b/build/algorithm @@ -64,11 +64,23 @@ namespace build target& search (name, scope&); - // Match a rule to the action/target with ambiguity detection. + // Match and apply a rule to the action/target with ambiguity + // detection. Increment the target's dependents count, which + // means that you should call this function with the intent + // to also call execute(). In case of optimizations that + // would avoid calling execute(), decrement the dependents + // cound manually to compensate. // void match (action, target&); + // Match (but do not apply) a rule to the action/target with + // ambiguity detection. Note that this function does not touch + // the dependents count. + // + void + match_only (action, target&); + // Match a "delegate rule" from withing another rules' apply() // function. Return recipe and recipe action (if any). Note // that unlike match(), this call doesn't increment the @@ -120,7 +132,7 @@ namespace build // Execute the action on target, assuming a rule has been matched // and the recipe for this action has been set. This is the default - // executor implementation. + // executor implementation. Decrements the dependents count. // target_state execute (action, target&); |