diff options
author | unknown <kostja@bodhi.(none)> | 2008-05-20 11:38:17 +0400 |
---|---|---|
committer | unknown <kostja@bodhi.(none)> | 2008-05-20 11:38:17 +0400 |
commit | 4175806efca7644c41ab77e5a8f07d1cc5a1ac00 (patch) | |
tree | c2c65314fdd8ac05f82de10701ce5eb6a9856e11 /sql/my_decimal.h | |
parent | 41116166257e92df96c394035c8b580e48626b00 (diff) | |
parent | 4b13b5cb34de81942d52173663031fb119d5b8e1 (diff) | |
download | mariadb-git-4175806efca7644c41ab77e5a8f07d1cc5a1ac00.tar.gz |
Merge bk-internal.mysql.com:/home/bk/mysql-5.1
into bodhi.(none):/opt/local/work/mysql-5.1-27430
Makefile.am:
Auto merged
include/my_global.h:
Auto merged
mysql-test/include/mix1.inc:
Auto merged
sql/item.cc:
Auto merged
sql/my_decimal.h:
Auto merged
sql/mysqld.cc:
Auto merged
sql/set_var.cc:
Auto merged
sql/set_var.h:
Auto merged
sql/sp.cc:
Auto merged
sql/sp_head.cc:
Auto merged
sql/sql_base.cc:
Auto merged
sql/sql_class.cc:
Auto merged
sql/sql_class.h:
Auto merged
sql/sql_parse.cc:
Auto merged
sql/sql_table.cc:
Auto merged
sql/sql_update.cc:
Auto merged
sql/share/errmsg.txt:
Auto merged
sql/sql_yacc.yy:
Auto merged
libmysqld/CMakeLists.txt:
Manual merge.
libmysqld/lib_sql.cc:
Manual merge.
mysql-test/t/disabled.def:
Manual merge.
Diffstat (limited to 'sql/my_decimal.h')
-rw-r--r-- | sql/my_decimal.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sql/my_decimal.h b/sql/my_decimal.h index e73e0d4080d..0e79f70ab4e 100644 --- a/sql/my_decimal.h +++ b/sql/my_decimal.h @@ -114,6 +114,14 @@ public: bool sign() const { return decimal_t::sign; } void sign(bool s) { decimal_t::sign= s; } uint precision() const { return intg + frac; } + + /** Swap two my_decimal values */ + void swap(my_decimal &rhs) + { + swap_variables(my_decimal, *this, rhs); + /* Swap the buffer pointers back */ + swap_variables(decimal_digit_t *, buf, rhs.buf); + } }; |