mp_units::utility

Namespaces

Name
detail

Types

NameDescription
constrained A transparent wrapper that carries an error policy for domain constraint enforcement.
safe_int Wraps an integral type with overflow detection.
safe_int_terminate_policy Error policy that terminates the program on overflow (always available, freestanding-safe).
safe_int_throw_policy Error policy that throws std::overflow_error on overflow (hosted only).
terminate_policy Error policy that terminates the program on constraint violation (freestanding-safe).
throw_policy Error policy that throws std::domain_error on constraint violation (hosted only).
unspecified_t Sentinel default for a specializable variable-template customization point with no usable default.

Type Aliases

Name
safe_i16
safe_i32
safe_i64
safe_i8
safe_u16
safe_u32
safe_u64
safe_u8

Functions

NameDescription
operator% Modulus operators
operator* Multiplication operators
operator+ Unary plus operators
operator- Unary minus operators
operator/ Division operators
operator<< Stream insertion operator
operator== Equality operators
operator<=> Three-way comparison operators

Variables

Name
unspecified

Concepts

NameDescription
Complex A complex-field representation type.
ComplexScalar A complex scalar: complex field with real()/imag()/modulus().
ConstraintPolicy
OverflowPolicy
Real A real-field representation type.
RealScalar A real scalar (tensor order 0): real field, totally ordered, self-scalable.
Scalar A scalar (real or complex, tensor order 0) - the element type a vector/tensor is built from.
Tensor A second-order tensor (or a lower-order type filling its slot).
Vector A vector (a scalar, or a magnitude-bearing tensor-order-1 type).
specified Satisfied when a customization point has been given a value (i.e. is not unspecified).