diff options
author | Michael Widenius <monty@askmonty.org> | 2013-06-16 21:26:40 +0300 |
---|---|---|
committer | Michael Widenius <monty@askmonty.org> | 2013-06-16 21:26:40 +0300 |
commit | 8075b05b7dc03f67abc7c7a3d788dcf87b3483c9 (patch) | |
tree | e692658d2942b85bfcc7ca01eb6b61b06caf370e /sql/sql_array.h | |
parent | 7c1abe151c88d0f1cf7bad0a856b554a2fdec83a (diff) | |
download | mariadb-git-8075b05b7dc03f67abc7c7a3d788dcf87b3483c9.tar.gz |
More merge fixes:
- mdl.cc and mdl.h merged completely
- mysql_system_tables*.sql merged completely
- Fixed wrong merge of lock_tables
- Added some missing functions:
- bool THD::notify_shared_lock()
- Dynamic_array::pop, Dynamic_array::del
- Added MDL_context_owner to THD
- Added metadata_locks_hash_instances
Diffstat (limited to 'sql/sql_array.h')
-rw-r--r-- | sql/sql_array.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sql/sql_array.h b/sql/sql_array.h index f07126bc0ef..9ac27cca63b 100644 --- a/sql/sql_array.h +++ b/sql/sql_array.h @@ -124,6 +124,17 @@ public: return (insert_dynamic(&array, (uchar*)&el)); } + /// Pops the last element. Does nothing if array is empty. + Elem& pop() + { + return *((Elem*)pop_dynamic(&array)); + } + + void del(uint idx) + { + delete_dynamic_element(&array, idx); + } + int elements() { return array.elements; |