Skip to content

Commit

Permalink
Bump to wasmedge 0.14
Browse files Browse the repository at this point in the history
Signed-off-by: csh <[email protected]>
  • Loading branch information
L-jasmine committed Feb 5, 2024
1 parent fa3f3ce commit a6220e9
Show file tree
Hide file tree
Showing 13 changed files with 750 additions and 551 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/ci-build-release-lib.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ concurrency:

on:
push:
branches:
- '!bump/**'
paths-ignore:
- "**/*.md"
- ".github/workflows/standalone.yml"
Expand Down
4 changes: 2 additions & 2 deletions crates/wasmedge-sys/src/ast_module.rs
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ impl<'module> ImportType<'module> {
false => {
// get the element type
let elem_ty = unsafe { ffi::WasmEdge_TableTypeGetRefType(ctx_tab_ty) };
let elem_ty: RefType = elem_ty.into();
let elem_ty = RefType::from(ValType::from(elem_ty));

// get the limit
let limit = unsafe { ffi::WasmEdge_TableTypeGetLimit(ctx_tab_ty) };
Expand Down Expand Up @@ -317,7 +317,7 @@ impl<'module> ExportType<'module> {
false => {
// get the element type
let elem_ty = unsafe { ffi::WasmEdge_TableTypeGetRefType(ctx_tab_ty) };
let elem_ty: RefType = elem_ty.into();
let elem_ty = RefType::from(ValType::from(elem_ty));

// get the limit
let limit = unsafe { ffi::WasmEdge_TableTypeGetLimit(ctx_tab_ty) };
Expand Down
6 changes: 3 additions & 3 deletions crates/wasmedge-sys/src/async/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,19 +164,19 @@ mod tests {
println!("Rust: Entering Rust function real_add");

if input.len() != 2 {
return Err(CoreError::Execution(CoreExecutionError::FuncTypeMismatch));
return Err(CoreError::Execution(CoreExecutionError::FuncSigMismatch));
}

let a = if input[0].ty() == ValType::I32 {
input[0].to_i32()
} else {
return Err(CoreError::Execution(CoreExecutionError::FuncTypeMismatch));
return Err(CoreError::Execution(CoreExecutionError::FuncSigMismatch));
};

let b = if input[1].ty() == ValType::I32 {
input[1].to_i32()
} else {
return Err(CoreError::Execution(CoreExecutionError::FuncTypeMismatch));
return Err(CoreError::Execution(CoreExecutionError::FuncSigMismatch));
};

tokio::time::sleep(std::time::Duration::from_millis(300)).await;
Expand Down
Loading

0 comments on commit a6220e9

Please sign in to comment.