aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/algorithm.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'libbuild2/algorithm.cxx')
-rw-r--r--libbuild2/algorithm.cxx8
1 files changed, 2 insertions, 6 deletions
diff --git a/libbuild2/algorithm.cxx b/libbuild2/algorithm.cxx
index e535af3..d1a796d 100644
--- a/libbuild2/algorithm.cxx
+++ b/libbuild2/algorithm.cxx
@@ -682,9 +682,7 @@ namespace build2
// in its match() (provided that it matches) in order to, for
// example, convey some information to apply().
//
- s.vars.clear ();
- t.prerequisite_targets[a].clear ();
- if (a.inner ()) t.clear_data ();
+ clear_target (a, t);
const rule_match* r (match_rule (a, t, nullptr, try_match));
@@ -723,9 +721,7 @@ namespace build2
// As a sanity measure clear the target data since it can be incomplete
// or invalid (mark()/unmark() should give you some ideas).
//
- s.vars.clear ();
- t.prerequisite_targets[a].clear ();
- if (a.inner ()) t.clear_data ();
+ clear_target (a, t);
s.state = target_state::failed;
l.offset = target::offset_applied;