Skip to content

Commit 60f0992

Browse files
committed
libexpr: move ExprLet::attrs data to arena as well
I missed this because I assumed all Exprs were recursed into by bindVars, but ExprLet's ExprAttrs field is not really its own AST node, so it doesn't get recursed into.
1 parent 43a1831 commit 60f0992

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/libexpr/nixexpr.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -504,6 +504,7 @@ void ExprCall::bindVars(EvalState & es, const std::shared_ptr<const StaticEnv> &
504504

505505
void ExprLet::bindVars(EvalState & es, const std::shared_ptr<const StaticEnv> & env)
506506
{
507+
attrs->moveDataToAllocator(es.mem.exprs.alloc);
507508
auto newEnv = [&]() -> std::shared_ptr<const StaticEnv> {
508509
auto newEnv = std::make_shared<StaticEnv>(nullptr, env, attrs->attrs->size());
509510

0 commit comments

Comments
 (0)