Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/deno/cli/tsc/dts/lib.deno.unstable.d.ts>Deno.UnsafeCallback#close

A modern runtime for JavaScript and TypeScript.
Latest
method Deno.UnsafeCallback.prototype.close
import { Deno } from "https://deno.land/x/deno@v1.41.0/cli/tsc/dts/lib.deno.unstable.d.ts";
const { UnsafeCallback } = Deno;

Removes the C function pointer associated with this instance.

Continuing to use the instance or the C function pointer after closing the UnsafeCallback will lead to errors and crashes.

Calling this method sets the callback's reference counting to zero, stops the callback from waking up the Deno event loop when called from foreign threads and no longer keeps Deno's process from exiting.