E.V.E  0.1-beta

◆ minf

eve::minf = {}
inlineconstexpr

Callable object computing the negative infinity value.

Required header: #include <eve/function/minf.hpp>

Member Effect
operator() Computes the minf constant

tempate < floating_value T > T operator()( as<T> const & t) const noexcept;
Lightweight type-wrapper.
Definition: as.hpp:29

Parameters

t: Type wrapper instance embedding the type of the constant.

Return value

the call eve::minf(as<T>()) is semantically equivalent to T(-std::numeric_limits<t_t>::infinity())


Example

See it live on Compiler Explorer

#include <eve/constant/minf.hpp>
#include <eve/wide.hpp>
#include <iostream>
using wide_ft = eve::wide<float>;
int main()
{
wide_ft wxf;
std::cout << "---- simd" << std::endl
<< "-> minf(as<wide_ft>()) = " << eve::minf(eve::as<wide_ft>()) << std::endl
<< "-> minf(as(wxf)) = " << eve::minf(eve::as(wxf)) << std::endl;
double xf;
std::cout << "---- scalar" << std::endl
<< "-> minf(as<float>()) = " << eve::minf(eve::as(float())) << std::endl
<< "-> minf(as<xf)) = " << eve::minf(eve::as(xf)) << std::endl;
return 0;
}
constexpr callable_minf_ minf
Callable object computing the negative infinity value.
Definition: minf.hpp:55
Wrapper for SIMD registers.
Definition: wide.hpp:65