diff options
author | unknown <malff/marcsql@weblab.(none)> | 2007-08-30 17:23:40 -0600 |
---|---|---|
committer | unknown <malff/marcsql@weblab.(none)> | 2007-08-30 17:23:40 -0600 |
commit | 3f9be28c41832ef87e0832476780e6b3c1d1749e (patch) | |
tree | 00bcf2b19fee762a68dc643dafacd013f9bf9e3a /sql/item_cmpfunc.h | |
parent | 7388ea3c56a268387e60fc28b671d664ecfa8ad4 (diff) | |
parent | bccbd5c493a5350a7dd36e0349f2ad6d05863e89 (diff) | |
download | mariadb-git-3f9be28c41832ef87e0832476780e6b3c1d1749e.tar.gz |
Merge weblab.(none):/home/marcsql/TREE/mysql-5.0-base
into weblab.(none):/home/marcsql/TREE/mysql-5.0-runtime
sql/item_cmpfunc.h:
Auto merged
sql/sql_lex.cc:
Auto merged
Diffstat (limited to 'sql/item_cmpfunc.h')
-rw-r--r-- | sql/item_cmpfunc.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/sql/item_cmpfunc.h b/sql/item_cmpfunc.h index 7b6eaef08ec..8410c66b034 100644 --- a/sql/item_cmpfunc.h +++ b/sql/item_cmpfunc.h @@ -1361,6 +1361,7 @@ public: Item_cond(List<Item> &nlist) :Item_bool_func(), list(nlist), abort_on_null(0) {} bool add(Item *item) { return list.push_back(item); } + bool add_at_head(Item *item) { return list.push_front(item); } void add_at_head(List<Item> *nlist) { list.prepand(nlist); } bool fix_fields(THD *, Item **ref); @@ -1553,6 +1554,15 @@ public: Item *neg_transformer(THD *thd); }; +inline bool is_cond_and(Item *item) +{ + if (item->type() != Item::COND_ITEM) + return FALSE; + + Item_cond *cond_item= (Item_cond*) item; + return (cond_item->functype() == Item_func::COND_AND_FUNC); +} + class Item_cond_or :public Item_cond { public: @@ -1574,6 +1584,14 @@ public: Item *neg_transformer(THD *thd); }; +inline bool is_cond_or(Item *item) +{ + if (item->type() != Item::COND_ITEM) + return FALSE; + + Item_cond *cond_item= (Item_cond*) item; + return (cond_item->functype() == Item_func::COND_OR_FUNC); +} /* XOR is Item_cond, not an Item_int_func because we could like to |