From 50bb4749af25efce64bc7e7b1045855f81b6343e Mon Sep 17 00:00:00 2001 From: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Date: Sat, 20 May 2023 19:43:44 -0700 Subject: [internal] Make `JSC.NewFunction` more type safe --- src/bun.js/api/ffi.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/bun.js/api/ffi.zig') diff --git a/src/bun.js/api/ffi.zig b/src/bun.js/api/ffi.zig index ae3e596f1..fe2b50955 100644 --- a/src/bun.js/api/ffi.zig +++ b/src/bun.js/api/ffi.zig @@ -384,7 +384,7 @@ pub const FFI = struct { global, &str, @intCast(u32, function.arg_types.items.len), - compiled.ptr, + bun.cast(JSC.JSHostFunctionPtr, compiled.ptr), false, ); compiled.js_function = cb; @@ -480,7 +480,7 @@ pub const FFI = struct { global, name, @intCast(u32, function.arg_types.items.len), - compiled.ptr, + bun.cast(JSC.JSHostFunctionPtr, compiled.ptr), false, ); compiled.js_function = cb; -- cgit v1.2.3