1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-28 22:01:15 +02:00

Don't recompile the same regex over and over

This commit is contained in:
Eelco Dolstra 2014-10-03 21:29:20 +02:00
parent 104e55bb7f
commit 3b5fa8d50c
2 changed files with 8 additions and 3 deletions

View file

@ -1,6 +1,9 @@
#pragma once
#include <memory>
#include "types.hh"
#include "regex.hh"
namespace nix {
@ -14,6 +17,9 @@ struct DrvName
DrvName();
DrvName(const string & s);
bool matches(DrvName & n);
private:
std::shared_ptr<Regex> regex;
};
typedef list<DrvName> DrvNames;