| 1 | // (C) Copyright Gennadiy Rozental 2005. |
|---|
| 2 | // Distributed under the Boost Software License, Version 1.0. |
|---|
| 3 | // (See accompanying file LICENSE_1_0.txt or copy at |
|---|
| 4 | // http://www.boost.org/LICENSE_1_0.txt) |
|---|
| 5 | |
|---|
| 6 | // See http://www.boost.org/libs/test for the library home page. |
|---|
| 7 | // |
|---|
| 8 | // File : $RCSfile: wrap_io_saver.hpp,v $ |
|---|
| 9 | // |
|---|
| 10 | // Version : $Revision: 1.2 $ |
|---|
| 11 | // |
|---|
| 12 | // Description : wraps io savers staff to be provide workaround for classic iostreams |
|---|
| 13 | // *************************************************************************** |
|---|
| 14 | |
|---|
| 15 | #ifndef BOOST_WRAP_IO_SAVER_HPP_011605GER |
|---|
| 16 | #define BOOST_WRAP_IO_SAVER_HPP_011605GER |
|---|
| 17 | |
|---|
| 18 | #include <boost/test/detail/suppress_warnings.hpp> |
|---|
| 19 | |
|---|
| 20 | #if defined(BOOST_STANDARD_IOSTREAMS) |
|---|
| 21 | #include <boost/io/ios_state.hpp> |
|---|
| 22 | #endif |
|---|
| 23 | |
|---|
| 24 | namespace boost { |
|---|
| 25 | |
|---|
| 26 | namespace unit_test { |
|---|
| 27 | |
|---|
| 28 | #if defined(BOOST_STANDARD_IOSTREAMS) |
|---|
| 29 | |
|---|
| 30 | typedef ::boost::io::ios_base_all_saver io_saver_type; |
|---|
| 31 | |
|---|
| 32 | #else |
|---|
| 33 | |
|---|
| 34 | struct io_saver_type { |
|---|
| 35 | explicit io_saver_type( std::ostream& ) {} |
|---|
| 36 | void restore() {} |
|---|
| 37 | }; |
|---|
| 38 | |
|---|
| 39 | #endif |
|---|
| 40 | |
|---|
| 41 | } // namespace unit_test |
|---|
| 42 | |
|---|
| 43 | } // namespace boost |
|---|
| 44 | |
|---|
| 45 | #include <boost/test/detail/enable_warnings.hpp> |
|---|
| 46 | |
|---|
| 47 | // *************************************************************************** |
|---|
| 48 | // Revision History : |
|---|
| 49 | // |
|---|
| 50 | // $Log: wrap_io_saver.hpp,v $ |
|---|
| 51 | // Revision 1.2 2005/12/14 04:59:11 rogeeff |
|---|
| 52 | // *** empty log message *** |
|---|
| 53 | // |
|---|
| 54 | // Revision 1.1 2005/04/30 16:48:21 rogeeff |
|---|
| 55 | // io saver warkaround for classic io is shared |
|---|
| 56 | // |
|---|
| 57 | // Revision 1.1 2005/02/20 08:27:06 rogeeff |
|---|
| 58 | // This a major update for Boost.Test framework. See release docs for complete list of fixes/updates |
|---|
| 59 | // |
|---|
| 60 | // *************************************************************************** |
|---|
| 61 | |
|---|
| 62 | #endif // BOOST_WRAP_IO_SAVER_HPP_011605GER |
|---|
| 63 | |
|---|