aboutsummaryrefslogtreecommitdiff
path: root/src/libcmd/repl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libcmd/repl.cc')
-rw-r--r--src/libcmd/repl.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/libcmd/repl.cc b/src/libcmd/repl.cc
index 34de2160a..525c25560 100644
--- a/src/libcmd/repl.cc
+++ b/src/libcmd/repl.cc
@@ -141,7 +141,11 @@ struct NixRepl
* Note: This is `shared_ptr` to avoid garbage collection.
*/
std::shared_ptr<Value *> replOverlaysEvalFunction =
+ #if HAVE_BOEHMGC
std::allocate_shared<Value *>(traceable_allocator<Value *>(), nullptr);
+ #else
+ std::make_shared<Value *>(nullptr);
+ #endif
/**
* Get the `info` AttrSet that's passed as the first argument to each