Fixing divdu by constant -1.
This commit is contained in:
@@ -308,16 +308,16 @@ void Value::Div(Value* other) {
|
||||
assert_true(type == other->type);
|
||||
switch (type) {
|
||||
case INT8_TYPE:
|
||||
constant.i8 /= other->constant.i8;
|
||||
constant.i8 /= uint8_t(other->constant.i8);
|
||||
break;
|
||||
case INT16_TYPE:
|
||||
constant.i16 /= other->constant.i16;
|
||||
constant.i16 /= uint16_t(other->constant.i16);
|
||||
break;
|
||||
case INT32_TYPE:
|
||||
constant.i32 /= other->constant.i32;
|
||||
constant.i32 /= uint32_t(other->constant.i32);
|
||||
break;
|
||||
case INT64_TYPE:
|
||||
constant.i64 /= other->constant.i64;
|
||||
constant.i64 /= uint64_t(other->constant.i64);
|
||||
break;
|
||||
case FLOAT32_TYPE:
|
||||
constant.f32 /= other->constant.f32;
|
||||
|
||||
Reference in New Issue
Block a user