Commit 366cda49 authored by Alexander Barkov's avatar Alexander Barkov

Adding "const" qualifier into a few methods in Field.

parent 091f6773
......@@ -10210,6 +10210,7 @@ Field::set_warning(Sql_condition::enum_warning_level level, uint code,
void Field::set_datetime_warning(Sql_condition::enum_warning_level level,
uint code, const ErrConv *str,
timestamp_type ts_type, int cuted_increment)
const
{
THD *thd= get_thd();
if (thd->really_abort_on_warning() && level >= Sql_condition::WARN_LEVEL_WARN)
......
......@@ -727,7 +727,7 @@ class Field
null_bit= p_null_bit;
}
inline THD *get_thd() { return table ? table->in_use : current_thd; }
inline THD *get_thd() const { return table ? table->in_use : current_thd; }
enum {
LAST_NULL_BYTE_UNDEF= 0
......@@ -897,7 +897,7 @@ class Field
int cuted_increment) const;
void set_datetime_warning(Sql_condition::enum_warning_level, uint code,
const ErrConv *str, timestamp_type ts_type,
int cuted_increment);
int cuted_increment) const;
inline bool check_overflow(int op_result)
{
return (op_result == E_DEC_OVERFLOW);
......@@ -1682,7 +1682,7 @@ class Field_temporal_with_date: public Field_temporal {
int was_cut, int have_smth_to_conv);
virtual void store_TIME(MYSQL_TIME *ltime) = 0;
bool validate_for_get_date(bool not_zero_date, const MYSQL_TIME *ltime,
ulonglong fuzzydate)
ulonglong fuzzydate) const
{
if (!not_zero_date)
return fuzzydate & TIME_NO_ZERO_DATE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment