[#mp_units-explicitly_convertible]
= xref:mp_units.adoc[mp&lowbar;units]::explicitly&lowbar;convertible
:relfileprefix: ../
:mrdocs:

Checks whether a quantity of quantity spec `From` can be explicitly converted to quantity spec `To`

== Synopsis

Declared in `&lt;mp&hyphen;units&sol;framework&sol;quantity&lowbar;spec&lowbar;concepts&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    xref:mp_units/QuantitySpec.adoc[QuantitySpec] From,
    xref:mp_units/QuantitySpec.adoc[QuantitySpec] To&gt;
&lsqb;&lsqb;nodiscard&rsqb;&rsqb;
consteval
bool
explicitly&lowbar;convertible(
    From from,
    To to);
----

== Return Value

`true` if `from` is explicitly convertible to `to`

[NOTE]
====
The return value https://en.cppreference.com/cpp/language/attributes/nodiscard[should not be discarded^].
====
== Template Parameters

[cols="1,4"]
|===
| Name| Description
| *From*
| source quantity specification type
| *To*
| target quantity specification type
|===

== Parameters

[cols="1,4"]
|===
| Name| Description
| *from*
| source quantity specification value
| *to*
| target quantity specification value
|===


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