|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r83081 - sandbox/tuple-move/libs/tuple/test
From: adam.wulkiewicz_at_[hidden]
Date: 2013-02-22 07:32:38
Author: awulkiew
Date: 2013-02-22 07:32:37 EST (Fri, 22 Feb 2013)
New Revision: 83081
URL: http://svn.boost.org/trac/boost/changeset/83081
Log:
tuple-move test added
Text files modified:
sandbox/tuple-move/libs/tuple/test/tuple_move.cpp | 25 +++++++++++++++++++++++++
1 files changed, 25 insertions(+), 0 deletions(-)
Modified: sandbox/tuple-move/libs/tuple/test/tuple_move.cpp
==============================================================================
--- sandbox/tuple-move/libs/tuple/test/tuple_move.cpp (original)
+++ sandbox/tuple-move/libs/tuple/test/tuple_move.cpp 2013-02-22 07:32:37 EST (Fri, 22 Feb 2013)
@@ -32,6 +32,17 @@
state_type last;
};
+struct foo
+{
+ boost::tuple<int> t;
+};
+
+template <typename T>
+struct foot
+{
+ boost::tuple<T> t;
+};
+
int test_main(int, char* [])
{
using namespace boost;
@@ -221,6 +232,20 @@
ti = boost::move(cpf);
BOOST_CHECK(get<0>(ti).last_op() == cm::copy_assign);
+ {
+ foo a, b;
+ a = b;
+ }
+
+ {
+ foot<cm> a, b;
+ a = b;
+ BOOST_CHECK(get<0>(a.t).last_op() == cm::copy_assign);
+ a = boost::move(b);
+ BOOST_CHECK(get<0>(a.t).last_op() == cm::copy_assign);
+ }
+
+
return 0;
}
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk