summaryrefslogtreecommitdiff
path: root/sql/item_geofunc.h
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.org>2015-10-04 09:37:57 +0400
committerAlexander Barkov <bar@mariadb.org>2015-10-04 09:37:57 +0400
commitba0b6685510f4a271da8d386ff75bfd83d3156c2 (patch)
tree99448a9d70e6ec59074aba5240a27e7eb102b423 /sql/item_geofunc.h
parent100d77e69d8af37909b3e29c8299e2c3792c8b1b (diff)
downloadmariadb-git-ba0b6685510f4a271da8d386ff75bfd83d3156c2.tar.gz
A clean-up for MDEV-7950:
- Turning get_mm_tree_for_const() from a static function into a protected method in Item. - Adding a new class Item_bool_func2_with_rev, for the functions and operators that have a reverse function and can use the range optimizer for to optimize "value OP field" as "field REV_OP value". Deriving Item_bool_rowready_func2 and Item_funt_spatial_rel from the new class. - Removing Item_bool_func2::have_rev_func().
Diffstat (limited to 'sql/item_geofunc.h')
-rw-r--r--sql/item_geofunc.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/item_geofunc.h b/sql/item_geofunc.h
index 2379e6184d1..b72661fe054 100644
--- a/sql/item_geofunc.h
+++ b/sql/item_geofunc.h
@@ -275,7 +275,7 @@ public:
Spatial relations
*/
-class Item_func_spatial_rel: public Item_bool_func2
+class Item_func_spatial_rel: public Item_bool_func2_with_rev
{
protected:
enum Functype spatial_rel;
@@ -285,7 +285,7 @@ protected:
Item_func::Functype type, Item *value);
public:
Item_func_spatial_rel(THD *thd, Item *a, Item *b, enum Functype sp_rel):
- Item_bool_func2(thd, a, b), spatial_rel(sp_rel)
+ Item_bool_func2_with_rev(thd, a, b), spatial_rel(sp_rel)
{
maybe_null= true;
}