[λ] Use lowerExpression to create captured identifier

This commit is contained in:
Sathya Gunasekaran
2023-01-19 12:13:34 +00:00
parent 50d27c325a
commit ef5636c25d
+1 -6
View File
@@ -1675,12 +1675,7 @@ function gatherCapturedDeps(
return;
}
captured.add({
kind: "Identifier",
identifier: builder.resolveIdentifier(path),
effect: Effect.Unknown,
loc: path.node.loc ?? GeneratedSource,
});
captured.add(lowerExpressionToPlace(builder, path));
},
});