Removed unnecessary integer_type usage

This commit is contained in:
Justin Ethier 2017-01-30 17:35:10 -05:00
parent 9b2a084160
commit be542b745f

View file

@ -1046,9 +1046,6 @@
" Cyc_check_num(data, num); " Cyc_check_num(data, num);
if (obj_is_int(num)) { if (obj_is_int(num)) {
return_closcall1(data, k, obj_int2obj( abs( obj_obj2int(num)))); return_closcall1(data, k, obj_int2obj( abs( obj_obj2int(num))));
} else if (type_of(num) == integer_tag) {
object obj = obj_int2obj(abs(((integer_type *)num)->value));
return_closcall1(data, k, obj);
} else { } else {
make_double(d, fabs(((double_type *)num)->value)); make_double(d, fabs(((double_type *)num)->value));
return_closcall1(data, k, &d); return_closcall1(data, k, &d);
@ -1061,15 +1058,11 @@
Cyc_check_num(data, num2); Cyc_check_num(data, num2);
if (obj_is_int(num1)) { if (obj_is_int(num1)) {
i = obj_obj2int(num1); i = obj_obj2int(num1);
} else if (type_of(num1) == integer_tag) {
i = ((integer_type *)num1)->value;
} else /* Must be double: if (type_of(num1) == double_tag)*/ { } else /* Must be double: if (type_of(num1) == double_tag)*/ {
i = ((double_type *)num1)->value; i = ((double_type *)num1)->value;
} }
if (obj_is_int(num2)) { if (obj_is_int(num2)) {
j = obj_obj2int(num2); j = obj_obj2int(num2);
} else if (type_of(num2) == integer_tag) {
j = ((integer_type *)num2)->value;
} else /* Must be double: if (type_of(num2) == double_tag)*/ { } else /* Must be double: if (type_of(num2) == double_tag)*/ {
j = ((double_type *)num2)->value; j = ((double_type *)num2)->value;
} }