1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-06 21:41:48 +02:00

Unify DirEntries types

This commit is contained in:
Eelco Dolstra 2023-11-01 15:33:19 +01:00
parent cdb27c1519
commit 5381123879
8 changed files with 16 additions and 14 deletions

View file

@ -48,15 +48,15 @@ struct LocalStoreAccessor : public FSAccessor
S_ISREG(st.st_mode) && st.st_mode & S_IXUSR}};
}
StringSet readDirectory(const Path & path) override
DirEntries readDirectory(const Path & path) override
{
auto realPath = toRealPath(path);
auto entries = nix::readDirectory(realPath);
StringSet res;
DirEntries res;
for (auto & entry : entries)
res.insert(entry.name);
res.insert_or_assign(entry.name, std::nullopt);
return res;
}