[#bsl-operator_lt-01d]
= xref:bsl.adoc[bsl]::operator&lt;
:relfileprefix: ../
:mrdocs:

Return `true` if the index of the active alternative in the specified `lhs` is less than that of the specified `rhs`, or if both have the same active alternative and the contained value of `lhs` compares less than that of `rhs`, or if `lhs` is valueless by exception and `rhs` is not&semi; otherwise, return `false`&period; All alternatives shall support `operator&lt;`&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&lt;(
    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);
----


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