From 9139ec41370d9acfc2edd0f2cdc4b5bcf9f43711 Mon Sep 17 00:00:00 2001 From: Jonathan Turkanis Date: Mon, 31 Jan 2005 23:16:32 +0000 Subject: [PATCH] added broken overload resolution workarounds for metrowerks [SVN r26973] --- include/boost/iostreams/stream_facade.hpp | 18 +++++++++++------- include/boost/iostreams/streambuf_facade.hpp | 15 +++++++++++---- 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/include/boost/iostreams/stream_facade.hpp b/include/boost/iostreams/stream_facade.hpp index 8a7c036..0ffb331 100755 --- a/include/boost/iostreams/stream_facade.hpp +++ b/include/boost/iostreams/stream_facade.hpp @@ -14,15 +14,14 @@ #include #include #include +#include #include #include #include #include #include -namespace boost { namespace iostreams { - -namespace detail { +namespace boost { namespace iostreams { namespace detail { template struct stream_facade_traits { @@ -70,7 +69,13 @@ public: stream_facade_base() : pbase_type(), stream_type(&member) { } }; -} // End namespace detail. +} } } // End namespaces detail, iostreams, boost. + +#ifdef BOOST_IOSTREAMS_BROKEN_OVERLOAD_RESOLUTION +# include +#else + +namespace boost { namespace iostreams { // // Template name: stream_facade. @@ -94,9 +99,6 @@ public: typedef BOOST_IOSTREAMS_CHAR_TYPE(Device) char_type; BOOST_IOSTREAMS_STREAMBUF_TYPEDEFS(Tr) private: - typedef base_from_member< - streambuf_facade - > pbase_type; typedef typename detail::stream_facade_traits< Device, Tr @@ -156,4 +158,6 @@ private: } } // End namespaces iostreams, boost. +#endif // #ifdef BOOST_IOSTREAMS_BROKEN_OVERLOAD_RESOLUTION + #endif // #ifndef BOOST_IOSTREAMS_STREAM_FACADE_HPP_INCLUDED diff --git a/include/boost/iostreams/streambuf_facade.hpp b/include/boost/iostreams/streambuf_facade.hpp index cf33922..5ab3bf3 100755 --- a/include/boost/iostreams/streambuf_facade.hpp +++ b/include/boost/iostreams/streambuf_facade.hpp @@ -14,6 +14,7 @@ #include // MSVC. #include // allocator. +#include #include #include #include @@ -21,9 +22,7 @@ #include #include -namespace boost { namespace iostreams { - -namespace detail { +namespace boost { namespace iostreams { namespace detail { template struct streambuf_facade_traits { @@ -35,7 +34,13 @@ struct streambuf_facade_traits { >::type type; }; -} // End namespace detail. +} } } // End namespaces detail, iostreams, boost + +#ifdef BOOST_IOSTREAMS_BROKEN_OVERLOAD_RESOLUTION +# include +#else + +namespace boost { namespace iostreams { template< typename T, typename Tr = @@ -109,6 +114,8 @@ private: } } // End namespaces iostreams, boost. +#endif // #ifdef BOOST_IOSTREAMS_BROKEN_OVERLOAD_RESOLUTION + #include // MSVC. #endif // #ifndef BOOST_IOSTREAMS_STREAMBUF_FACADE_HPP_INCLUDED