Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r73642 - trunk/libs/fusion/test/algorithm
From: joel_at_[hidden]
Date: 2011-08-10 18:01:38


Author: djowel
Date: 2011-08-10 18:01:37 EDT (Wed, 10 Aug 2011)
New Revision: 73642
URL: http://svn.boost.org/trac/boost/changeset/73642

Log:
Added pop_back test for lists
Text files modified:
   trunk/libs/fusion/test/algorithm/pop_back.cpp | 10 +++++++++-
   1 files changed, 9 insertions(+), 1 deletions(-)

Modified: trunk/libs/fusion/test/algorithm/pop_back.cpp
==============================================================================
--- trunk/libs/fusion/test/algorithm/pop_back.cpp (original)
+++ trunk/libs/fusion/test/algorithm/pop_back.cpp 2011-08-10 18:01:37 EDT (Wed, 10 Aug 2011)
@@ -1,15 +1,17 @@
 /*=============================================================================
     Copyright (c) 2001-2006 Joel de Guzman
 
- Distributed under the Boost Software License, Version 1.0. (See accompanying
+ Distributed under the Boost Software License, Version 1.0. (See accompanying
     file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
 ==============================================================================*/
 #include <boost/detail/lightweight_test.hpp>
 #include <boost/fusion/container/vector/vector.hpp>
+#include <boost/fusion/container/list/list.hpp>
 #include <boost/fusion/adapted/mpl.hpp>
 #include <boost/fusion/sequence/io/out.hpp>
 #include <boost/fusion/sequence/comparison/equal_to.hpp>
 #include <boost/fusion/container/generation/make_vector.hpp>
+#include <boost/fusion/container/generation/make_list.hpp>
 #include <boost/fusion/algorithm/transformation/pop_back.hpp>
 #include <boost/mpl/vector_c.hpp>
 
@@ -41,6 +43,12 @@
         BOOST_TEST((boost::fusion::pop_back(mpl_vec()) == make_vector(1, 2, 3, 4)));
     }
 
+ {
+ list<int, int> l(1, 2);
+ std::cout << pop_back(l) << std::endl;
+ BOOST_TEST((pop_back(l) == make_list(1)));
+ }
+
     return boost::report_errors();
 }
 


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