diff --git a/doc/reference.html b/doc/reference.html index 8111be9..7ec0129 100644 --- a/doc/reference.html +++ b/doc/reference.html @@ -80,7 +80,7 @@ noexcept and explicit conversion operators. The actual implementation uses C++11 features only when they are available, and otherwise falls back on C++03 features.

Macros

-

Users may defined the following macros if desired. Sensible defaults are +

Users may define the following macros if desired. Sensible defaults are provided, so users may ignore these macros if they prefer.

@@ -109,17 +109,16 @@ provided, so users may ignore these macros if they prefer.

facility. - + - +
BOOST_SYSTEM_NO_DEPRECATEDBOOST_SYSTEM_ENABLE_DEPRECATED Not defined.Deprecated features are excluded.Deprecated features are provided for compatibility.

Deprecated names

-

In the process of adding Boost.System to C++0x standard library, the C++ -committee changed some -names. To ease transition, Boost.System deprecates the old -names, but continues to provide them unless macro BOOST_SYSTEM_NO_DEPRECATED -is defined.

+

In the process of adding Boost.System to the C++11 standard library, the +C++ committee changed some names. To ease transition, Boost.System deprecates +the old names, but will provide them when the macro +BOOST_SYSTEM_ENABLE_DEPRECATED is defined.

diff --git a/include/boost/system/detail/error_code.ipp b/include/boost/system/detail/error_code.ipp index dec55d3..99d0892 100644 --- a/include/boost/system/detail/error_code.ipp +++ b/include/boost/system/detail/error_code.ipp @@ -452,7 +452,7 @@ namespace } // unnamed namespace -# ifndef BOOST_SYSTEM_NO_DEPRECATED +# ifdef BOOST_SYSTEM_ENABLE_DEPRECATED BOOST_SYSTEM_DECL error_code throws; // "throw on error" special error_code; // note that it doesn't matter if this // isn't initialized before use since diff --git a/include/boost/system/error_code.hpp b/include/boost/system/error_code.hpp index 080bb27..8041d5d 100644 --- a/include/boost/system/error_code.hpp +++ b/include/boost/system/error_code.hpp @@ -144,7 +144,7 @@ namespace boost } // namespace errc -# ifndef BOOST_SYSTEM_NO_DEPRECATED +# ifdef BOOST_SYSTEM_ENABLE_DEPRECATED namespace posix = errc; namespace posix_error = errc; # endif @@ -198,7 +198,7 @@ namespace boost #endif // deprecated synonyms ------------------------------------------------------------// -#ifndef BOOST_SYSTEM_NO_DEPRECATED +#ifdef BOOST_SYSTEM_ENABLE_DEPRECATED inline const error_category & get_system_category() { return system_category(); } inline const error_category & get_generic_category() { return generic_category(); } inline const error_category & get_posix_category() { return generic_category(); } @@ -533,7 +533,7 @@ namespace boost }; // predefined error_code object used as "throw on error" tag -# ifndef BOOST_SYSTEM_NO_DEPRECATED +# ifdef BOOST_SYSTEM_ENABLE_DEPRECATED BOOST_SYSTEM_DECL extern error_code throws; # endif diff --git a/include/boost/system/linux_error.hpp b/include/boost/system/linux_error.hpp index 0873a7c..d02ce29 100644 --- a/include/boost/system/linux_error.hpp +++ b/include/boost/system/linux_error.hpp @@ -89,7 +89,7 @@ namespace boost }; } // namespace linux_error -# ifndef BOOST_SYSTEM_NO_DEPRECATED +# ifdef BOOST_SYSTEM_ENABLE_DEPRECATED namespace Linux = linux_error; # endif diff --git a/include/boost/system/windows_error.hpp b/include/boost/system/windows_error.hpp index 0fb7ea6..c6e0aad 100644 --- a/include/boost/system/windows_error.hpp +++ b/include/boost/system/windows_error.hpp @@ -107,7 +107,7 @@ namespace boost } // namespace windows -# ifndef BOOST_SYSTEM_NO_DEPRECATED +# ifdef BOOST_SYSTEM_ENABLE_DEPRECATED namespace windows = windows_error; # endif diff --git a/test/error_code_test.cpp b/test/error_code_test.cpp index baf3853..7965541 100644 --- a/test/error_code_test.cpp +++ b/test/error_code_test.cpp @@ -9,9 +9,6 @@ //----------------------------------------------------------------------------// -// test without deprecated features -#define BOOST_SYSTEM_NO_DEPRECATED - #include #include diff --git a/test/error_code_user_test.cpp b/test/error_code_user_test.cpp index a006a8d..e9e5845 100644 --- a/test/error_code_user_test.cpp +++ b/test/error_code_user_test.cpp @@ -14,8 +14,6 @@ // Motivation was a Boost posting by Christopher Kohlhoff on June 28, 2006. -#define BOOST_SYSTEM_NO_DEPRECATED - #include #include #include diff --git a/test/initialization_test.cpp b/test/initialization_test.cpp index 8c7c988..9c89a50 100644 --- a/test/initialization_test.cpp +++ b/test/initialization_test.cpp @@ -18,7 +18,7 @@ struct foo foo() { boost::system::error_code ec; - ec == boost::system::posix::permission_denied; + ec == boost::system::errc::permission_denied; } } f; diff --git a/test/system_error_test.cpp b/test/system_error_test.cpp index fe88cd7..32bd04e 100644 --- a/test/system_error_test.cpp +++ b/test/system_error_test.cpp @@ -9,9 +9,6 @@ //----------------------------------------------------------------------------// -// test without deprecated features -#define BOOST_SYSTEM_NO_DEPRECATED - #include #include
Old usage, now deprecated