[#util-Overloaded]
= xref:util.adoc[util]::Overloaded
:relfileprefix: ../
:mrdocs:

Overloaded helper for std&colon;&colon;visit&period; This helper and std&colon;&colon;visit in general are useful to write code that switches on a variant type&period; Unlike if&sol;else&hyphen;if and switch&sol;case statements, std&colon;&colon;visit will trigger compile errors if there are unhandled cases&period;

== Synopsis

Declared in `&lt;util&sol;overloaded&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class&period;&period;&period; Ts&gt;
struct Overloaded
    : Ts&period;&period;&period;
----

== Description

Implementation comes from and example usage can be found at https&colon;&sol;&sol;en&period;cppreference&period;com&sol;w&sol;cpp&sol;utility&sol;variant&sol;visit&num;Example

== Base Classes

[cols="1,4"]
|===
| Name| Description
| `Ts&period;&period;&period;`
| 
|===

== Using Declarations

[cols="1"]
|===
| Name
| xref:util/Overloaded/operator().adoc[`operator()`] 
|===



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