[#bsl-operator_eq-058]
= xref:bsl.adoc[bsl]::operator&equals;&equals;
:relfileprefix: ../
:mrdocs:

Return `true` if `lhs` and `rhs` are equal&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;variant&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class t&lowbar;HEAD,
    class&period;&period;&period; t&lowbar;TAIL&gt;
bool
operator&equals;&equals;(
    xref:bsl/variant.adoc[variant&lt;t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;&gt;] const& lhs,
    xref:bsl/variant.adoc[variant&lt;t&lowbar;HEAD, t&lowbar;TAIL&period;&period;&period;&gt;] const& rhs);
----

== Description

Return `true` if the specified `lhs` and `rhs` are both valueless by exception or if they have the same active alternative and their contained values compare equal&semi; otherwise, return `false`&period; All alternatives shall support `operator&equals;&equals;`&period;

== Return Value

`true` if `lhs` and `rhs` are equal

== Parameters

[cols="1,4"]
|===
| Name| Description
| *lhs*
| variant to compare
| *rhs*
| variant to compare
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
