summaryrefslogtreecommitdiff
path: root/ext/node/polyfills/internal_binding/udp_wrap.ts
diff options
context:
space:
mode:
authorKenta Moriuchi <moriken@kimamass.com>2024-01-11 07:37:25 +0900
committerGitHub <noreply@github.com>2024-01-10 15:37:25 -0700
commit515a34b4de222e35c7ade1b92614d746e73d4c2e (patch)
tree8284201fc826a33f12597959a8a8be14e0f524bd /ext/node/polyfills/internal_binding/udp_wrap.ts
parentd4893eb51a01c5a692d8ca74a3b8ff95c5fd1d9f (diff)
refactor: use `core.ensureFastOps()` (#21888)
Diffstat (limited to 'ext/node/polyfills/internal_binding/udp_wrap.ts')
-rw-r--r--ext/node/polyfills/internal_binding/udp_wrap.ts10
1 files changed, 7 insertions, 3 deletions
diff --git a/ext/node/polyfills/internal_binding/udp_wrap.ts b/ext/node/polyfills/internal_binding/udp_wrap.ts
index 209c84a23..b78f2a077 100644
--- a/ext/node/polyfills/internal_binding/udp_wrap.ts
+++ b/ext/node/polyfills/internal_binding/udp_wrap.ts
@@ -24,7 +24,11 @@
// deno-lint-ignore-file prefer-primordials
import { core } from "ext:core/mod.js";
-const ops = core.ops;
+const {
+ op_node_unstable_net_listen_udp,
+ op_node_unstable_net_listen_unixpacket,
+} = core.ensureFastOps();
+
import {
AsyncWrap,
providerType,
@@ -41,8 +45,8 @@ import * as net from "ext:deno_net/01_net.js";
import { isLinux, isWindows } from "ext:deno_node/_util/os.ts";
const DenoListenDatagram = net.createListenDatagram(
- ops.op_node_unstable_net_listen_udp,
- ops.op_node_unstable_net_listen_unixpacket,
+ op_node_unstable_net_listen_udp,
+ op_node_unstable_net_listen_unixpacket,
);
type MessageType = string | Uint8Array | Buffer | DataView;