Attempt to represent the S^2->S^3 header reorganisation as a series of "hg rename" operations
1 //-----------------------------------------------------------------------------
2 // boost variant/detail/variant_io.hpp header file
3 // See http://www.boost.org for updates, documentation, and revision history.
4 //-----------------------------------------------------------------------------
6 // Copyright (c) 2002-2003
7 // Eric Friedman, Itay Maman
9 // Distributed under the Boost Software License, Version 1.0. (See
10 // accompanying file LICENSE_1_0.txt or copy at
11 // http://www.boost.org/LICENSE_1_0.txt)
13 #ifndef BOOST_VARIANT_DETAIL_VARIANT_IO_HPP
14 #define BOOST_VARIANT_DETAIL_VARIANT_IO_HPP
16 #include <iosfwd> // for std::basic_ostream forward declare
18 #include "boost/variant/variant_fwd.hpp"
20 #include "boost/detail/templated_streams.hpp"
21 #include "boost/variant/static_visitor.hpp"
25 ///////////////////////////////////////////////////////////////////////////////
26 // function template operator<<
28 // Outputs the content of the given variant to the given ostream.
31 // forward declare (allows output of embedded variant< variant< ... >, ... >)
33 BOOST_TEMPLATED_STREAM_ARGS(E,T)
34 BOOST_TEMPLATED_STREAM_COMMA
35 BOOST_VARIANT_ENUM_PARAMS(typename U)
37 inline BOOST_TEMPLATED_STREAM(ostream, E,T)& operator<<(
38 BOOST_TEMPLATED_STREAM(ostream, E,T)& out
39 , const variant< BOOST_VARIANT_ENUM_PARAMS(U) >& rhs
42 namespace detail { namespace variant {
44 template <typename OStream>
46 : public boost::static_visitor<>
48 private: // representation
54 explicit printer(OStream& out)
59 public: // visitor interface
62 void operator()(const T& operand) const
69 }} // namespace detail::variant
72 BOOST_TEMPLATED_STREAM_ARGS(E,T)
73 BOOST_TEMPLATED_STREAM_COMMA
74 BOOST_VARIANT_ENUM_PARAMS(typename U)
76 inline BOOST_TEMPLATED_STREAM(ostream, E,T)& operator<<(
77 BOOST_TEMPLATED_STREAM(ostream, E,T)& out
78 , const variant< BOOST_VARIANT_ENUM_PARAMS(U) >& rhs
81 detail::variant::printer<
82 BOOST_TEMPLATED_STREAM(ostream, E,T)
85 rhs.apply_visitor(visitor);
92 #endif // BOOST_VARIANT_DETAIL_VARIANT_IO_HPP