diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2020-04-16 17:24:28 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2020-04-16 17:30:13 +0200 |
commit | 10e17eaa5802a3c368eee8408821828072e76ba7 (patch) | |
tree | a5f5b3f3c5411da0fe98f9938ab21b8c22309dc6 /src/libexpr/value.hh | |
parent | b3e5eea4a91400fb2a12aba4b07a94d03ba54605 (diff) |
ValueMap, VectorVector: Use traceable_allocator
We want to *trace* the 'Value *' arrays, not garbage-collect them!
Otherwise the vectors/maps can end up pointing to nowhere.
Fixes #3377. Closes #3384.
Diffstat (limited to 'src/libexpr/value.hh')
-rw-r--r-- | src/libexpr/value.hh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libexpr/value.hh b/src/libexpr/value.hh index 9cf2bf06a..71025824e 100644 --- a/src/libexpr/value.hh +++ b/src/libexpr/value.hh @@ -253,8 +253,8 @@ 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; |