From db99d2cabd0805faf7e338026965adb027513331 Mon Sep 17 00:00:00 2001 From: Ivan Enderlin Date: Tue, 3 Mar 2020 17:17:26 +0100 Subject: [PATCH] feat(interface-types) Implement `s64-to-i32x` and `u64-to-i32x` Actually, `s64-to-i32` and `u64-to-i32` already error when overflow happens. --- src/interpreter/mod.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/interpreter/mod.rs b/src/interpreter/mod.rs index 2fbb846..1cfe665 100644 --- a/src/interpreter/mod.rs +++ b/src/interpreter/mod.rs @@ -233,10 +233,8 @@ where Instruction::U16ToI32 => instructions::u16_to_i32(), Instruction::S32ToI32 => instructions::s32_to_i32(), Instruction::U32ToI32 => instructions::u32_to_i32(), - Instruction::S64ToI32 => instructions::s64_to_i32(), - //Instruction::S64ToI32X - Instruction::U64ToI32 => instructions::u64_to_i32(), - //Instruction::U64ToI32X + Instruction::S64ToI32 | Instruction::S64ToI32X => instructions::s64_to_i32(), + Instruction::U64ToI32 | Instruction::U64ToI32X => instructions::u64_to_i32(), Instruction::S8ToI64 => instructions::s8_to_i64(), Instruction::U8ToI64 => instructions::u8_to_i64(), Instruction::S16ToI64 => instructions::s16_to_i64(),