MCPcopy Create free account
hub / github.com/WebAssembly/wasm-c-api / ~StoreImpl

Method ~StoreImpl

src/wasm-v8.cc:331–350  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

329 }
330
331 ~StoreImpl() {
332#ifdef WASM_API_DEBUG
333 isolate_->RequestGarbageCollectionForTesting(
334 v8::Isolate::kFullGarbageCollection);
335#endif
336 {
337 v8::HandleScope scope(isolate_);
338 while (handle_pool_ != nullptr) {
339 auto handle = handle_pool_;
340 handle_pool_ = reinterpret_cast<v8::Persistent<v8::Object>*>(
341 wasm_v8::foreign_get(handle->Get(isolate_)));
342 delete handle;
343 }
344 }
345 context()->Exit();
346 isolate_->Exit();
347 isolate_->Dispose();
348 delete create_params_.array_buffer_allocator;
349 stats.free(Stats::STORE, this);
350 }
351
352 auto isolate() const -> v8::Isolate* {
353 return isolate_;

Callers

nothing calls this directly

Calls 2

foreign_getFunction · 0.85
freeMethod · 0.80

Tested by

no test coverage detected