Assert that compatible realisations have the same dependencies

Should always hold, but that’s not necessarily obvious, so better
enforce it
This commit is contained in:
regnat 2021-06-22 10:50:28 +02:00
parent 16fb7d8d95
commit c878cee895

View file

@ -143,7 +143,11 @@ StorePath RealisedPath::path() const {
bool Realisation::isCompatibleWith(const Realisation & other) const bool Realisation::isCompatibleWith(const Realisation & other) const
{ {
assert (id == other.id); assert (id == other.id);
return outPath == other.outPath; if (outPath == other.outPath) {
assert(dependentRealisations == other.dependentRealisations);
return true;
}
return false;
} }
void RealisedPath::closure( void RealisedPath::closure(