Skip to content

Commit a8f98d1

Browse files
committed
Expose Func.matchesKind to consumers
1 parent 9c42564 commit a8f98d1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main.zig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ pub const Func = opaque {
221221
}
222222

223223
/// Returns tue if the given `kind` of `Valkind` can coerce to type `T`
224-
fn matchesKind(comptime T: type, kind: Valkind) bool {
224+
pub fn matchesKind(comptime T: type, kind: Valkind) bool {
225225
return switch (T) {
226226
i32, u32 => kind == .i32,
227227
i64, u64 => kind == .i64,
@@ -236,7 +236,7 @@ pub const Func = opaque {
236236
extern "c" fn wasm_func_new(*Store, ?*c_void, Callback) ?*Func;
237237
extern "c" fn wasm_func_delete(*Func) void;
238238
extern "c" fn wasm_func_as_extern(*Func) ?*Extern;
239-
extern "c" fn wasm_func_copy(*Func) ?*Func;
239+
extern "c" fn wasm_func_copy(*const Func) ?*Func;
240240
extern "c" fn wasm_func_call(*Func, *const ValVec, *ValVec) ?*Trap;
241241
extern "c" fn wasm_func_result_arity(*Func) usize;
242242
extern "c" fn wasm_func_param_arity(*Func) usize;

0 commit comments

Comments
 (0)