mirror of
https://github.com/NixOS/nix.git
synced 2025-11-26 12:10:59 +01:00
added state options and state locations into drv
This commit is contained in:
parent
b712f0f019
commit
4c63f18dcc
7 changed files with 120 additions and 14 deletions
|
|
@ -51,3 +51,15 @@ ATermList nix::toATermList(const StringSet & ss)
|
|||
l = ATinsert(l, toATerm(*i));
|
||||
return l;
|
||||
}
|
||||
|
||||
ATermList nix::toATermList(const SetStringSet & sss)
|
||||
{
|
||||
ATermList l = ATempty;
|
||||
for (SetStringSet::const_reverse_iterator i = sss.rbegin(); i != sss.rend(); ++i){
|
||||
StringSet ss = *i;
|
||||
for (StringSet::const_reverse_iterator j = ss.rbegin(); j != ss.rend(); ++j){
|
||||
l = ATinsert(l, toATerm(*j));
|
||||
}
|
||||
}
|
||||
return l;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@ ATerm toATerm(const char * s);
|
|||
ATerm toATerm(const string & s);
|
||||
|
||||
ATermList toATermList(const StringSet & ss);
|
||||
ATermList toATermList(const SetStringSet & sss);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -48,6 +48,7 @@ public:
|
|||
|
||||
typedef list<string> Strings;
|
||||
typedef set<string> StringSet;
|
||||
typedef set<StringSet> SetStringSet;
|
||||
|
||||
|
||||
/* Paths are just strings. */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue