mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
made changes according to the review, mostly removing unused code and fixing code to follow the coding conventions
This commit is contained in:
30
sql/item.h
30
sql/item.h
@ -5303,8 +5303,6 @@ public:
|
||||
/* Compare the cached value with the source value, without copying */
|
||||
virtual int cmp_read_only()=0;
|
||||
|
||||
virtual void clear()=0;
|
||||
|
||||
virtual ~Cached_item(); /*line -e1509 */
|
||||
};
|
||||
|
||||
@ -5322,11 +5320,6 @@ public:
|
||||
cmp();
|
||||
item= save;
|
||||
}
|
||||
|
||||
void clear()
|
||||
{
|
||||
null_value= false;
|
||||
}
|
||||
};
|
||||
|
||||
class Cached_item_str :public Cached_item_item
|
||||
@ -5337,10 +5330,6 @@ public:
|
||||
Cached_item_str(THD *thd, Item *arg);
|
||||
bool cmp(void);
|
||||
int cmp_read_only();
|
||||
void clear()
|
||||
{
|
||||
null_value= false;
|
||||
}
|
||||
~Cached_item_str(); // Deallocate String:s
|
||||
};
|
||||
|
||||
@ -5353,11 +5342,6 @@ public:
|
||||
bool cmp(void);
|
||||
int cmp_read_only();
|
||||
double get_value(){ return value;}
|
||||
void clear()
|
||||
{
|
||||
value=0.0;
|
||||
null_value= false;
|
||||
}
|
||||
};
|
||||
|
||||
class Cached_item_int :public Cached_item_item
|
||||
@ -5368,11 +5352,6 @@ public:
|
||||
bool cmp(void);
|
||||
int cmp_read_only();
|
||||
longlong get_value(){ return value;}
|
||||
void clear()
|
||||
{
|
||||
value=0.0;
|
||||
null_value= false;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@ -5384,11 +5363,6 @@ public:
|
||||
bool cmp(void);
|
||||
int cmp_read_only();
|
||||
my_decimal *get_value(){ return &value;};
|
||||
void clear()
|
||||
{
|
||||
null_value= false;
|
||||
my_decimal_set_zero(&value);
|
||||
}
|
||||
};
|
||||
|
||||
class Cached_item_field :public Cached_item
|
||||
@ -5406,10 +5380,6 @@ public:
|
||||
}
|
||||
bool cmp(void);
|
||||
int cmp_read_only();
|
||||
void clear()
|
||||
{
|
||||
null_value= false;
|
||||
}
|
||||
};
|
||||
|
||||
class Item_default_value : public Item_field
|
||||
|
@ -31,8 +31,6 @@ class Group_bound_tracker
|
||||
public:
|
||||
|
||||
Group_bound_tracker(THD *thd, SQL_I_List<ORDER> *list)
|
||||
{
|
||||
if (list)
|
||||
{
|
||||
for (ORDER *curr = list->first; curr; curr=curr->next)
|
||||
{
|
||||
@ -40,13 +38,6 @@ public:
|
||||
group_fields.push_back(tmp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Group_bound_tracker(THD *thd, Item *item)
|
||||
{
|
||||
Cached_item *tmp= new_Cached_item(thd, item, FALSE);
|
||||
group_fields.push_back(tmp);
|
||||
}
|
||||
|
||||
void init()
|
||||
{
|
||||
@ -96,19 +87,6 @@ public:
|
||||
return 0;
|
||||
}
|
||||
|
||||
bool compare_with_cache_for_null_values()
|
||||
{
|
||||
List_iterator<Cached_item> li(group_fields);
|
||||
Cached_item *ptr;
|
||||
while ((ptr= li++))
|
||||
{
|
||||
ptr->cmp();
|
||||
if (ptr->null_value)
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private:
|
||||
List<Cached_item> group_fields;
|
||||
/*
|
||||
|
@ -968,10 +968,6 @@ public:
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
bool check_for_end_of_partition()
|
||||
{
|
||||
return end_of_partition;
|
||||
}
|
||||
|
||||
private:
|
||||
Group_bound_tracker bound_tracker;
|
||||
@ -1078,6 +1074,7 @@ protected:
|
||||
{
|
||||
if (perform_no_action)
|
||||
return;
|
||||
|
||||
List_iterator_fast<Item_sum> it(sum_functions);
|
||||
Item_sum *item_sum;
|
||||
while ((item_sum= it++))
|
||||
@ -1747,9 +1744,7 @@ public:
|
||||
|
||||
/* Walk to the end of the partition, find how many rows there are. */
|
||||
while (!cursor.next())
|
||||
{
|
||||
num_rows_in_partition++;
|
||||
}
|
||||
|
||||
List_iterator_fast<Item_sum> it(sum_functions);
|
||||
Item_sum* item;
|
||||
@ -1805,6 +1800,7 @@ public:
|
||||
{
|
||||
return cursor.get_rownum();
|
||||
}
|
||||
|
||||
private:
|
||||
Item* order_item;
|
||||
};
|
||||
|
@ -10191,6 +10191,11 @@ geometry_function:
|
||||
Item_func_spatial_precise_rel(thd, $3, $5,
|
||||
Item_func::SP_CONTAINS_FUNC));
|
||||
}
|
||||
| WITHIN '(' expr ',' expr ')'
|
||||
{
|
||||
$$= GEOM_NEW(thd, Item_func_spatial_precise_rel(thd, $3, $5,
|
||||
Item_func::SP_WITHIN_FUNC));
|
||||
}
|
||||
| GEOMETRYCOLLECTION '(' expr_list ')'
|
||||
{
|
||||
$$= GEOM_NEW(thd,
|
||||
@ -10237,6 +10242,7 @@ geometry_function:
|
||||
Geometry::wkb_polygon,
|
||||
Geometry::wkb_linestring));
|
||||
}
|
||||
|
||||
;
|
||||
|
||||
/*
|
||||
@ -14628,6 +14634,7 @@ keyword:
|
||||
| UNICODE_SYM {}
|
||||
| UNINSTALL_SYM {}
|
||||
| UNBOUNDED_SYM {}
|
||||
| WITHIN
|
||||
| WRAPPER_SYM {}
|
||||
| XA_SYM {}
|
||||
| UPGRADE_SYM {}
|
||||
|
Reference in New Issue
Block a user