getMachines(): Cache result

This commit is contained in:
Eelco Dolstra 2019-04-01 21:09:35 +02:00
parent 2f59b30251
commit 2bc6304793

View file

@ -89,10 +89,11 @@ void parseMachines(const std::string & s, Machines & machines)
Machines getMachines() Machines getMachines()
{ {
static auto machines = [&]() {
Machines machines; Machines machines;
parseMachines(settings.builders, machines); parseMachines(settings.builders, machines);
return machines;
}();
return machines; return machines;
} }