Boost logo

Boost-Commit :

From: bdawes_at_[hidden]
Date: 2008-07-10 21:25:10


Author: bemandawes
Date: 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
New Revision: 47300
URL: http://svn.boost.org/trac/boost/changeset/47300

Log:
Merge accumulated changes from trunk
Text files modified:
   branches/release/boost/system/error_code.hpp | 38 +++++++++++----------
   branches/release/boost/system/system_error.hpp | 14 +++++++-
   branches/release/libs/system/doc/index.html | 16 +++++----
   branches/release/libs/system/doc/reference.html | 58 +++++++++++++++++++++------------
   branches/release/libs/system/src/error_code.cpp | 31 +++++++-----------
   branches/release/libs/system/test/Jamfile.v2 | 17 ++-------
   branches/release/libs/system/test/error_code_test.cpp | 9 ----
   branches/release/libs/system/test/header_only_test.cpp | 9 ----
   branches/release/libs/system/test/system_error_test.cpp | 68 +++++++++++++++++++++++++--------------
   9 files changed, 140 insertions(+), 120 deletions(-)

Modified: branches/release/boost/system/error_code.hpp
==============================================================================
--- branches/release/boost/system/error_code.hpp (original)
+++ branches/release/boost/system/error_code.hpp 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -47,11 +47,11 @@
     template< class T >
     struct is_error_condition_enum { static const bool value = false; };
 
- // portable error_conditions -------------------------------------------//
+ // generic error_conditions --------------------------------------------//
 
- namespace posix_error
+ namespace errc
     {
- enum posix_errno
+ enum errc_t
       {
         success = 0,
         address_family_not_supported = EAFNOSUPPORT,
@@ -134,13 +134,14 @@
         wrong_protocol_type = EPROTOTYPE
       };
 
- } // namespace posix_error
+ } // namespace errc
 
 # ifndef BOOST_SYSTEM_NO_DEPRECATED
- namespace posix = posix_error;
+ namespace posix = errc;
+ namespace posix_error = errc;
 # endif
 
- template<> struct is_error_condition_enum<posix_error::posix_errno>
+ template<> struct is_error_condition_enum<errc::errc_t>
       { static const bool value = true; };
 
 
@@ -199,15 +200,16 @@
     // predefined error categories -----------------------------------------//
 
     BOOST_SYSTEM_DECL const error_category & get_system_category();
- BOOST_SYSTEM_DECL const error_category & get_posix_category();
+ BOOST_SYSTEM_DECL const error_category & get_generic_category();
 
     static const error_category & system_category = get_system_category();
- static const error_category & posix_category = get_posix_category();
+ static const error_category & generic_category = get_generic_category();
     
 # ifndef BOOST_SYSTEM_NO_DEPRECATED
     // deprecated synonyms
- static const error_category & errno_ecat = get_posix_category();
- static const error_category & native_ecat = get_system_category();
+ static const error_category & posix_category = get_generic_category();
+ static const error_category & errno_ecat = get_generic_category();
+ static const error_category & native_ecat = get_system_category();
 # endif
 
     // class error_condition -----------------------------------------------//
@@ -219,7 +221,7 @@
     public:
 
       // constructors:
- error_condition() : m_val(0), m_cat(&get_posix_category()) {}
+ error_condition() : m_val(0), m_cat(&get_generic_category()) {}
       error_condition( int val, const error_category & cat ) : m_val(val), m_cat(&cat) {}
 
       template <class ConditionEnum>
@@ -248,7 +250,7 @@
       void clear()
       {
         m_val = 0;
- m_cat = &get_posix_category();
+ m_cat = &get_generic_category();
       }
 
       // observers:
@@ -436,17 +438,17 @@
         + reinterpret_cast<std::size_t>(&ec.category());
     }
 
- // make_* functions for posix_error::posix_errno -----------------------------//
+ // make_* functions for errc::errc_t -----------------------------//
 
- namespace posix_error
+ namespace errc
     {
       // explicit conversion:
- inline error_code make_error_code( posix_errno e )
- { return error_code( e, get_posix_category() ); }
+ inline error_code make_error_code( errc_t e )
+ { return error_code( e, get_generic_category() ); }
 
       // implicit conversion:
- inline error_condition make_error_condition( posix_errno e )
- { return error_condition( e, get_posix_category() ); }
+ inline error_condition make_error_condition( errc_t e )
+ { return error_condition( e, get_generic_category() ); }
     }
 
     // error_category default implementation -------------------------------//

Modified: branches/release/boost/system/system_error.hpp
==============================================================================
--- branches/release/boost/system/system_error.hpp (original)
+++ branches/release/boost/system/system_error.hpp 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -24,13 +24,23 @@
     public:
       system_error( error_code ec )
           : std::runtime_error(""), m_error_code(ec) {}
+
       system_error( error_code ec, const std::string & what_arg )
           : std::runtime_error(what_arg), m_error_code(ec) {}
+
+ system_error( error_code ec, const char* what_arg )
+ : std::runtime_error(what_arg), m_error_code(ec) {}
+
+ system_error( int ev, const error_category & ecat )
+ : std::runtime_error(""), m_error_code(ev,ecat) {}
+
       system_error( int ev, const error_category & ecat,
         const std::string & what_arg )
           : std::runtime_error(what_arg), m_error_code(ev,ecat) {}
- system_error( int ev, const error_category & ecat )
- : std::runtime_error(""), m_error_code(ev,ecat) {}
+
+ system_error( int ev, const error_category & ecat,
+ const char * what_arg )
+ : std::runtime_error(what_arg), m_error_code(ev,ecat) {}
 
       virtual ~system_error() throw() {}
 

Modified: branches/release/libs/system/doc/index.html
==============================================================================
--- branches/release/libs/system/doc/index.html (original)
+++ branches/release/libs/system/doc/index.html 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -11,10 +11,10 @@
 
 <body>
 
-<table border="0" cellpadding="5" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="637">
+<table border="0" cellpadding="5" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111">
   <tr>
     <td width="277">
-<a href="../../../index.htm">
+<a href="../../../index.html">
 <img src="../../../boost.png" alt="boost.png (6897 bytes)" align="middle" width="277" height="86" border="0"></a></td>
     <td width="337" align="middle">
     <font size="7">System Library</font>
@@ -132,14 +132,16 @@
 paper. Johan Nilsson's comments led to several of the refinements in N2066 .</p>
 <hr>
 
-<p>© Copyright Beman Dawes, 1999<br>
-Distributed under the Boost Software License, Version 1.0. See
-www.boost.org/LICENSE_1_0.txt</p>
-
 <p>Revised
-<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%B %d, %Y" startspan -->November 12, 2007<!--webbot bot="Timestamp" endspan i-checksum="39581" --> </font>
+<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%B %d, %Y" startspan -->February 23, 2008<!--webbot bot="Timestamp" endspan i-checksum="41408" --> </font>
 </p>
 
+<p>© Copyright Beman Dawes, 1999</p>
+
+<p>Distributed under the Boost Software License, Version 1.0.
+(See file LICENSE_1_0.txt
+or&nbsp; www.boost.org/LICENSE_1_0.txt) </p>
+
 </body>
 
 </html>
\ No newline at end of file

Modified: branches/release/libs/system/doc/reference.html
==============================================================================
--- branches/release/libs/system/doc/reference.html (original)
+++ branches/release/libs/system/doc/reference.html 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -132,10 +132,10 @@
     template< class T="" >
       struct is_error_condition_enum { static const bool value = false; };
 
- // portable error_conditions
- namespace posix_error
+ // generic error_conditions
+ namespace errc
     {
- enum posix_errno
+ enum errc_t
       {
         success = 0,
         address_family_not_supported, //EAFNOSUPPORT
@@ -218,9 +218,9 @@
         wrong_protocol_type //EPROTOTYPE
       };
 
- } // namespace posix_error
+ } // namespace errc
 
- template<> struct is_error_condition_enum<posix::posix_errno>&lt;posix_error::posix_errno&gt;
+ template<> struct is_error_condition_enum<posix::posix_errno>&lt;errc::errc_t&gt;
       { static const bool value = true; };
 
     bool operator==( const error_code &amp; lhs, const error_code &amp; rhs );
@@ -236,8 +236,8 @@
     bool operator&lt;( const error_code &amp; lhs, const error_code &amp; rhs );
     bool operator&lt;( const error_condition &amp; lhs, const error_condition &amp; rhs );
 
- error_code make_error_code( posix_error::posix_errno e );
- error_condition make_error_condition( posix_error::posix_errno e );
+ error_code make_error_code( errc::errc_t e );
+ error_condition make_error_condition( errc::errc_t e );
 
     template &lt;class charT, class traits&gt;
       std::basic_ostream&lt;charT,traits&gt;&amp;
@@ -247,7 +247,7 @@
   }
 }</pre>
 </blockquote>
-<p>The value of each<code> posix_errno</code> constant shall be the same as the
+<p>The value of each<code> errc_t</code> constant shall be the same as the
 value of the <code>&lt;cerrno&gt;</code> macro shown in the above synopsis.</p>
 <p>Users may specialize <code>is_error_code_enum</code> and <code>
 is_error_condition_enum</code> templates to indicate that a type is eligible for
@@ -290,10 +290,10 @@
     };
 
     const error_category &amp; get_system_category();
- const error_category &amp; get_posix_category();
+ const error_category &amp; get_generic_category();
 
     static const error_category &amp; system_category = get_system_category();
- static const error_category &amp; posix_category = get_posix_category();
+ static const error_category &amp; generic_category = get_generic_category();
   }
 }</pre>
 </blockquote>
@@ -316,7 +316,7 @@
   <p><i>Returns:</i>&nbsp; <code>error_condition( ev, *this )</code>.</p>
   <blockquote>
     <p>&nbsp;[<i>--Note:</i> Derived classes will typically convert <code>ev</code>
- to some portable <code>error_category</code>, such as <code>posix_category</code>,
+ to some portable <code>error_category</code>, such as <code>generic_category</code>,
     and return it as an <code>error_condition</code> for that category. <i>--end
     note</i>]</p>
   </blockquote>
@@ -361,7 +361,7 @@
   identifying errors originating from the operating system.</p>
   <p><i>Throws:</i> Nothing.</p>
 </blockquote>
-<pre>const error_category &amp; get_posix_category();</pre>
+<pre>const error_category &amp; get_generic_category();</pre>
 <blockquote>
   <p><i>Returns:</i> A reference to a <code>error_category</code> object
   identifying portable error conditions.</p>
@@ -370,7 +370,7 @@
 <h3><a name="Class-error_category-predefined-objects">Class <code>error_category</code>
 predefined objects</a></h3>
 <p>Predefined objects <code>system_category</code>
-and <code>posix_category</code> identify operating system error codes and portable error conditions, respectively.</p>
+and <code>generic_category</code> identify operating system error codes and portable error conditions, respectively.</p>
 <h2><a name="Class-error_code">Class <code>
 error_code</code></a></h2>
 <p>The class <code>error_code</code> describes an object used to hold error code
@@ -454,7 +454,7 @@
 </blockquote>
 <p><code>void clear();</code></p>
 <blockquote>
- <p><i>postcondition:</i> <code>value() == 0 &amp;&amp; category() == posix_category</code></p>
+ <p><i>postcondition:</i> <code>value() == 0 &amp;&amp; category() == generic_category</code></p>
 </blockquote>
   <h3><a name="Class-error_code-observers">Class <code>
 error_code</code> observers</a></h3>
@@ -538,7 +538,7 @@
 <pre>error_condition(); </pre>
 <blockquote>
   <p><i>Effects:</i> Constructs an object of type <code>error_condition</code>.</p>
- <p><i>Postconditions:</i> <code>val_ == 0 and cat_ == posix_category</code>.</p>
+ <p><i>Postconditions:</i> <code>val_ == 0 and cat_ == generic_category</code>.</p>
   <p><i>Throws:</i> Nothing.</p>
 </blockquote>
 <pre>error_condition( value_type val, const error_category &amp; cat );</pre>
@@ -571,7 +571,7 @@
 </blockquote>
 <p><code>void clear();</code></p>
 <blockquote>
- <p><i>postcondition:</i> <code>value() == 0 &amp;&amp; category() == posix_category</code></p>
+ <p><i>postcondition:</i> <code>value() == 0 &amp;&amp; category() == generic_category</code></p>
 </blockquote>
 <h3><a name="Class-error_condition-observers">Class <code>error_condition</code>
 observers</a></h3>
@@ -651,13 +651,13 @@
   &nbsp; || (lhs.category() == rhs.category() &amp;&amp; lhs.value() &lt; rhs.value())</code>.</p>
   <p><i>Throws: </i>Nothing.</p>
 </blockquote>
-<pre>error_code make_error_code( posix_error::posix_errno e );</pre>
+<pre>error_code make_error_code( errc::errc_t e );</pre>
 <blockquote>
- <p><i>Returns:</i> <code>error_code( e, posix_category)</code>.</p>
+ <p><i>Returns:</i> <code>error_code( e, generic_category)</code>.</p>
 </blockquote>
-<pre>error_condition make_error_condition( posix_error::posix_errno e );</pre>
+<pre>error_condition make_error_condition( errc::errc_t e );</pre>
 <blockquote>
- <p><i>Returns:</i> <code>error_condition( e, posix_category)</code>.</p>
+ <p><i>Returns:</i> <code>error_condition( e, generic_category)</code>.</p>
 </blockquote>
 
 <pre>template &lt;class charT, class traits&gt;
@@ -689,8 +689,11 @@
     {
     public:
       system_error( error_code ec );
+ system_error( error_code ec, const char * what_arg );
       system_error( error_code ec, const std::string &amp; what_arg );
       system_error( error_code::value_type ev, const error_category &amp; ecat,
+ const char * what_arg );
+ system_error( error_code::value_type ev, const error_category &amp; ecat,
                     const std::string &amp; what_arg );
       system_error( error_code::value_type ev, const error_category &amp; ecat);
 
@@ -706,6 +709,12 @@
   <p><i>Postcondition:</i> <code>code() == ec <br>
 &nbsp; &amp;&amp; std::strcmp( this-&gt;runtime_error::what(), &quot;&quot; ) == 0</code></p>
 </blockquote>
+<pre>system_error( error_code ec, const char * what_arg );</pre>
+<blockquote>
+ <p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
+ <p><i>Postcondition:</i> <code>code() == ec <br>
+&nbsp; &amp;&amp; std::strcmp( this-&gt;runtime_error::what(), what_arg ) == 0</code></p>
+</blockquote>
 <pre>system_error( error_code ec, const std::string &amp; what_arg );</pre>
 <blockquote>
   <p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
@@ -713,6 +722,13 @@
 &nbsp; &amp;&amp; std::strcmp( this-&gt;runtime_error::what(), what_arg.c_str() ) == 0</code></p>
 </blockquote>
 <pre>system_error( error_code::value_type ev, const error_category &amp; ecat,
+ const char * what_arg );</pre>
+<blockquote>
+ <p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
+ <p><i>Postcondition:</i> <code>code() == error_code( ev, ecat )<br>
+&nbsp; &amp;&amp; std::strcmp( this-&gt;runtime_error::what(), what_arg ) == 0</code></p>
+</blockquote>
+<pre>system_error( error_code::value_type ev, const error_category &amp; ecat,
              const std::string &amp; what_arg );</pre>
 <blockquote>
   <p><i>Effects:</i> Constructs an object of class <code>system_error</code>.</p>
@@ -743,7 +759,7 @@
 <a href="http://www.boost.org/LICENSE_1_0.txt">www.boost.org/LICENSE_1_0.txt</a></p>
 
 <p>Revised
-<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%B %d, %Y" startspan -->November 12, 2007<!--webbot bot="Timestamp" endspan i-checksum="39581" --> </font>
+<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%B %d, %Y" startspan -->June 25, 2008<!--webbot bot="Timestamp" endspan i-checksum="14296" --> </font>
 </p>
 
 </body>

Modified: branches/release/libs/system/src/error_code.cpp
==============================================================================
--- branches/release/libs/system/src/error_code.cpp (original)
+++ branches/release/libs/system/src/error_code.cpp 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -9,14 +9,7 @@
 
 //----------------------------------------------------------------------------//
 
-// VC++ 8.0 warns on usage of certain Standard Library and API functions that
-// can be cause buffer overruns or other possible security issues if misused.
-// See http://msdn.microsoft.com/msdnmag/issues/05/05/SafeCandC/default.aspx
-// But the wording of the warning is misleading and unsettling, there are no
-// portable alternative functions, and VC++ 8.0's own libraries use the
-// functions in question. So turn off the warnings.
-#define _CRT_SECURE_NO_DEPRECATE
-#define _SCL_SECURE_NO_DEPRECATE
+#include <boost/config/warning_disable.hpp>
 
 // define BOOST_SYSTEM_SOURCE so that <boost/system/config.hpp> knows
 // the library is being built (possibly exporting rather than importing code)
@@ -45,12 +38,12 @@
 
 namespace
 {
- // standard error categories -------------------------------------------//
+ // standard error categories ---------------------------------------------//
 
- class posix_error_category : public error_category
+ class generic_error_category : public error_category
   {
   public:
- posix_error_category(){}
+ generic_error_category(){}
     const char * name() const;
     std::string message( int ev ) const;
   };
@@ -64,14 +57,14 @@
     error_condition default_error_condition( int ev ) const;
   };
 
- // posix_error_category implementation ---------------------------------//
+ // generic_error_category implementation ---------------------------------//
 
- const char * posix_error_category::name() const
+ const char * generic_error_category::name() const
   {
- return "POSIX";
+ return "GENERIC";
   }
 
- std::string posix_error_category::message( int ev ) const
+ std::string generic_error_category::message( int ev ) const
   {
   // strerror_r is preferred because it is always thread safe,
   // however, we fallback to strerror in certain cases because:
@@ -325,7 +318,7 @@
 
   std::string system_error_category::message( int ev ) const
   {
- return posix_category.message( ev );
+ return generic_category.message( ev );
   }
 # else
 // TODO:
@@ -409,10 +402,10 @@
       return system_category_const;
     }
 
- BOOST_SYSTEM_DECL const error_category & get_posix_category()
+ BOOST_SYSTEM_DECL const error_category & get_generic_category()
     {
- static const posix_error_category posix_category_const;
- return posix_category_const;
+ static const generic_error_category generic_category_const;
+ return generic_category_const;
     }
 
   } // namespace system

Modified: branches/release/libs/system/test/Jamfile.v2
==============================================================================
--- branches/release/libs/system/test/Jamfile.v2 (original)
+++ branches/release/libs/system/test/Jamfile.v2 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -19,31 +19,24 @@
            : # command line
            : # input files
            : # requirements
- <define>BOOST_SYSTEM_STATIC_LINK
                    <link>static
          ]
          [ run error_code_test.cpp
- : : : <define>BOOST_SYSTEM_DYN_LINK
- : error_code_test_dll
+ : : : : error_code_test_dll
          ]
          [ run error_code_user_test.cpp
- : : : <define>BOOST_SYSTEM_STATIC_LINK
- <link>static
+ : : : <link>static
          ]
          [ run error_code_user_test.cpp
- : : : <define>BOOST_SYSTEM_DYN_LINK
- : error_code_user_test_dll
+ : : : : error_code_user_test_dll
          ]
          [ run system_error_test.cpp
- : : : <define>BOOST_SYSTEM_STATIC_LINK
- <link>static
+ : : : <link>static
          ]
          [ run system_error_test.cpp
- : : : <define>BOOST_SYSTEM_DYN_LINK
- : system_error_test_dll
+ : : : : system_error_test_dll
          ]
          [ run initialization_test.cpp
- : : : <define>BOOST_SYSTEM_DYN_LINK
          ]
          [ run header_only_test.cpp
            : : : <link>static

Modified: branches/release/libs/system/test/error_code_test.cpp
==============================================================================
--- branches/release/libs/system/test/error_code_test.cpp (original)
+++ branches/release/libs/system/test/error_code_test.cpp 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -9,14 +9,7 @@
 
 //----------------------------------------------------------------------------//
 
-// VC++ 8.0 warns on usage of certain Standard Library and API functions that
-// can cause buffer overruns or other possible security issues if misused.
-// See http://msdn.microsoft.com/msdnmag/issues/05/05/SafeCandC/default.aspx
-// But the wording of the warning is misleading and unsettling, there are no
-// portable alternative functions, and VC++ 8.0's own libraries use the
-// functions in question. So turn off the warnings.
-#define _CRT_SECURE_NO_DEPRECATE
-#define _SCL_SECURE_NO_DEPRECATE
+#include <boost/config/warning_disable.hpp>
 
 #include <boost/test/minimal.hpp>
 #include <boost/system/error_code.hpp>

Modified: branches/release/libs/system/test/header_only_test.cpp
==============================================================================
--- branches/release/libs/system/test/header_only_test.cpp (original)
+++ branches/release/libs/system/test/header_only_test.cpp 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -9,14 +9,7 @@
 
 //----------------------------------------------------------------------------//
 
-// VC++ 8.0 warns on usage of certain Standard Library and API functions that
-// can cause buffer overruns or other possible security issues if misused.
-// See http://msdn.microsoft.com/msdnmag/issues/05/05/SafeCandC/default.aspx
-// But the wording of the warning is misleading and unsettling, there are no
-// portable altersystem functions, and VC++ 8.0's own libraries use the
-// functions in question. So turn off the warnings.
-#define _CRT_SECURE_NO_DEPRECATE
-#define _SCL_SECURE_NO_DEPRECATE
+#include <boost/config/warning_disable.hpp>
 
 #define BOOST_ERROR_CODE_HEADER_ONLY
 

Modified: branches/release/libs/system/test/system_error_test.cpp
==============================================================================
--- branches/release/libs/system/test/system_error_test.cpp (original)
+++ branches/release/libs/system/test/system_error_test.cpp 2008-07-10 21:25:09 EDT (Thu, 10 Jul 2008)
@@ -9,18 +9,12 @@
 
 //----------------------------------------------------------------------------//
 
-// VC++ 8.0 warns on usage of certain Standard Library and API functions that
-// can cause buffer overruns or other possible security issues if misused.
-// See http://msdn.microsoft.com/msdnmag/issues/05/05/SafeCandC/default.aspx
-// But the wording of the warning is misleading and unsettling, there are no
-// portable alternative functions, and VC++ 8.0's own libraries use the
-// functions in question. So turn off the warnings.
-#define _CRT_SECURE_NO_DEPRECATE
-#define _SCL_SECURE_NO_DEPRECATE
+#include <boost/config/warning_disable.hpp>
 
 #include <boost/test/minimal.hpp>
 #include <boost/system/system_error.hpp>
 #include <iostream>
+#include <string>
 
 #ifdef BOOST_WINDOWS_API
 #include <windows.h>
@@ -29,6 +23,7 @@
 using boost::system::system_error;
 using boost::system::error_code;
 using boost::system::system_category;
+using std::string;
 
 #define TEST(x,v,w) test(#x,x,v,w)
 
@@ -58,29 +53,52 @@
 # endif
   }
 
- const boost::uint_least32_t uvalue = 1u;
+ const boost::uint_least32_t uvalue = 2u;
 }
 
 int test_main( int, char *[] )
 {
- // all combinations of constructors:
+ // all constructors, in the same order as they appear in the header:
 
- system_error se_0_m( error_code(0, system_category), "se_0_m" );
- system_error se_1_m( 1, system_category, "se_1_m" );
- system_error se_0_nm( error_code(0, system_category), "" );
- system_error se_1_nm( 1, system_category, "" );
- system_error se_0_nmx( error_code(0, system_category), "" );
- system_error se_1_nmx( 1, system_category, "" );
- system_error se_1u_m( uvalue, system_category, "se_1u_m" );
-
- TEST( se_0_m, 0, "se_0_m" );
- TEST( se_1_m, 1, "se_1_m: Incorrect function" );
- TEST( se_0_nm, 0, "" );
- TEST( se_1_nm, 1, "Incorrect function" );
- TEST( se_0_nmx, 0, "" );
- TEST( se_1_nmx, 1, "Incorrect function" );
- TEST( se_1u_m, 1, "se_1u_m: Incorrect function" );
+ system_error c1_0( error_code(0, system_category) );
+ system_error c1_1( error_code(1, system_category) );
+ system_error c1_2u( error_code(uvalue, system_category) );
 
+ system_error c2_0( error_code(0, system_category), string("c2_0") );
+ system_error c2_1( error_code(1, system_category), string("c2_1") );
+
+ system_error c3_0( error_code(0, system_category), "c3_0" );
+ system_error c3_1( error_code(1, system_category), "c3_1" );
+
+ system_error c4_0( 0, system_category );
+ system_error c4_1( 1, system_category );
+ system_error c4_2u( uvalue, system_category );
+
+ system_error c5_0( 0, system_category, string("c5_0") );
+ system_error c5_1( 1, system_category, string("c5_1") );
+
+ system_error c6_0( 0, system_category, "c6_0" );
+ system_error c6_1( 1, system_category, "c6_1" );
+
+ TEST( c1_0, 0, "" );
+ TEST( c1_1, 1, "Incorrect function" );
+ TEST( c1_2u, 2, "The system cannot find the file specified" );
+
+ TEST( c2_0, 0, "c2_0" );
+ TEST( c2_1, 1, "c2_1: Incorrect function" );
+
+ TEST( c3_0, 0, "c3_0" );
+ TEST( c3_1, 1, "c3_1: Incorrect function" );
+
+ TEST( c4_0, 0, "" );
+ TEST( c4_1, 1, "Incorrect function" );
+ TEST( c4_2u, 2, "The system cannot find the file specified" );
+
+ TEST( c5_0, 0, "c5_0" );
+ TEST( c5_1, 1, "c5_1: Incorrect function" );
+
+ TEST( c6_0, 0, "c6_0" );
+ TEST( c6_1, 1, "c6_1: Incorrect function" );
 
   return 0;
 }


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