Closed rbuckton closed 6 months ago
A preview of this PR can be found at https://tc39.es/proposal-explicit-resource-management/pr/178.
This was approved by consensus at the July, 2023 TC39 Plenary, but still needs reviews from the editors and reviewers before I can merge.
@waldemarhorwat, @syg, @michaelficarra, @bakkot: can you please review?
@waldemarhorwat, @syg: Could one of you review?
This has also been merged in to https://github.com/rbuckton/ecma262/pull/3
This moves the
DisposeResources
calls from the abstract closures inEvaluateFunctionBody
,GeneratorStart
,AsyncGeneratorStart
, andAsyncBlockStart
to theEvaluation
ofFunctionStatementList
. This centralizes the disposal logic for all function types and avoids the complexity of handling functions created from Abstract Closures that do not currently establish a proper declarative environment.This change is based on findings discovered while writing Test262 tests and implementing this proposal in Engine262.
Fixes #176 Fixes #177
cc: @tc39/ecma262-editors