std::locale::operator==, operator!= - cppreference.com

##### cppreference.com

##### Search

Create account

##### Namespaces

- Page
- Discussion

##### Variants

##### Views

- View
- Edit
- History

##### Actions

# std::locale::operator==, operator!=

From cppreference.com
< cpp‎ | locale‎ | locale

Defined in header `<locale>` |  |
bool operator==( const locale& other ) const; | (1) |
bool operator!=( const locale& other ) const; | (2) |

Tests two locales for equality. Named locales are considered equal if their names are equal. Unnamed locales are considered equal if they are copies of each other.

### [edit] Parameters

other | - | a std::locale object to compare

### [edit] Return value

1) true if `other` is a copy of *this or has an identical name, false otherwise.

2) false if `other` is a copy of *this or has an identical name, true otherwise.

### [edit] Example

| This section is incomplete Reason: no example

### [edit] See also

(constructor) | constructs a new locale (public member function) [edit]
name | returns the name of the locale or "*" if unnamed (public member function) [edit]

Retrieved from "http://en.cppreference.com/mwiki/index.php?title=cpp/locale/locale/operator_cmp&oldid=58159"
Category:

- Todo no example