mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
MDEV-12826 Add Type_handler::val_int_signed_typecast() and Type_handler::val_int_unsigned_typecast()
This commit is contained in:
@ -2976,6 +2976,70 @@ bool Type_handler_geometry::
|
||||
#endif
|
||||
|
||||
|
||||
/*************************************************************************/
|
||||
|
||||
longlong Type_handler_real_result::
|
||||
Item_val_int_signed_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_int_result::
|
||||
Item_val_int_signed_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_decimal_result::
|
||||
Item_val_int_signed_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_temporal_result::
|
||||
Item_val_int_signed_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_string_result::
|
||||
Item_val_int_signed_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int_signed_typecast_from_str();
|
||||
}
|
||||
|
||||
/*************************************************************************/
|
||||
|
||||
longlong Type_handler_real_result::
|
||||
Item_val_int_unsigned_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int_unsigned_typecast_from_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_int_result::
|
||||
Item_val_int_unsigned_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int_unsigned_typecast_from_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_decimal_result::
|
||||
Item_val_int_unsigned_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int_unsigned_typecast_from_decimal();
|
||||
}
|
||||
|
||||
longlong Type_handler_temporal_result::
|
||||
Item_val_int_unsigned_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int_unsigned_typecast_from_int();
|
||||
}
|
||||
|
||||
longlong Type_handler_string_result::
|
||||
Item_val_int_unsigned_typecast(Item *item) const
|
||||
{
|
||||
return item->val_int_unsigned_typecast_from_str();
|
||||
}
|
||||
|
||||
/*************************************************************************/
|
||||
|
||||
String *
|
||||
|
Reference in New Issue
Block a user