diff options
Diffstat (limited to 'sql/item_cmpfunc.cc')
-rw-r--r-- | sql/item_cmpfunc.cc | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/sql/item_cmpfunc.cc b/sql/item_cmpfunc.cc index 5852108dc43..4b9eb37488e 100644 --- a/sql/item_cmpfunc.cc +++ b/sql/item_cmpfunc.cc @@ -503,7 +503,7 @@ static bool convert_const_to_int(THD *thd, Item_field *field_item, if (0 == field_cmp) { Item *tmp= new Item_int_with_ref(field->val_int(), *item, - test(field->flags & UNSIGNED_FLAG)); + MY_TEST(field->flags & UNSIGNED_FLAG)); if (tmp) thd->change_item_tree(item, tmp); result= 1; // Item was replaced @@ -1044,8 +1044,8 @@ int Arg_comparator::compare_e_string() res1= (*a)->val_str(&value1); res2= (*b)->val_str(&value2); if (!res1 || !res2) - return test(res1 == res2); - return test(sortcmp(res1, res2, cmp_collation.collation) == 0); + return MY_TEST(res1 == res2); + return MY_TEST(sortcmp(res1, res2, cmp_collation.collation) == 0); } @@ -1055,8 +1055,8 @@ int Arg_comparator::compare_e_binary_string() res1= (*a)->val_str(&value1); res2= (*b)->val_str(&value2); if (!res1 || !res2) - return test(res1 == res2); - return test(stringcmp(res1, res2) == 0); + return MY_TEST(res1 == res2); + return MY_TEST(stringcmp(res1, res2) == 0); } @@ -1111,8 +1111,8 @@ int Arg_comparator::compare_e_real() double val1= (*a)->val_real(); double val2= (*b)->val_real(); if ((*a)->null_value || (*b)->null_value) - return test((*a)->null_value && (*b)->null_value); - return test(val1 == val2); + return MY_TEST((*a)->null_value && (*b)->null_value); + return MY_TEST(val1 == val2); } int Arg_comparator::compare_e_decimal() @@ -1121,8 +1121,8 @@ int Arg_comparator::compare_e_decimal() my_decimal *val1= (*a)->val_decimal(&decimal1); my_decimal *val2= (*b)->val_decimal(&decimal2); if ((*a)->null_value || (*b)->null_value) - return test((*a)->null_value && (*b)->null_value); - return test(my_decimal_cmp(val1, val2) == 0); + return MY_TEST((*a)->null_value && (*b)->null_value); + return MY_TEST(my_decimal_cmp(val1, val2) == 0); } @@ -1160,8 +1160,8 @@ int Arg_comparator::compare_e_real_fixed() double val1= (*a)->val_real(); double val2= (*b)->val_real(); if ((*a)->null_value || (*b)->null_value) - return test((*a)->null_value && (*b)->null_value); - return test(val1 == val2 || fabs(val1 - val2) < precision); + return MY_TEST((*a)->null_value && (*b)->null_value); + return MY_TEST(val1 == val2 || fabs(val1 - val2) < precision); } @@ -1272,8 +1272,8 @@ int Arg_comparator::compare_e_int() longlong val1= (*a)->val_int(); longlong val2= (*b)->val_int(); if ((*a)->null_value || (*b)->null_value) - return test((*a)->null_value && (*b)->null_value); - return test(val1 == val2); + return MY_TEST((*a)->null_value && (*b)->null_value); + return MY_TEST(val1 == val2); } /** @@ -1284,8 +1284,8 @@ int Arg_comparator::compare_e_int_diff_signedness() longlong val1= (*a)->val_int(); longlong val2= (*b)->val_int(); if ((*a)->null_value || (*b)->null_value) - return test((*a)->null_value && (*b)->null_value); - return (val1 >= 0) && test(val1 == val2); + return MY_TEST((*a)->null_value && (*b)->null_value); + return (val1 >= 0) && MY_TEST(val1 == val2); } int Arg_comparator::compare_row() |