aboutsummaryrefslogtreecommitdiff
path: root/src/libexpr/eval.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2021-07-05 13:53:52 +0200
committerEelco Dolstra <edolstra@gmail.com>2021-07-05 13:53:52 +0200
commit24bc9354627b3b6d65efb9bb18faa57d681624db (patch)
tree9d09107383c5a0ab6b843d327e3b41de6be4567f /src/libexpr/eval.cc
parentc053aecff4e44cde74ad043796623a8073413c99 (diff)
parent5be17a4b96fa4dbd512da4cba59f177cdbd84935 (diff)
Merge branch 'disable_gc' of https://github.com/Pamplemousse/nix
Diffstat (limited to 'src/libexpr/eval.cc')
-rw-r--r--src/libexpr/eval.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc
index fe25d894a..c3206a577 100644
--- a/src/libexpr/eval.cc
+++ b/src/libexpr/eval.cc
@@ -64,7 +64,11 @@ static char * dupStringWithLen(const char * s, size_t size)
RootValue allocRootValue(Value * v)
{
+#if HAVE_BOEHMGC
return std::allocate_shared<Value *>(traceable_allocator<Value *>(), v);
+#else
+ return std::make_shared<Value *>(v);
+#endif
}