diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2017-07-28 09:28:28 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2017-07-28 09:28:28 +0200 |
commit | e84eedc54348e268ca95200b70caede9884076ea (patch) | |
tree | 47adec094b24d8cb6934bbf28434e746ad9f564f /build2/install | |
parent | 566bcb8c4c36d12e398f00349c5f27cae06fa7a9 (diff) |
Add support for custom data storage in target::preprequisite_targets
Diffstat (limited to 'build2/install')
-rw-r--r-- | build2/install/rule.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/build2/install/rule.cxx b/build2/install/rule.cxx index 6b0905f..8611247 100644 --- a/build2/install/rule.cxx +++ b/build2/install/rule.cxx @@ -189,10 +189,10 @@ namespace build2 // Save the prerequisite targets that we found since the // call to match_delegate() below will wipe them out. // - target::prerequisite_targets_type p; + prerequisite_targets pts; if (!t.prerequisite_targets.empty ()) - p.swap (t.prerequisite_targets); + pts.swap (t.prerequisite_targets); // Find the "real" update rule, that is, the rule that would // have been found if we signalled that we do not match from @@ -203,24 +203,24 @@ namespace build2 // If we have no installable prerequisites, then simply redirect // to it. // - if (p.empty ()) + if (pts.empty ()) return d; // Ok, the worst case scenario: we need to cause update of // prerequisite targets and also delegate to the real update. // - return [pt = move (p), dr = move (d)] ( + return [pts = move (pts), d = move (d)] ( action a, const target& t) mutable -> target_state { // Do the target update first. // - target_state r (execute_delegate (dr, a, t)); + target_state r (execute_delegate (d, a, t)); // Swap our prerequisite targets back in and execute. // - t.prerequisite_targets.swap (pt); + t.prerequisite_targets.swap (pts); r |= straight_execute_prerequisites (a, t); - pt.swap (t.prerequisite_targets); // In case we get re-executed. + pts.swap (t.prerequisite_targets); // In case we get re-executed. return r; }; |