aboutsummaryrefslogtreecommitdiff
path: root/build/rule.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'build/rule.cxx')
-rw-r--r--build/rule.cxx12
1 files changed, 5 insertions, 7 deletions
diff --git a/build/rule.cxx b/build/rule.cxx
index e912b2e..475d812 100644
--- a/build/rule.cxx
+++ b/build/rule.cxx
@@ -102,10 +102,8 @@ namespace build
//
timestamp mt (dynamic_cast<path_target&> (t).mtime ());
- for (target* pt: t.prerequisites)
+ for (target* pt: t.prerequisite_targets)
{
- assert (pt != nullptr); // We don't skip anything.
-
target_state ts (execute (a, *pt));
// If this is an mtime-based target, then compare timestamps.
@@ -170,6 +168,10 @@ namespace build
recipe fsdir_rule::
apply (action a, target& t, void*) const
{
+ // Inject dependency on the parent directory.
+ //
+ inject_parent_fsdir (a, t);
+
switch (a.operation ())
{
// For default, we don't do anything other than letting our
@@ -191,10 +193,6 @@ namespace build
assert (false);
}
- // Inject dependency on the parent directory.
- //
- inject_parent_fsdir (a, t);
-
switch (a)
{
case perform_update_id: return &perform_update;