1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-27 21:01:16 +02:00

Remove static variable name clashes

This was useful for an experiment with building Nix as a single
compilation unit. It's not very useful otherwise but also doesn't
hurt...
This commit is contained in:
Eelco Dolstra 2020-10-06 13:36:55 +02:00
parent 0419cd2695
commit 85c8be6286
63 changed files with 97 additions and 92 deletions

View file

@ -33,7 +33,7 @@ struct ArchiveSettings : Config
static ArchiveSettings archiveSettings;
static GlobalConfig::Register r1(&archiveSettings);
static GlobalConfig::Register rArchiveSettings(&archiveSettings);
const std::string narVersionMagic1 = "nix-archive-1";

View file

@ -277,7 +277,7 @@ Args::Flag Args::Flag::mkHashTypeOptFlag(std::string && longName, std::optional<
};
}
static void completePath(std::string_view prefix, bool onlyDirs)
static void _completePath(std::string_view prefix, bool onlyDirs)
{
pathCompletions = true;
glob_t globbuf;
@ -300,12 +300,12 @@ static void completePath(std::string_view prefix, bool onlyDirs)
void completePath(size_t, std::string_view prefix)
{
completePath(prefix, false);
_completePath(prefix, false);
}
void completeDir(size_t, std::string_view prefix)
{
completePath(prefix, true);
_completePath(prefix, true);
}
Strings argvToStrings(int argc, char * * argv)

View file

@ -10,7 +10,7 @@ namespace nix {
LoggerSettings loggerSettings;
static GlobalConfig::Register r1(&loggerSettings);
static GlobalConfig::Register rLoggerSettings(&loggerSettings);
static thread_local ActivityId curActivity = 0;