Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r73245 - sandbox/conversion/boost/conversion
From: vicente.botet_at_[hidden]
Date: 2011-07-19 17:55:32


Author: viboes
Date: 2011-07-19 17:55:32 EDT (Tue, 19 Jul 2011)
New Revision: 73245
URL: http://svn.boost.org/trac/boost/changeset/73245

Log:
conversion: cleanup
Removed:
   sandbox/conversion/boost/conversion/ca_wrapper.hpp
   sandbox/conversion/boost/conversion/convert_to_via.hpp

Deleted: sandbox/conversion/boost/conversion/ca_wrapper.hpp
==============================================================================
--- sandbox/conversion/boost/conversion/ca_wrapper.hpp 2011-07-19 17:55:32 EDT (Tue, 19 Jul 2011)
+++ (empty file)
@@ -1,94 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (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/conversion for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-
-/*!
- @file
- @brief
- Defines the free function @c mca.
- */
-#ifndef BOOST_CONVERSION_CA_WRAPPER_HPP
-#define BOOST_CONVERSION_CA_WRAPPER_HPP
-
-#include <boost/conversion/convert_to.hpp>
-#include <boost/conversion/assign_to.hpp>
-
-namespace boost {
- namespace conversion {
-
- //! wrapper providing assignment and conversion operations from a reference.
-
- template <typename T>
- class ca_wrapper {
- public:
- T& ref_;
-
- //! copy constructor
- //! @NoThrow.
- ca_wrapper(ca_wrapper const& r) : ref_(r.ref_) { }
-
- //! constructor from a reference
- //! @NoThrow.
- ca_wrapper(T& r) : ref_(r) {}
-
- //! Implicit conversion to @c U.
- //! @Effects Forwards the conversion from the reference using @c conver_to.
- //! @Returns @c *this
- //! @Throws Whatever @c convert_to throws.
- template <typename U>
- operator U() const {
- return boost::conversion::convert_to<U>(ref_);
- }
-
- //! Assignment.
- //!
- //! @Effects Forwards the assignment to the reference.
- //! @Returns @c *this
- //! @Throws Whatever @c T assignment can throws.
- ca_wrapper& operator =(ca_wrapper<T> const& u) {
- ref_ = u.ref_;
- return *this;
- }
-
- //! Assignment from a converter assigner wrapping a type U convertible to T.
- //!
- //! @Effects Forwards the assignment to the reference using assign_to.
- //! @Returns @c *this
- //! @Throws Whatever @c assign_to throws.
- template <typename U>
- ca_wrapper& operator =(ca_wrapper<U> const& u) {
- boost::conversion::assign_to(ref_, u.ref_);
- return *this;
- }
-
- //! Assignment from a type U convertible to T.
- //!
- //! @Effects Forwards the assignment to the reference using assign_to
- //! @Returns @c *this
- //! @Throws Whatever @c assign_to throws.
- template <typename U>
- ca_wrapper& operator =(U const& u) {
- boost::conversion::assign_to(ref_, u);
- return *this;
- }
- };
- //! makes a converter assigner wrapper of the reference parameter.
-
- //! The result is able to transform conversion by convert_to calls and assignments by assign_to calls.
- //! @NoThrow.
- template <typename T>
- ca_wrapper<T> mca(T& r) {
- return ca_wrapper<T>(r);
- }
- }
-}
-
-#endif
-

Deleted: sandbox/conversion/boost/conversion/convert_to_via.hpp
==============================================================================
--- sandbox/conversion/boost/conversion/convert_to_via.hpp 2011-07-19 17:55:32 EDT (Tue, 19 Jul 2011)
+++ (empty file)
@@ -1,28 +0,0 @@
-//////////////////////////////////////////////////////////////////////////////
-//
-// (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/conversion for documentation.
-//
-//////////////////////////////////////////////////////////////////////////////
-
-#ifndef BOOST_CONVERSION_CONVERT_TO_VIA_HPP
-#define BOOST_CONVERSION_CONVERT_TO_VIA_HPP
-
-#include <boost/conversion/convert_to.hpp>
-
-namespace boost {
- namespace conversion {
-
- template < typename Target, typename Via, typename Source >
- Target convert_to_via(const Source& val) {
- boost::conversion::convert_to<Target>(boost::conversion::convert_to<Via>(val));
- }
-
- }
-}
-
-#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