From bd97b1f1a847766e8895cb6d689a572558edcc42 Mon Sep 17 00:00:00 2001 From: Mark Koch Date: Mon, 27 Nov 2023 13:27:13 +0000 Subject: [PATCH 1/2] fix: Use correct number of args for int ops --- src/std_extensions/arithmetic/int_ops.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/std_extensions/arithmetic/int_ops.rs b/src/std_extensions/arithmetic/int_ops.rs index 9a77f5dfb..422f7b2ab 100644 --- a/src/std_extensions/arithmetic/int_ops.rs +++ b/src/std_extensions/arithmetic/int_ops.rs @@ -81,11 +81,15 @@ fn extension() -> Extension { let idiv_checked_sig = int_polytype( 2, - vec![int_type_var(1)], + vec![int_type_var(0), int_type_var(1)], vec![sum_with_error(int_type_var(0))], ); - let idiv_sig = int_polytype(2, vec![int_type_var(1)], vec![int_type_var(0)]); + let idiv_sig = int_polytype( + 2, + vec![int_type_var(1), int_type_var(1)], + vec![int_type_var(0)], + ); let imod_checked_sig = int_polytype( 2, From eb74e80af5878675815c30c21c8a6e5cdda444b7 Mon Sep 17 00:00:00 2001 From: Mark Koch Date: Mon, 27 Nov 2023 13:28:23 +0000 Subject: [PATCH 2/2] More fixes --- src/std_extensions/arithmetic/int_ops.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/std_extensions/arithmetic/int_ops.rs b/src/std_extensions/arithmetic/int_ops.rs index 422f7b2ab..cd9221deb 100644 --- a/src/std_extensions/arithmetic/int_ops.rs +++ b/src/std_extensions/arithmetic/int_ops.rs @@ -87,7 +87,7 @@ fn extension() -> Extension { let idiv_sig = int_polytype( 2, - vec![int_type_var(1), int_type_var(1)], + vec![int_type_var(0), int_type_var(1)], vec![int_type_var(0)], ); @@ -103,7 +103,11 @@ fn extension() -> Extension { vec![int_type_var(1)], ); - let ish_sig = int_polytype(2, vec![int_type_var(1)], vec![int_type_var(0)]); + let ish_sig = int_polytype( + 2, + vec![int_type_var(0), int_type_var(1)], + vec![int_type_var(0)], + ); let widen_poly = int_polytype(2, vec![int_type_var(0)], vec![int_type_var(1)]); let narrow_poly = int_polytype(