Universal Numbers Library C++ API
sw::universal -- header-only custom arithmetic types (posit, cfloat, lns, fixpnt, dd/qd, and more)
Loading...
Searching...
No Matches
cross_type_traits.hpp File Reference
#include <type_traits>
#include <concepts>
#include <limits>
#include <string_view>

Classes

struct  sw::universal::is_universal_arithmetic< T, typename >
struct  sw::universal::is_universal_arithmetic< T, std::void_t< decltype(static_cast< double >(std::declval< const T & >())), decltype(std::declval< const T & >().iszero()), decltype(std::declval< const T & >().sign()), decltype(T{}) > >
struct  sw::universal::precision_bits< T, typename >
struct  sw::universal::precision_bits< T, std::void_t< decltype(T::fbits)> >

Namespaces

namespace  sw
 required std libraries
namespace  sw::universal
namespace  sw::universal::detail

Concepts

concept  sw::universal::UniversalNumber
concept  sw::universal::UniversalFloatingPoint

Typedefs

template<typename T1, typename T2>
using sw::universal::promote_t

Functions

template<typename T>
constexpr bool sw::universal::detail::has_limits ()
template<typename T>
constexpr long sw::universal::detail::promotion_max_exponent ()
template<typename T>
constexpr long sw::universal::detail::promotion_digits ()
template<typename T>
constexpr long sw::universal::detail::promotion_min_exponent ()
template<typename T>
constexpr std::string_view sw::universal::detail::promotion_type_name ()
template<typename T1, typename T2>
constexpr bool sw::universal::detail::promotion_ranks_above ()

Variables

template<typename T>
constexpr bool sw::universal::is_universal_arithmetic_v = is_universal_arithmetic<T>::value
template<typename T>
constexpr unsigned sw::universal::precision_bits_v
template<typename T>
constexpr bool sw::universal::detail::has_limits_v = has_limits<T>()