Skyward boardcore
Loading...
Searching...
No Matches
Numeric.h File Reference
#include <cstring>
#include <limits>
#include <type_traits>
Include dependency graph for Numeric.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  detail
 
namespace  std
 

Functions

template<class T >
auto detail::add_sat (T x, T y) noexcept -> typename std::enable_if_t< std::is_integral< T >::value, T >
 Computes the saturating addition x + y for integral types.
 
template<typename To , typename From >
auto detail::bit_cast (const From &src) noexcept -> typename std::enable_if_t< sizeof(To)==sizeof(From) &&std::is_trivially_copyable< To >::value &&std::is_trivially_copyable< From >::value, To >
 Obtain a value of type To by reinterpreting the object representation of From.
 

Detailed Description

contains utility functions for numeric types, possibly from newer C++ standards.

Definition in file Numeric.h.