hm-inference #6

Merged
sb10q merged 136 commits from hm-inference into master 2021-08-19 11:46:50 +08:00
1 changed files with 1 additions and 31 deletions
Showing only changes of commit d4807293b0 - Show all commits

View File

@ -333,69 +333,39 @@ pub fn set_primirives_magic_methods(store: &PrimitiveStore, unifier: &mut Unifie
int64: int64_t, int64: int64_t,
float: float_t, float: float_t,
bool: bool_t, bool: bool_t,
none: _none_t ..
} = *store; } = *store;
/* int32 ======== */ /* int32 ======== */
impl_basic_arithmetic(unifier, store, int32_t, int32_t, int32_t); impl_basic_arithmetic(unifier, store, int32_t, int32_t, int32_t);
// impl_basic_arithmetic(unifier, store, int32_t, int64_t, int64_t);
// impl_basic_arithmetic(unifier, store, int32_t, float_t, float_t);
impl_bitwise_arithmetic(unifier, store, int32_t); impl_bitwise_arithmetic(unifier, store, int32_t);
// impl_div(unifier, store, int32_t, int32_t);
// impl_div(unifier, store, int32_t, int64_t);
impl_div(unifier, store, int32_t, int32_t); impl_div(unifier, store, int32_t, int32_t);
impl_floordiv(unifier, store, int32_t, int32_t, int32_t); impl_floordiv(unifier, store, int32_t, int32_t, int32_t);
// impl_floordiv(unifier, store, int32_t, int64_t, int32_t);
// impl_floordiv(unifier, store, int32_t, float_t, float_t);
impl_mod(unifier, store, int32_t, int32_t, int32_t); impl_mod(unifier, store, int32_t, int32_t, int32_t);
// impl_mod(unifier, store, int32_t, int64_t, int32_t);
// impl_mod(unifier, store, int32_t, float_t, float_t);
impl_unary_op(unifier, store, int32_t); impl_unary_op(unifier, store, int32_t);
impl_invert(unifier, store, int32_t); impl_invert(unifier, store, int32_t);
impl_not(unifier, store, int32_t); impl_not(unifier, store, int32_t);
impl_comparison(unifier, store, int32_t, int32_t); impl_comparison(unifier, store, int32_t, int32_t);
// impl_comparison(unifier, store, int32_t, int64_t);
// impl_comparison(unifier, store, int32_t, float_t);
impl_eq(unifier, store, int32_t); impl_eq(unifier, store, int32_t);
/* int64 ======== */ /* int64 ======== */
// impl_basic_arithmetic(unifier, store, int64_t, int32_t, int64_t);
impl_basic_arithmetic(unifier, store, int64_t, int64_t, int64_t); impl_basic_arithmetic(unifier, store, int64_t, int64_t, int64_t);
// impl_basic_arithmetic(unifier, store, int64_t, float_t, float_t);
impl_bitwise_arithmetic(unifier, store, int64_t); impl_bitwise_arithmetic(unifier, store, int64_t);
// impl_div(unifier, store, int64_t, int32_t);
impl_div(unifier, store, int64_t, int64_t); impl_div(unifier, store, int64_t, int64_t);
// impl_div(unifier, store, int64_t, float_t);
// impl_floordiv(unifier, store, int64_t, int32_t, int64_t);
impl_floordiv(unifier, store, int64_t, int64_t, int64_t); impl_floordiv(unifier, store, int64_t, int64_t, int64_t);
// impl_floordiv(unifier, store, int64_t, float_t, float_t);
// impl_mod(unifier, store, int64_t, int32_t, int64_t);
impl_mod(unifier, store, int64_t, int64_t, int64_t); impl_mod(unifier, store, int64_t, int64_t, int64_t);
// impl_mod(unifier, store, int64_t, float_t, float_t);
impl_unary_op(unifier, store, int64_t); impl_unary_op(unifier, store, int64_t);
impl_invert(unifier, store, int64_t); impl_invert(unifier, store, int64_t);
impl_not(unifier, store, int64_t); impl_not(unifier, store, int64_t);
// impl_comparison(unifier, store, int64_t, int32_t);
impl_comparison(unifier, store, int64_t, int64_t); impl_comparison(unifier, store, int64_t, int64_t);
// impl_comparison(unifier, store, int64_t, float_t);
impl_eq(unifier, store, int64_t); impl_eq(unifier, store, int64_t);
/* float ======== */ /* float ======== */
// impl_basic_arithmetic(unifier, store, float_t, int32_t, float_t);
// impl_basic_arithmetic(unifier, store, float_t, int64_t, float_t);
impl_basic_arithmetic(unifier, store, float_t, float_t, float_t); impl_basic_arithmetic(unifier, store, float_t, float_t, float_t);
// impl_div(unifier, store, float_t, int32_t);
// impl_div(unifier, store, float_t, int64_t);
impl_div(unifier, store, float_t, float_t); impl_div(unifier, store, float_t, float_t);
// impl_floordiv(unifier, store, float_t, int32_t, float_t);
// impl_floordiv(unifier, store, float_t, int64_t, float_t);
impl_floordiv(unifier, store, float_t, float_t, float_t); impl_floordiv(unifier, store, float_t, float_t, float_t);
// impl_mod(unifier, store, float_t, int32_t, float_t);
// impl_mod(unifier, store, float_t, int64_t, float_t);
impl_mod(unifier, store, float_t, float_t, float_t); impl_mod(unifier, store, float_t, float_t, float_t);
impl_unary_op(unifier, store, float_t); impl_unary_op(unifier, store, float_t);
impl_not(unifier, store, float_t); impl_not(unifier, store, float_t);
// impl_comparison(unifier, store, float_t, int32_t);
// impl_comparison(unifier, store, float_t, int64_t);
impl_comparison(unifier, store, float_t, float_t); impl_comparison(unifier, store, float_t, float_t);
impl_eq(unifier, store, float_t); impl_eq(unifier, store, float_t);