aboutsummaryrefslogtreecommitdiff
path: root/libbuild2/algorithm.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2022-02-09 10:11:18 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2022-02-09 10:19:46 +0200
commitc285dafe9e2b7e4bba3fddad3fa254e4bdbb02d3 (patch)
treef17edc9cc380e983b7a23409db3899dc998ded9b /libbuild2/algorithm.cxx
parent50de0d1dbdccf95722e229dd1728a00ee661412b (diff)
Don't use fallback file_rule to clean real targets
Diffstat (limited to 'libbuild2/algorithm.cxx')
-rw-r--r--libbuild2/algorithm.cxx16
1 files changed, 14 insertions, 2 deletions
diff --git a/libbuild2/algorithm.cxx b/libbuild2/algorithm.cxx
index e15fcbc..9b6fd4e 100644
--- a/libbuild2/algorithm.cxx
+++ b/libbuild2/algorithm.cxx
@@ -967,9 +967,21 @@ namespace build2
// not seem like it will be easy to fix (we don't know whether
// someone else will execute this target).
//
- // @@ What if we always do match & execute together? After all,
+ // What if we always do match & execute together? After all,
// if a group can be resolved in apply(), then it can be
- // resolved in match()!
+ // resolved in match()! Feels a bit drastic.
+ //
+ // But, this won't be a problem if the target returns noop_recipe.
+ // And perhaps it's correct to fail if it's not noop_recipe but
+ // nobody executed it? Maybe not.
+ //
+ // Another option would be to have a count for such "matched but
+ // may not be executed" targets and then make sure target_count
+ // is less than that at the end. Though this definitelt makes it
+ // less exact (since we can end up executed this target but not
+ // some other). Maybe we can increment and decrement such targets
+ // in a separate count (i.e., mark their recipe as special or some
+ // such).
//
// Apply (locked).