diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2020-04-16 18:33:10 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2020-04-16 18:33:10 +0200 |
commit | f89349f07eda66dea2aa3b70bdc2c5c649406bdc (patch) | |
tree | 9ff9148956592d29fc1c7e45ccf4dfc64b2457b5 /src/libexpr/value.hh | |
parent | 0858738355dd9bdb20a723f15629c423fe14a7b1 (diff) | |
parent | efaffaa9d1de38efecb718aa7a99ba1f2e342ade (diff) |
Merge remote-tracking branch 'origin/master' into flakes
Diffstat (limited to 'src/libexpr/value.hh')
-rw-r--r-- | src/libexpr/value.hh | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/libexpr/value.hh b/src/libexpr/value.hh index 60de60c67..1a0738241 100644 --- a/src/libexpr/value.hh +++ b/src/libexpr/value.hh @@ -258,12 +258,17 @@ void mkPath(Value & v, const char * s); #if HAVE_BOEHMGC -typedef std::vector<Value *, gc_allocator<Value *> > ValueVector; -typedef std::map<Symbol, Value *, std::less<Symbol>, gc_allocator<std::pair<const Symbol, Value *> > > ValueMap; +typedef std::vector<Value *, traceable_allocator<Value *> > ValueVector; +typedef std::map<Symbol, Value *, std::less<Symbol>, traceable_allocator<std::pair<const Symbol, Value *> > > ValueMap; #else typedef std::vector<Value *> ValueVector; typedef std::map<Symbol, Value *> ValueMap; #endif +/* A value allocated in traceable memory. */ +typedef std::shared_ptr<Value *> RootValue; + +RootValue allocRootValue(Value * v); + } |