Move new ValidPathInfo methods to path-info.cc

We'll move the old ones separately, so as not to clutter the diff.
This commit is contained in:
John Ericson 2023-01-13 15:06:07 -05:00
parent 91617f80ec
commit 2e7be46e73
2 changed files with 15 additions and 15 deletions

View file

@ -3,6 +3,21 @@
namespace nix { namespace nix {
StorePathSet ValidPathInfo::referencesPossiblyToSelf() const
{
return references.possiblyToSelf(path);
}
void ValidPathInfo::insertReferencePossiblyToSelf(StorePath && ref)
{
return references.insertPossiblyToSelf(path, std::move(ref));
}
void ValidPathInfo::setReferencesPossiblyToSelf(StorePathSet && refs)
{
return references.setPossiblyToSelf(path, std::move(refs));
}
ValidPathInfo ValidPathInfo::read(Source & source, const Store & store, unsigned int format) ValidPathInfo ValidPathInfo::read(Source & source, const Store & store, unsigned int format)
{ {
return read(source, store, format, store.parseStorePath(readString(source))); return read(source, store, format, store.parseStorePath(readString(source)));

View file

@ -1228,21 +1228,6 @@ std::string showPaths(const PathSet & paths)
return concatStringsSep(", ", quoteStrings(paths)); return concatStringsSep(", ", quoteStrings(paths));
} }
StorePathSet ValidPathInfo::referencesPossiblyToSelf() const
{
return references.possiblyToSelf(path);
}
void ValidPathInfo::insertReferencePossiblyToSelf(StorePath && ref)
{
return references.insertPossiblyToSelf(path, std::move(ref));
}
void ValidPathInfo::setReferencesPossiblyToSelf(StorePathSet && refs)
{
return references.setPossiblyToSelf(path, std::move(refs));
}
std::string ValidPathInfo::fingerprint(const Store & store) const std::string ValidPathInfo::fingerprint(const Store & store) const
{ {
if (narSize == 0) if (narSize == 0)