Skip to content

Commit 40c5d58

Browse files
addaleaxtargos
authored andcommitted
Revert "src: keep main-thread Isolate attached to platform during Dispose"
This reverts commit e460f8c. It is no longer necessary after the previous commit, and restores consistency of the call order between the main thread code, the other call sites, and the documentation. Refs: #31795 PR-URL: #31853 Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
1 parent f5b60ec commit 40c5d58

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/node_main_instance.cc

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,8 @@ NodeMainInstance::~NodeMainInstance() {
102102
if (!owns_isolate_) {
103103
return;
104104
}
105-
// TODO(addaleax): Reverse the order of these calls. The fact that we first
106-
// dispose the Isolate is a temporary workaround for
107-
// https://github.com/nodejs/node/issues/31752 -- V8 should not be posting
108-
// platform tasks during Dispose(), but it does in some WASM edge cases.
109-
isolate_->Dispose();
110105
platform_->UnregisterIsolate(isolate_);
106+
isolate_->Dispose();
111107
}
112108

113109
int NodeMainInstance::Run() {

0 commit comments

Comments
 (0)