aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/value.hh
diff options
context:
space:
mode:
authorSilvan Mosberger <contact@infinisil.com>2021-12-02 17:46:44 +0100
committerSilvan Mosberger <contact@infinisil.com>2021-12-02 21:54:51 +0100
commit90700736c7744b97ab69a4fadcd56fa242ec617f (patch)
treefe1915e61e4d367dd393fc4c45021c9fcf7ac226 /src/libexpr/value.hh
parent2ff71b021379a2c9bbdcb789a93cdc585b3520ca (diff)
Introduce builtins.groupBy primop
This function is very useful in nixpkgs, but its implementation in Nix itself is rather slow due to it requiring a lot of attribute set and list appends.
Diffstat (limited to 'src/libexpr/value.hh')
-rw-r--r--src/libexpr/value.hh2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libexpr/value.hh b/src/libexpr/value.hh
index 4b43e47ae..6b4f3c0ae 100644
--- a/src/libexpr/value.hh
+++ b/src/libexpr/value.hh
@@ -425,9 +425,11 @@ void mkPath(Value & v, const char * s);
#if HAVE_BOEHMGC
typedef std::vector<Value *, traceable_allocator<Value *> > ValueVector;
typedef std::map<Symbol, Value *, std::less<Symbol>, traceable_allocator<std::pair<const Symbol, Value *> > > ValueMap;
+typedef std::map<Symbol, ValueVector, std::less<Symbol>, traceable_allocator<std::pair<const Symbol, ValueVector> > > ValueVectorMap;
#else
typedef std::vector<Value *> ValueVector;
typedef std::map<Symbol, Value *> ValueMap;
+typedef std::map<Symbol, ValueVector> ValueVectorMap;
#endif