mirror of
https://github.com/NixOS/nix.git
synced 2025-11-10 20:46:01 +01:00
treewide: Use StringSet alias consistently instead of std::set<std::string>
The intention is to switch to transparent comparators from N3657 for ordered set containers for strings and using the alias consistently would simplify things.
This commit is contained in:
parent
a976a46ee8
commit
d8c97d8073
55 changed files with 111 additions and 109 deletions
|
|
@ -40,7 +40,7 @@ nlohmann::json NixMultiCommand::toJSON()
|
|||
void NixMultiCommand::run()
|
||||
{
|
||||
if (!command) {
|
||||
std::set<std::string> subCommandTextLines;
|
||||
StringSet subCommandTextLines;
|
||||
for (auto & [name, _] : commands)
|
||||
subCommandTextLines.insert(fmt("- `%s`", name));
|
||||
std::string markdownError =
|
||||
|
|
|
|||
|
|
@ -363,7 +363,7 @@ void completeFlakeRefWithFragment(
|
|||
const Strings & defaultFlakeAttrPaths,
|
||||
std::string_view prefix);
|
||||
|
||||
std::string showVersions(const std::set<std::string> & versions);
|
||||
std::string showVersions(const StringSet & versions);
|
||||
|
||||
void printClosureDiff(
|
||||
ref<Store> store, const StorePath & beforePath, const StorePath & afterPath, std::string_view indent);
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ DerivedPathsWithInfo InstallableAttrPath::toDerivedPaths()
|
|||
|
||||
auto newOutputs = std::visit(overloaded {
|
||||
[&](const ExtendedOutputsSpec::Default & d) -> OutputsSpec {
|
||||
std::set<std::string> outputsToInstall;
|
||||
StringSet outputsToInstall;
|
||||
for (auto & output : packageInfo.queryOutputs(false, true))
|
||||
outputsToInstall.insert(output.first);
|
||||
if (outputsToInstall.empty())
|
||||
|
|
|
|||
|
|
@ -117,7 +117,7 @@ DerivedPathsWithInfo InstallableFlake::toDerivedPaths()
|
|||
.drvPath = makeConstantStorePathRef(std::move(drvPath)),
|
||||
.outputs = std::visit(overloaded {
|
||||
[&](const ExtendedOutputsSpec::Default & d) -> OutputsSpec {
|
||||
std::set<std::string> outputsToInstall;
|
||||
StringSet outputsToInstall;
|
||||
if (auto aOutputSpecified = attr->maybeGetAttr(state->sOutputSpecified)) {
|
||||
if (aOutputSpecified->getBool()) {
|
||||
if (auto aOutputName = attr->maybeGetAttr("outputName"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue