|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r63065 - in sandbox/chrono/boost/conversion: . boost std
From: vicente.botet_at_[hidden]
Date: 2010-06-17 17:11:21
Author: viboes
Date: 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
New Revision: 63065
URL: http://svn.boost.org/trac/boost/changeset/63065
Log:
Add Conversion lib on Chrono
Added:
sandbox/chrono/boost/conversion/
sandbox/chrono/boost/conversion/assign_to.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/
sandbox/chrono/boost/conversion/boost/array.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/chrono_duration_to_posix_time_duration.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/chrono_posix_time.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/chrono_time_point_to_posix_time_ptime.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/interval.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/optional.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/rational.hpp (contents, props changed)
sandbox/chrono/boost/conversion/boost/tuple.hpp (contents, props changed)
sandbox/chrono/boost/conversion/ca_wrapper.hpp (contents, props changed)
sandbox/chrono/boost/conversion/convert_to.hpp (contents, props changed)
sandbox/chrono/boost/conversion/convert_to_via.hpp (contents, props changed)
sandbox/chrono/boost/conversion/pack.hpp (contents, props changed)
sandbox/chrono/boost/conversion/std/
sandbox/chrono/boost/conversion/std/complex.hpp (contents, props changed)
sandbox/chrono/boost/conversion/std/pair.hpp (contents, props changed)
sandbox/chrono/boost/conversion/std/string.hpp (contents, props changed)
sandbox/chrono/boost/conversion/std/vector.hpp (contents, props changed)
Added: sandbox/chrono/boost/conversion/assign_to.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/assign_to.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,65 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERSION_ASSIGN_TO__HPP
+#define BOOST_CONVERSION_ASSIGN_TO__HPP
+
+#include <cstddef> //for std::size_t
+#include <boost/conversion/convert_to.hpp>
+
+namespace boost {
+ namespace conversion {
+ namespace partial_specialization_workaround {
+ template < typename To, typename From >
+ struct assign_to {
+ inline static To& apply(To& to, const From& from)
+ {
+ to = from;
+ return to;
+ }
+ };
+ template < typename To, typename From, std::size_t N >
+ struct assign_to<To[N],From[N]> {
+ inline static To*& apply(To(&to)[N], const From(& from)[N])
+ {
+ for (std::size_t i = 0; i < N; ++i)
+ {
+ to[i] = boost::convert_to<To>(from[i]);
+ }
+ return to;
+ }
+ };
+ }
+
+ template < typename To, typename From >
+ To& assign_to(To& to, const From& from, dummy::type_tag<To> const&) {
+ return conversion::partial_specialization_workaround::assign_to<To,From>::apply(to, from);
+ }
+ }
+
+ namespace conversion_impl {
+ template <typename Target, typename Source>
+ Target& assign_to_impl(Target& to, const Source& from) {
+ using namespace boost::conversion;
+ //use boost::conversion::assign_to if ADL fails
+ return assign_to(to, from, boost::dummy::type_tag<Target>());
+ }
+ }
+
+ template <typename Target, typename Source>
+ Target& assign_to(Target& to, const Source& from, boost::dummy::base_tag<Target> const& p=boost::dummy::base_tag<Target>()) {
+ return conversion_impl::assign_to_impl<Target, Source>(to, from);
+ }
+}
+
+
+
+#endif
+
Added: sandbox/chrono/boost/conversion/boost/array.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/array.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,69 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_ARRAY__HPP
+#define BOOST_CONVERT_TO_ARRAY__HPP
+
+#include <boost/array.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <algorithm>
+#include <boost/config.hpp>
+
+namespace boost {
+
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < typename T1, typename T2, std::size_t N>
+ struct convert_to< array<T1,N>, array<T2,N> > {
+ inline static array<T1,N> apply(array<T2,N> const & from)
+ {
+ array<T1,N> to;
+ boost::assign_to(to, from);
+ return to;
+ }
+ };
+ template < typename T1, typename T2, std::size_t N>
+ struct assign_to< array<T1,N>, array<T2,N> > {
+ inline static array<T1,N>& apply(array<T1,N>& to, array<T2,N> const & from)
+ {
+ for (unsigned int i =0; i<N; ++i) {
+ to[i]=boost::convert_to<T1>(from[i]);
+ }
+ return to;
+ }
+ };
+ }}
+ #else
+ template < typename T1, typename T2, std::size_t N>
+ inline array<T1,N> convert_to(array<T2,N> const & from
+ , boost::dummy::type_tag<array<T1,N> > const&
+ )
+ {
+ array<T1,N> to;
+ boost::assign_to(to, from);
+ return to;
+ }
+
+ template < typename T1, typename T2, std::size_t N>
+ inline array<T1,N>& assign_to(array<T1,N>& to, array<T2,N> const & from
+ , boost::dummy::type_tag<array<T1,N> > const&
+ )
+ {
+ for (unsigned int i =0; i<N; ++i) {
+ to[i]=boost::convert_to<T1>(from[i]);
+ }
+ return to;
+ }
+ #endif
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/boost/chrono_duration_to_posix_time_duration.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/chrono_duration_to_posix_time_duration.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,118 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_CHRONO_DURATION_TO_POSIX_TIME_DURATION__HPP
+#define BOOST_CONVERT_TO_CHRONO_DURATION_TO_POSIX_TIME_DURATION__HPP
+
+#include <boost/chrono/chrono.hpp>
+#include <boost/date_time/posix_time/posix_time_types.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/config.hpp>
+
+namespace boost {
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < class Rep, class Period>
+ struct convert_to<posix_time::time_duration, chrono::duration<Rep, Period> > {
+ inline static posix_time::time_duration apply(chrono::duration<Rep, Period> const & from)
+ {
+ typedef chrono::duration<Rep, Period> src_duration_t;
+ typedef chrono::nanoseconds duration_t;
+ typedef duration_t::rep rep_t;
+ rep_t d = chrono::duration_cast<duration_t>(from).count();
+ rep_t sec = d/1000000000;
+ rep_t nsec = d%1000000000;
+ return posix_time::seconds(static_cast<long>(sec))+
+#ifdef BOOST_DATE_TIME_HAS_NANOSECONDS
+ posix_time::nanoseconds(nsec);
+#else
+ posix_time::microseconds((nsec+500)/1000);
+#endif
+ }
+ };
+ template < class Rep, class Period>
+ struct assign_to<posix_time::time_duration, chrono::duration<Rep, Period> > {
+ inline static posix_time::time_duration& apply(posix_time::time_duration& to, const chrono::duration<Rep, Period>& from)
+ {
+ to = boost::convert_to<posix_time::time_duration>(from);
+ return to;
+ }
+ };
+
+ template < class Rep, class Period>
+ struct convert_to<chrono::duration<Rep, Period>, posix_time::time_duration> {
+ inline static chrono::duration<Rep, Period> apply(posix_time::time_duration const & from)
+ {
+ return chrono::duration_cast<chrono::duration<Rep, Period> >(chrono::nanoseconds(from.total_nanoseconds()));
+ }
+ };
+ template < class Rep, class Period>
+ struct assign_to<chrono::duration<Rep, Period>, posix_time::time_duration> {
+ inline static chrono::duration<Rep, Period> & apply(chrono::duration<Rep, Period> & to, const posix_time::time_duration& from)
+ {
+ to = boost::convert_to<chrono::duration<Rep, Period> >(from);
+ return to;
+ }
+ };
+ }}
+ #else
+ namespace chrono {
+ template < class Rep, class Period>
+ inline posix_time::time_duration convert_to(chrono::duration<Rep, Period> const & from
+ , boost::dummy::type_tag<posix_time::time_duration> const&)
+ {
+ typedef duration<Rep, Period> src_duration_t;
+ typedef nanoseconds duration_t;
+ typedef duration_t::rep rep_t;
+ rep_t d = chrono::duration_cast<duration_t>(from).count();
+ rep_t sec = d/1000000000;
+ rep_t nsec = d%1000000000;
+ return posix_time::seconds(static_cast<long>(sec))+
+#ifdef BOOST_DATE_TIME_HAS_NANOSECONDS
+ posix_time::nanoseconds(nsec);
+#else
+ posix_time::microseconds((nsec+500)/1000);
+#endif
+ }
+
+ template < class Rep, class Period>
+ inline chrono::duration<Rep, Period> & assign_to(chrono::duration<Rep, Period> & to, const posix_time::time_duration& from
+ , boost::dummy::type_tag<chrono::duration<Rep, Period> > const&
+ )
+
+ {
+ to = boost::convert_to<duration<Rep, Period> >(from);
+ return to;
+ }
+ }
+
+ namespace posix_time {
+ template < class Rep, class Period>
+ inline chrono::duration<Rep, Period> convert_to(time_duration const & from
+ , boost::dummy::type_tag<chrono::duration<Rep, Period> > const&)
+ {
+ return chrono::duration_cast<chrono::duration<Rep, Period> >(chrono::nanoseconds(from.total_nanoseconds()));
+ }
+
+ template < class Rep, class Period>
+ inline time_duration& assign_to(time_duration& to, const chrono::duration<Rep, Period>& from
+ , boost::dummy::type_tag<posix_time::time_duration> const&
+ )
+ {
+ to = boost::convert_to<time_duration>(from);
+ return to;
+ }
+ }
+ #endif
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/boost/chrono_posix_time.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/chrono_posix_time.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,18 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_CHRONO_POSIX_TIME__HPP
+#define BOOST_CONVERT_TO_CHRONO_POSIX_TIME__HPP
+
+#include <boost/conversion/boost/chrono_time_point_to_posix_time_ptime.hpp>
+#include <boost/conversion/boost/chrono_duration_to_posix_time_duration.hpp>
+
+#endif
+
Added: sandbox/chrono/boost/conversion/boost/chrono_time_point_to_posix_time_ptime.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/chrono_time_point_to_posix_time_ptime.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,130 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//[CHRONO_TIME_POINT_TO_POSIX_TIME_PTIME__HPP
+#ifndef BOOST_CONVERT_TO_CHRONO_TIME_POINT_TO_POSIX_TIME_PTIME__HPP
+#define BOOST_CONVERT_TO_CHRONO_TIME_POINT_TO_POSIX_TIME_PTIME__HPP
+
+#include <boost/chrono/chrono.hpp>
+#include <boost/date_time/posix_time/posix_time_types.hpp>
+#include <boost/date_time/posix_time/conversion.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/config.hpp>
+
+namespace boost {
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < class Clock, class Duration>
+ struct convert_to<posix_time::ptime, chrono::time_point<Clock, Duration> > {
+ inline static posix_time::ptime apply(const chrono::time_point<Clock, Duration>& from)
+ {
+ typedef chrono::time_point<Clock, Duration> time_point_t;
+ typedef chrono::nanoseconds duration_t;
+ typedef duration_t::rep rep_t;
+ rep_t d = chrono::duration_cast<duration_t>(from.time_since_epoch()).count();
+ rep_t sec = d/1000000000;
+ rep_t nsec = d%1000000000;
+ return posix_time::from_time_t(0)+
+ posix_time::seconds(static_cast<long>(sec))+
+#ifdef BOOST_DATE_TIME_HAS_NANOSECONDS
+ posix_time::nanoseconds(nsec);
+#else
+ posix_time::microseconds((nsec+500)/1000);
+#endif
+ }
+ };
+ template < class Clock, class Duration>
+ struct assign_to<posix_time::ptime, chrono::time_point<Clock, Duration> > {
+ inline static posix_time::ptime& apply(posix_time::ptime& to, const chrono::time_point<Clock, Duration>& from)
+ {
+ to = boost::convert_to<posix_time::ptime>(from);
+ return to;
+ }
+ };
+
+ template < class Clock, class Duration>
+ struct convert_to<chrono::time_point<Clock, Duration>, posix_time::ptime> {
+ inline static chrono::time_point<Clock, Duration> apply(const posix_time::ptime& from)
+ {
+ posix_time::time_duration const time_since_epoch=from-posix_time::from_time_t(0);
+ chrono::time_point<Clock, Duration> t=chrono::system_clock::from_time_t(time_since_epoch.total_seconds());
+ long nsec=time_since_epoch.fractional_seconds()*(1000000000/time_since_epoch.ticks_per_second());
+ return t+chrono::nanoseconds(nsec);
+
+ }
+ };
+ template < class Clock, class Duration>
+ struct assign_to<chrono::time_point<Clock, Duration>, posix_time::ptime> {
+ inline static chrono::time_point<Clock, Duration>& apply(chrono::time_point<Clock, Duration>& to, const posix_time::ptime& from)
+ {
+ to = boost::convert_to<chrono::time_point<Clock, Duration> >(from);
+ return to;
+ }
+ };
+ }}
+ #else
+ namespace chrono {
+ template < class Clock, class Duration>
+ inline posix_time::ptime convert_to(const chrono::time_point<Clock, Duration>& from
+ , boost::dummy::type_tag<posix_time::ptime> const&)
+ {
+ typedef chrono::time_point<Clock, Duration> time_point_t;
+ typedef chrono::nanoseconds duration_t;
+ typedef duration_t::rep rep_t;
+ rep_t d = chrono::duration_cast<duration_t>(from.time_since_epoch()).count();
+ rep_t sec = d/1000000000;
+ rep_t nsec = d%1000000000;
+ return posix_time::from_time_t(0)+
+ posix_time::seconds(static_cast<long>(sec))+
+#ifdef BOOST_DATE_TIME_HAS_NANOSECONDS
+ posix_time::nanoseconds(nsec);
+#else
+ posix_time::microseconds((nsec+500)/1000);
+#endif
+ }
+
+
+ template < class Clock, class Duration>
+ inline chrono::time_point<Clock, Duration>& assign_to(chrono::time_point<Clock, Duration>& to, const posix_time::ptime& from
+ , boost::dummy::type_tag<chrono::time_point<Clock, Duration> > const&
+ )
+ {
+ to = boost::convert_to<chrono::time_point<Clock, Duration> >(from);
+ return to;
+ }
+
+ }
+ namespace posix_time {
+ template < class Clock, class Duration>
+ inline chrono::time_point<Clock, Duration> convert_to(const ptime& from
+ , boost::dummy::type_tag<chrono::time_point<Clock, Duration> > const&)
+ {
+ time_duration const time_since_epoch=from-from_time_t(0);
+ chrono::time_point<Clock, Duration> t=chrono::system_clock::from_time_t(time_since_epoch.total_seconds());
+ long nsec=time_since_epoch.fractional_seconds()*(1000000000/time_since_epoch.ticks_per_second());
+ return t+chrono::nanoseconds(nsec);
+ }
+
+ template < class Clock, class Duration>
+ inline ptime& assign_to(ptime& to, const chrono::time_point<Clock, Duration>& from
+ , boost::dummy::type_tag<posix_time::ptime> const&
+ )
+ {
+ to = boost::convert_to<ptime>(from);
+ return to;
+ }
+
+ }
+ #endif
+}
+
+#endif
+//]
Added: sandbox/chrono/boost/conversion/boost/interval.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/interval.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,60 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_INTERVAL__HPP
+#define BOOST_CONVERT_TO_INTERVAL__HPP
+
+#include <boost/numeric/interval.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+
+namespace boost {
+
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < class T, class PT, class U, class PU>
+ struct convert_to< numeric::interval<T,PT>, numeric::interval<U,PU> > {
+ inline static numeric::interval<T,PT> apply(numeric::interval<U,PU> const & from)
+ {
+ return numeric::interval<T,PT>(boost::convert_to<T>(from.lower()), boost::convert_to<U>(from.upper()));
+ }
+ };
+ template < class T, class PT, class U, class PU>
+ struct assign_to< numeric::interval<T,PT>, numeric::interval<U,PU> > {
+ inline static numeric::interval<T,PT>& apply(numeric::interval<T,PT>& to, const numeric::interval<U,PU>& from)
+ {
+ to.assign(boost::convert_to<T>(from.lower()), boost::convert_to<U>(from.upper()));
+ return to;
+ }
+ };
+
+ }}
+ #else
+ namespace numeric {
+ template < class T, class PT, class U, class PU>
+ inline interval<T,PT> convert_to(interval<U,PU> const & from
+ , boost::dummy::type_tag<interval<T,PT> > const&)
+ {
+ return interval<T,PT>(boost::convert_to<T>(from.lower()), boost::convert_to<U>(from.upper()));
+ }
+ template < class T, class PT, class U, class PU>
+ inline interval<T,PT>& assign_to(interval<T,PT>& to, const interval<U,PU>& from
+ , boost::dummy::type_tag<interval<T,PT> > const&
+ )
+ {
+ to.assign(boost::convert_to<T>(from.lower()),boost::convert_to<U>(from.upper()));
+ return to;
+ }
+ }
+ #endif
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/boost/optional.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/optional.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,63 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//[OPTIONAL__HPP
+#ifndef BOOST_CONVERT_TO_OPTIONAL__HPP
+#define BOOST_CONVERT_TO_OPTIONAL__HPP
+
+#include <boost/optional.hpp>
+#include <boost/none.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/config.hpp>
+
+namespace boost {
+
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < class Target, class Source>
+ struct convert_to< optional<Target>, optional<Source> > {
+ inline static optional<Target> apply(optional<Source> const & from)
+ {
+ return (from?optional<Target>(boost::convert_to<Target>(from.get())):optional<Target>());
+ }
+ };
+ template < class Target, class Source>
+ struct assign_to< optional<Target>, optional<Source> > {
+ inline static optional<Target>& apply(optional<Target>& to, const optional<Source>& from)
+ {
+ to = from?boost::convert_to<Target>(from.get()):optional<Target>();
+ return to;
+ }
+ };
+
+ }}
+ #else
+ template < class Target, class Source>
+ inline optional<Target> convert_to(optional<Source> const & from
+ , boost::dummy::type_tag<optional<Target> > const&)
+ {
+ return (from?optional<Target>(boost::convert_to<Target>(from.get())):optional<Target>());
+ }
+
+ template < class Target, class Source>
+ inline optional<Target>& assign_to(optional<Target>& to, const optional<Source>& from
+ , boost::dummy::type_tag<optional<Target> > const&
+ )
+ {
+ to = from?boost::convert_to<Target>(from.get()):optional<Target>();
+ return to;
+ }
+ #endif
+}
+
+#endif
+
+//]
Added: sandbox/chrono/boost/conversion/boost/rational.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/rational.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,62 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_PAIR__HPP
+#define BOOST_CONVERT_TO_PAIR__HPP
+
+#include <boost/rational.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/config.hpp>
+
+namespace boost {
+
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < class T, class U>
+ struct convert_to< rational<T>, rational<U> > {
+ inline static rational<T> apply(rational<U> const & from)
+ {
+ return rational<T>(boost::convert_to<T>(from.numerator()), boost::convert_to<T>(from.denominator()));
+ }
+ };
+ template < class T, class U>
+ struct assign_to< rational<T>, rational<U> > {
+ inline static rational<T>& apply(rational<T>& to, const rational<U>& from)
+ {
+ to.assign(boost::convert_to<T>(from.numerator()), boost::convert_to<T>(from.denominator()));
+ return to;
+ }
+ };
+
+ }}
+ #else
+ template < class T, class U>
+ inline rational<T> convert_to(rational<U> const & from
+ , boost::dummy::type_tag<rational<T> > const&)
+ {
+ return rational<T>(boost::convert_to<T>(from.numerator()), boost::convert_to<T>(from.denominator()));
+ }
+
+ template < class T, class U>
+ inline rational<T>& assign_to(rational<T>& to, const rational<U>& from
+ , boost::dummy::type_tag<rational<T> > const&
+ )
+ {
+ to.assign(boost::convert_to<T>(from.numerator()), boost::convert_to<T>(from.denominator()));
+ return to;
+ }
+ #endif
+
+
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/boost/tuple.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/boost/tuple.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,108 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_PAIR__HPP
+#define BOOST_CONVERT_TO_PAIR__HPP
+
+#include <boost/fusion/tuple.hpp>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/config.hpp>
+
+namespace boost {
+
+ #ifdef BOOST_NO_FUNCTION_TEMPLATE_ORDERING
+ namespace conversion { namespace partial_specialization_workaround {
+ template < class T1, class T2, class U1, class U2>
+ struct convert_to< fusion::tuple<T1,T2>, fusion::tuple<U1,U2> > {
+ inline static fusion::tuple<T1,T2> apply(fusion::tuple<U1,U2> const & from)
+ {
+ return fusion::tuple<T1,T2>(
+ boost::convert_to<T1>(fusion::get<0>(from))
+ , boost::convert_to<T2>(fusion::get<1>(from))
+ );
+ }
+ };
+ template < class T1, class T2, class U1, class U2>
+ struct assign_to< fusion::tuple<T1,T2>, fusion::tuple<U1,U2> > {
+ inline static fusion::tuple<T1,T2>& apply(fusion::tuple<T1,T2>& to, fusion::tuple<U1,U2> const & from)
+ {
+ to = boost::convert_to<fusion::tuple<T1,T2> >(from);
+ return to;
+ }
+ };
+ template < class T1, class T2, class T3, class U1, class U2, class U3>
+ struct convert_to< fusion::tuple<T1,T2,T3>, fusion::tuple<U1,U2,U3> > {
+ inline static fusion::tuple<T1,T2,T3> apply(fusion::tuple<U1,U2,U3> const & from)
+ {
+ return fusion::tuple<T1,T2, T3>(
+ boost::convert_to<T1>(fusion::get<0>(from))
+ , boost::convert_to<T2>(fusion::get<1>(from))
+ , boost::convert_to<T3>(fusion::get<2>(from))
+ );
+ }
+ };
+ template < class T1, class T2, class T3, class U1, class U2, class U3>
+ struct assign_to< fusion::tuple<T1,T2,T3>, fusion::tuple<U1,U2,U3> > {
+ inline static fusion::tuple<T1,T2,T3> apply(fusion::tuple<T1,T2,T3>& to, fusion::tuple<U1,U2,U3> const & from)
+ {
+ to = boost::convert_to<fusion::tuple<T1,T2> >(from);
+ return to;
+ }
+ };
+
+ }}
+ #else
+ namespace fusion {
+ template < class T1, class T2, class U1, class U2>
+ inline tuple<T1,T2> convert_to(tuple<U1,U2> const & from
+ , boost::dummy::type_tag<tuple<T1,T2> > const&)
+ {
+ return tuple<T1,T2>(
+ boost::convert_to<T1>(boost::fusion::get<0>(from))
+ , boost::convert_to<T2>(boost::fusion::get<1>(from))
+ );
+ }
+
+ template < class T1, class T2, class U1, class U2>
+ inline tuple<T1,T2>& assign_to(tuple<T1,T2>& to, tuple<U1,U2> const & from
+ , boost::dummy::type_tag<tuple<T1,T2> > const&
+ )
+ {
+ to = boost::convert_to<boost::fusion::tuple<T1,T2> >(from);
+ return to;
+ }
+
+ template < class T1, class T2, class T3, class U1, class U2, class U3>
+ inline tuple<T1,T2,T3> convert_to(tuple<U1,U2,U3> const & from
+ , boost::dummy::type_tag<tuple<T1,T2,T3> > const&
+ )
+ {
+ return boost::fusion::tuple<T1,T2, T3>(
+ boost::convert_to<T1>(boost::fusion::get<0>(from))
+ , boost::convert_to<T2>(boost::fusion::get<1>(from))
+ , boost::convert_to<T3>(boost::fusion::get<2>(from))
+ );
+ }
+
+ template < class T1, class T2, class T3, class U1, class U2, class U3>
+ inline tuple<T1,T2,T3> assign_to(tuple<T1,T2,T3>& to, boost::fusion::tuple<U1,U2,U3> const & from
+ , boost::dummy::type_tag<tuple<T1,T2,T3> > const&
+ )
+ {
+ to = boost::convert_to<boost::fusion::tuple<T1,T2> >(from);
+ return to;
+ }
+ }
+ #endif
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/ca_wrapper.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/ca_wrapper.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,43 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CA_WRAPPER__HPP
+#define BOOST_CA_WRAPPER__HPP
+
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+
+namespace boost {
+ namespace conversion {
+
+ template <typename T>
+ class ca_wrapper {
+ T& ref_;
+ public:
+ ca_wrapper(T& r) : ref_(r) {}
+ template <typename U>
+ operator U() {
+ return boost::convert_to<U>(ref_);
+ }
+ template <typename U>
+ T& operator =(U const& u) {
+ return boost::assign_to(ref_, u);
+ }
+ };
+ }
+ template <typename T>
+ conversion::ca_wrapper<T> mca(T& r) {
+ return conversion::ca_wrapper<T>(r);
+ }
+
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/convert_to.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/convert_to.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,53 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO__HPP
+#define BOOST_CONVERT_TO__HPP
+
+#include <cstddef> //for std::size_t
+
+namespace boost {
+ namespace dummy {
+ template <typename T> struct base_tag {};
+ template <typename T> struct type_tag : public base_tag<T> {};
+ }
+ namespace conversion {
+ namespace partial_specialization_workaround {
+ template < typename To, typename From >
+ struct convert_to {
+ inline static To apply(const From& val)
+ {
+ return To(val);
+ }
+ };
+ }
+
+ template < typename To, typename From >
+ To convert_to(const From& val, dummy::type_tag<To> const&) {
+ return conversion::partial_specialization_workaround::convert_to<To,From>::apply(val);
+ }
+ }
+ namespace conversion_impl {
+ template <typename Target, typename Source>
+ Target convert_to_impl(Source const& from) {
+ using namespace boost::conversion;
+ //use boost::conversion::convert_to if ADL fails
+ return convert_to(from, boost::dummy::type_tag<Target>());
+ }
+ }
+ template <typename Target, typename Source>
+ Target convert_to(Source const& from, boost::dummy::base_tag<Target> const& p=boost::dummy::base_tag<Target>()) {
+ return conversion_impl::convert_to_impl<Target>(from);
+ }
+
+}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/convert_to_via.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/convert_to_via.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,25 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_VIA__HPP
+#define BOOST_CONVERT_TO_VIA__HPP
+
+#include <boost/conversion/convert_to.hpp>
+
+namespace boost { namespace conversion {
+
+ template < typename To, typename Via, typename From >
+ To convert_to_via(const From& val) {
+ boost::convert_to<To>(boost::convert_to<Via>(val));
+ }
+}}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/pack.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/pack.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,82 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERSION_PACK__HPP
+#define BOOST_CONVERSION_PACK__HPP
+
+#include <boost/ref.hpp>
+#include <boost/fusion/adapted/std_pair.hpp>
+#include <boost/fusion/tuple.hpp>
+#include <boost/fusion/include/at_c.hpp>
+
+namespace boost { namespace conversion {
+
+
+namespace result_of {
+ template <typename T1, typename T2> struct pack2 {
+ typedef
+ std::pair<
+ //~ fusion::tuple<
+ boost::reference_wrapper<T1>
+ , boost::reference_wrapper<T2>
+ > type;
+ };
+ template <typename T1, typename T2, typename T3=fusion::void_> struct pack3 {
+ typedef fusion::tuple<
+ boost::reference_wrapper<T1>
+ , boost::reference_wrapper<T2>
+ , boost::reference_wrapper<T3>
+ > type;
+ };
+}
+
+template <typename T1, typename T2>
+typename boost::conversion::result_of::pack2<T1 const, T2 const>::type pack(
+ T1 const& t1, T2 const& t2) {
+ return std::make_pair
+ //~ return boost::fusion::make_tuple
+ (boost::cref(t1), boost::cref(t2));
+}
+
+template <typename T1, typename T2>
+typename boost::conversion::result_of::pack2<T1 const, T2>::type pack(T1 const& t1, T2 & t2) {
+ return std::make_pair
+ //~ return boost::fusion::make_tuple
+ (boost::cref(t1), boost::ref(t2));
+}
+
+template <typename T1, typename T2, typename T3>
+typename boost::conversion::result_of::pack3<T1 const, T2 const, T3 const>::type pack(
+ T1 const& t1, T2 const& t2, T3 const& t3) {
+ return fusion::make_tuple(boost::cref(t1), boost::cref(t2), boost::cref(t3));
+}
+
+template <typename T1, typename T2, typename T3>
+typename boost::conversion::result_of::pack3<T1 const, T2 const, T3>::type pack(
+ T1 const& t1, T2 const& t2, T3 & t3) {
+ return fusion::make_tuple(boost::cref(t1), boost::cref(t2), boost::ref(t3));
+}
+
+template <typename T1, typename T2, typename T3>
+typename boost::conversion::result_of::pack3<T1 const, T2, T3 const>::type pack(
+ T1 const& t1, T2 & t2, T3 const& t3) {
+ return fusion::make_tuple(boost::cref(t1), boost::ref(t2), boost::cref(t3));
+}
+
+template <typename T1, typename T2, typename T3>
+typename boost::conversion::result_of::pack3<T1 const, T2, T3>::type pack(
+ T1 const& t1, T2 & t2, T3 & t3) {
+ return fusion::make_tuple(boost::cref(t1), boost::ref(t2), boost::ref(t3));
+}
+
+}}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/std/complex.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/std/complex.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,44 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_COMPLEX__HPP
+#define BOOST_CONVERT_TO_COMPLEX__HPP
+
+#include <complex>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+
+namespace boost {
+namespace conversion {
+
+ // std namespace can not be overloaded
+ namespace partial_specialization_workaround {
+ template < class T, class U>
+ struct convert_to< std::complex<T>, std::complex<U> > {
+ inline static std::complex<T> apply(std::complex<U> const & from)
+ {
+ return std::complex<T>(boost::convert_to<T>(from.real()), boost::convert_to<T>(from.imag()));
+ }
+ };
+ template < class T, class U>
+ struct assign_to< std::complex<T>, std::complex<U> > {
+ inline static std::complex<T>& apply(std::complex<T>& to, const std::complex<U>& from)
+ {
+ to.real() = boost::convert_to<T>(from.real());
+ to.imag() = boost::convert_to<T>(from.imag());
+ return to;
+ }
+ };
+
+ }
+}}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/std/pair.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/std/pair.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,44 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//[PAIR__HPP
+#ifndef BOOST_CONVERT_TO_PAIR__HPP
+#define BOOST_CONVERT_TO_PAIR__HPP
+
+#include <utility>
+//#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+
+namespace boost { namespace conversion {
+
+ // std namespace can not be overloaded
+ namespace partial_specialization_workaround {
+ template < class T1, class T2, class U1, class U2>
+ struct convert_to< std::pair<T1,T2>, std::pair<U1,U2> > {
+ inline static std::pair<T1,T2> apply(std::pair<U1,U2> const & from)
+ {
+ return std::pair<T1,T2>(boost::convert_to<T1>(from.first), boost::convert_to<T2>(from.second));
+ }
+ };
+ template < class T1, class T2, class U1, class U2>
+ struct assign_to< std::pair<T1,T2>, std::pair<U1,U2> > {
+ inline static std::pair<T1,T2>& apply(std::pair<T1,T2>& to, const std::pair<U1,U2>& from)
+ {
+ to.first = boost::convert_to<T1>(from.first);
+ to.second = boost::convert_to<T2>(from.second);
+ return to;
+ }
+ };
+ }
+}}
+
+#endif
+
+//]
Added: sandbox/chrono/boost/conversion/std/string.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/std/string.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,60 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#ifndef BOOST_CONVERT_TO_PAIR__HPP
+#define BOOST_CONVERT_TO_PAIR__HPP
+
+#include <string>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/convert/convert.hpp>
+
+namespace boost {
+namespace conversion {
+
+ // std namespace can not be overloaded
+ namespace partial_specialization_workaround {
+
+ template<typename T, typename CharT, typename Traits, typename Alloc>
+ struct convert_to< std::basic_string<CharT,Traits,Alloc>, T > {
+ inline static std::basic_string<CharT,Traits,Alloc> apply(T const & from)
+ {
+ return convert<std::basic_string<CharT,Traits,Alloc> >::from(from);
+ }
+ }
+ template<typename T, typename CharT, typename Traits, typename Alloc>
+ struct assign_to< std::basic_string<CharT,Traits,Alloc>, T > {
+ inline static std::basic_string<CharT,Traits,Alloc>& apply(std::basic_string<CharT,Traits,Alloc>& to, const T& from)
+ {
+ to = convert<std::basic_string<CharT,Traits,Alloc> >::from(from);
+ return to;
+ }
+ };
+ template<typename T, typename CharT, typename Traits, typename Alloc>
+ struct convert_to< T, std::basic_string<CharT,Traits,Alloc>> {
+ inline static T apply(std::basic_string<CharT,Traits,Alloc> const & from)
+ {
+ return convert<T>::from(from);
+ }
+ };
+ template<typename T, typename CharT, typename Traits, typename Alloc>
+ struct assign_to< T, std::basic_string<CharT,Traits,Alloc>> {
+ inline static void apply(T& to, const std::basic_string<CharT,Traits,Alloc>& from)
+ {
+ to = convert<T>::from(from);
+ return to;
+ }
+ };
+
+ }
+}}
+
+#endif
+
Added: sandbox/chrono/boost/conversion/std/vector.hpp
==============================================================================
--- (empty file)
+++ sandbox/chrono/boost/conversion/std/vector.hpp 2010-06-17 17:11:19 EDT (Thu, 17 Jun 2010)
@@ -0,0 +1,72 @@
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2009. 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)
+//
+// See http://www.boost.org/libs/synchro for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+//[VECTOR__HPP
+#ifndef BOOST_CONVERT_TO_PAIR__HPP
+#define BOOST_CONVERT_TO_PAIR__HPP
+
+#include <vector>
+#include <boost/conversion/convert_to.hpp>
+#include <boost/conversion/assign_to.hpp>
+#include <boost/conversion/pack.hpp>
+
+
+namespace boost { namespace conversion {
+
+ // std namespace can not be overloaded
+ namespace partial_specialization_workaround {
+ template < class T1, class A1, class T2, class A2>
+ struct convert_to< std::vector<T1,A1>, std::vector<T2,A2> > {
+ inline static std::vector<T1,A1> apply(std::vector<T2,A2> const & from)
+ {
+ std::vector<T1,A1> res;
+ boost::assign_to(res, from);
+ return res;
+ }
+ };
+ template < class T1, class A1, class T2, class A2>
+ struct assign_to< std::vector<T1,A1>, std::vector<T2,A2> > {
+ inline static std::vector<T1,A1>& apply(
+ std::vector<T1,A1>& to,
+ std::vector<T2,A2> const & from)
+ {
+ to.resize(from.size());
+ for (unsigned int i=0; i<from.size(); ++i) {
+ boost::assign_to(to[i], from[i]);
+ }
+ return to;
+ }
+ };
+
+ template < class T1, class A1, class T2, class A2>
+ struct convert_to< std::vector<T1,A1>,
+ //~ typename boost::conversion::result_of::pack2<std::vector<T2,A2> const, A1 const>::type
+ //~ boost::fusion::tuple<
+ std::pair<
+ boost::reference_wrapper<std::vector<T2,A2> const>,
+ boost::reference_wrapper<A1 const>
+ >
+ > {
+ inline static std::vector<T1,A1> apply(
+ typename boost::conversion::result_of::pack2<std::vector<T2,A2> const, A1 const>::type
+ const & pack)
+ {
+ std::vector<T1,A1> res(fusion::at_c<1>(pack));
+ boost::assign_to(res, fusion::at_c<0>(pack).get());
+ return res;
+ }
+ };
+
+ }
+}}
+
+#endif
+
+//]
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