Namespaces
Variants
Views
Actions

std::error_condition::operator==,!=,<

From cppreference.com
< cpp‎ | error‎ | error condition
Revision as of 06:16, 2 December 2012 by P12 (Talk | contribs)

 
 
 
 
 

Template:ddcl list begin <tr class="t-dsc-header">

<td>
Defined in header <system_error>
</td>

<td></td> <td></td> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator==( const error_condition& lhs, const error_condition& rhs );
</td>

<td > (1) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator==( const error_code& lhs, const error_condition& rhs );
</td>

<td > (2) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator==( const error_condition& lhs, const error_code& rhs );
</td>

<td > (2) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator!=( const error_condition& lhs, const error_condition& rhs );
</td>

<td > (3) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator!=( const error_code& lhs, const error_condition& rhs );
</td>

<td > (4) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator!=( const error_condition& lhs, const error_code& rhs );
</td>

<td > (4) </td> <td > (since C++11) </td> </tr> <tr class="t-dcl-sep"><td></td><td></td><td></td></tr>

<tr class="t-dcl ">

<td >
bool operator<( const error_condition& lhs, const error_condition& rhs );
</td>

<td > (5) </td> <td > (since C++11) </td> </tr> Template:ddcl list end

Compares two error conditions.

1-2) Checks whether lhs and rhs are equal.
3-4) Checks whether lhs and rhs are not equal.
5) Checks whether lhs is less than rhs.

Parameters

lhs, rhs - error conditions to compare

Return value

1) true if the error category and error value compare equal.
2) true if lhs.category().equivalent(rhs.value(), lhs) or rhs.category().equivalent(lhs.value(), rhs) is true.
3) true if the error category or error value compare are not equal.
4) true if lhs.category().equivalent(rhs.value(), lhs) and rhs.category().equivalent(lhs.value(), rhs) is false.
5) true if lhs.category() < rhs.category(). Otherwise, true if lhs.category() == rhs.category() && lhs.value() < rhs.value(). Otherwise, false.

Exceptions

noexcept specification:  
noexcept