mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-23 20:15:05 +02:00
More fixes for the same reversal bug
This commit is contained in:
parent
8f14fd3328
commit
5a8cdc3518
1 changed files with 3 additions and 3 deletions
|
@ -2342,7 +2342,7 @@ object Cyc_fast_sum(void *data, object ptr, object x, object y) {
|
|||
// x is double
|
||||
if (is_object_type(x) && type_of(x) == double_tag) {
|
||||
if (obj_is_int(y)){
|
||||
assign_double(ptr, (double)(obj_obj2int(y)) + double_value(x));
|
||||
assign_double(ptr, double_value(x) + (double)(obj_obj2int(y)));
|
||||
return ptr;
|
||||
} else if (is_object_type(y) && type_of(y) == double_tag) {
|
||||
assign_double(ptr, double_value(x) + double_value(y));
|
||||
|
@ -2372,7 +2372,7 @@ object Cyc_fast_sub(void *data, object ptr, object x, object y) {
|
|||
// x is double
|
||||
if (is_object_type(x) && type_of(x) == double_tag) {
|
||||
if (obj_is_int(y)){
|
||||
assign_double(ptr, (double)(obj_obj2int(y)) - double_value(x));
|
||||
assign_double(ptr, double_value(x) - (double)(obj_obj2int(y)));
|
||||
return ptr;
|
||||
} else if (is_object_type(y) && type_of(y) == double_tag) {
|
||||
assign_double(ptr, double_value(x) - double_value(y));
|
||||
|
@ -2402,7 +2402,7 @@ object Cyc_fast_mul(void *data, object ptr, object x, object y) {
|
|||
// x is double
|
||||
if (is_object_type(x) && type_of(x) == double_tag) {
|
||||
if (obj_is_int(y)){
|
||||
assign_double(ptr, (double)(obj_obj2int(y)) * double_value(x));
|
||||
assign_double(ptr, double_value(x) * (double)(obj_obj2int(y)));
|
||||
return ptr;
|
||||
} else if (is_object_type(y) && type_of(y) == double_tag) {
|
||||
assign_double(ptr, double_value(x) * double_value(y));
|
||||
|
|
Loading…
Add table
Reference in a new issue