diff options
author | Nico Weber <nicolasweber@gmx.de> | 2014-01-04 05:32:41 (GMT) |
---|---|---|
committer | Nico Weber <nicolasweber@gmx.de> | 2014-01-04 05:32:41 (GMT) |
commit | d571e79baaf58032e291325043d7870eb13cb70b (patch) | |
tree | 5b6b12e7e58e629b0feee9b21ba284a3b402fb67 | |
parent | 1513693dce3aa6aa3af74965b6eb55a3cd37111e (diff) | |
download | Ninja-d571e79baaf58032e291325043d7870eb13cb70b.zip Ninja-d571e79baaf58032e291325043d7870eb13cb70b.tar.gz Ninja-d571e79baaf58032e291325043d7870eb13cb70b.tar.bz2 |
Add a comment.
-rw-r--r-- | src/ninja.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/ninja.cc b/src/ninja.cc index 5bf8221..008c052 100644 --- a/src/ninja.cc +++ b/src/ninja.cc @@ -140,6 +140,13 @@ struct NinjaMain : public BuildLogUser { virtual bool IsPathDead(StringPiece s) { Node* n = state_.LookupNode(s); + // Just checking n isn't enough: If an old output is both in the build log + // and in the deps log, it will have a Node object in state_. (It will also + // have an in edge if one of its inputs is another output that's in the deps + // log, but having a deps edge product an output thats input to another deps + // edge is rare, and the first recompaction will delete all old outputs from + // the deps log, and then a second recompaction will clear the build log, + // which seems good enough for this corner case.) return !n || !n->in_edge(); } }; |