E.V.E
v2023.02.15
 
Loading...
Searching...
No Matches

◆ convert

eve::convert = functor<convert_t>
inlineconstexpr

Defined in Header

#include <eve/module/core.hpp>

Callable Signatures

namespace eve
{
template<value T, scalar_value Target>
Target convert( T x, as_<Target> t) noexcept
}
constexpr auto convert
Converts a value to another type.
Definition: convert.hpp:90
EVE Main Namespace.
Definition: abi.hpp:18

Parameters

Return value

  • Elementwise conversion of x in the Target type is returned.
Note
  • Conversion operated by eve::convert follows the regular rules of C++ type conversion, including the cases leading to Undefined Behaviors.

Example

Semantic Modifiers

  • eve::saturated

    The expression convert[saturated](x,t) computes a saturated conversion of x to the type wrapped by t.