openMSX
Functions
cstd Namespace Reference

Functions

template<typename Iter1 , typename Iter2 >
constexpr void iter_swap (Iter1 a, Iter2 b)
 
template<typename InputIt , typename UnaryPredicate >
constexpr InputIt find_if_not (InputIt first, InputIt last, UnaryPredicate p)
 
template<typename ForwardIt , typename UnaryPredicate >
constexpr ForwardIt partition (ForwardIt first, ForwardIt last, UnaryPredicate p)
 
template<typename RAIt , typename Compare = std::less<>>
constexpr void sort (RAIt first, RAIt last, Compare cmp=Compare{})
 
template<typename RandomAccessRange , typename Compare = std::less<>>
constexpr void sort (RandomAccessRange &&range, Compare cmp=Compare{})
 
template<typename InputIt1 , typename InputIt2 >
constexpr bool lexicographical_compare (InputIt1 first1, InputIt1 last1, InputIt2 first2, InputIt2 last2)
 
template<typename ForwardIt , typename T >
constexpr void replace (ForwardIt first, ForwardIt last, const T &old_value, const T &new_value)
 
template<typename ForwardRange , typename T >
constexpr void replace (ForwardRange &range, const T &old_value, const T &new_value)
 
template<typename ForwardIt , typename T >
constexpr void fill (ForwardIt first, ForwardIt last, const T &value)
 
template<typename ForwardRange , typename T >
constexpr void fill (ForwardRange &range, const T &value)
 
template<typename T >
constexpr T abs (T t)
 
constexpr double upow (double x, unsigned u)
 
constexpr double ipow (double x, int i)
 
template<int ITERATIONS>
constexpr double exp (double x)
 
constexpr double simple_fmod (double x, double y)
 
template<int ITERATIONS>
constexpr double sin_iter (double x)
 
template<int ITERATIONS>
constexpr double cos_iter (double x)
 
template<int ITERATIONS>
constexpr double sin (double x)
 
template<int ITERATIONS>
constexpr double cos (double x)
 
template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double log (double x)
 
template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double log2 (double x)
 
template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double log10 (double x)
 
template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double pow (double x, double y)
 
template<int ITERATIONS>
constexpr double exp2 (double x)
 
constexpr double round (double x)
 
constexpr float round (float x)
 
constexpr double sqrt (double x)
 

Function Documentation

◆ abs()

template<typename T >
constexpr T cstd::abs ( t)
constexpr

Definition at line 124 of file cstd.hh.

References t.

◆ cos()

template<int ITERATIONS>
constexpr double cstd::cos ( double  x)
constexpr

Definition at line 280 of file cstd.hh.

◆ cos_iter()

template<int ITERATIONS>
constexpr double cstd::cos_iter ( double  x)
constexpr

Definition at line 225 of file cstd.hh.

References t, and openmsx::x.

◆ exp()

template<int ITERATIONS>
constexpr double cstd::exp ( double  x)
constexpr

Definition at line 166 of file cstd.hh.

References M_E, t, upow(), and openmsx::x.

◆ exp2()

template<int ITERATIONS>
constexpr double cstd::exp2 ( double  x)
constexpr

Definition at line 349 of file cstd.hh.

References M_LN2, and openmsx::x.

◆ fill() [1/2]

template<typename ForwardIt , typename T >
constexpr void cstd::fill ( ForwardIt  first,
ForwardIt  last,
const T &  value 
)
constexpr

Definition at line 110 of file cstd.hh.

Referenced by PerfectMinimalHash::create(), and fill().

◆ fill() [2/2]

template<typename ForwardRange , typename T >
constexpr void cstd::fill ( ForwardRange &  range,
const T &  value 
)
constexpr

Definition at line 118 of file cstd.hh.

References fill().

◆ find_if_not()

template<typename InputIt , typename UnaryPredicate >
constexpr InputIt cstd::find_if_not ( InputIt  first,
InputIt  last,
UnaryPredicate  p 
)
constexpr

Definition at line 35 of file cstd.hh.

Referenced by partition().

◆ ipow()

constexpr double cstd::ipow ( double  x,
int  i 
)
constexpr

Definition at line 160 of file cstd.hh.

References upow(), and openmsx::x.

◆ iter_swap()

template<typename Iter1 , typename Iter2 >
constexpr void cstd::iter_swap ( Iter1  a,
Iter2  b 
)
constexpr

Definition at line 27 of file cstd.hh.

Referenced by partition().

◆ lexicographical_compare()

template<typename InputIt1 , typename InputIt2 >
constexpr bool cstd::lexicographical_compare ( InputIt1  first1,
InputIt1  last1,
InputIt2  first2,
InputIt2  last2 
)
constexpr

Definition at line 83 of file cstd.hh.

◆ log()

template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double cstd::log ( double  x)
constexpr

Definition at line 315 of file cstd.hh.

References M_E, and openmsx::x.

Referenced by openmsx::Disk::logToPhys().

◆ log10()

template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double cstd::log10 ( double  x)
constexpr

Definition at line 337 of file cstd.hh.

References M_LN10, and openmsx::x.

◆ log2()

template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double cstd::log2 ( double  x)
constexpr

Definition at line 331 of file cstd.hh.

References M_LN2, and openmsx::x.

◆ partition()

template<typename ForwardIt , typename UnaryPredicate >
constexpr ForwardIt cstd::partition ( ForwardIt  first,
ForwardIt  last,
UnaryPredicate  p 
)
constexpr

Definition at line 46 of file cstd.hh.

References find_if_not(), and iter_swap().

◆ pow()

template<int E_ITERATIONS, int L_ITERATIONS>
constexpr double cstd::pow ( double  x,
double  y 
)
constexpr

Definition at line 343 of file cstd.hh.

References openmsx::x.

◆ replace() [1/2]

template<typename ForwardIt , typename T >
constexpr void cstd::replace ( ForwardIt  first,
ForwardIt  last,
const T &  old_value,
const T &  new_value 
)
constexpr

Definition at line 94 of file cstd.hh.

Referenced by replace().

◆ replace() [2/2]

template<typename ForwardRange , typename T >
constexpr void cstd::replace ( ForwardRange &  range,
const T &  old_value,
const T &  new_value 
)
constexpr

Definition at line 104 of file cstd.hh.

References replace().

◆ round() [1/2]

constexpr double cstd::round ( double  x)
constexpr

Definition at line 354 of file cstd.hh.

References openmsx::x.

◆ round() [2/2]

constexpr float cstd::round ( float  x)
constexpr

Definition at line 360 of file cstd.hh.

References openmsx::x.

◆ simple_fmod()

constexpr double cstd::simple_fmod ( double  x,
double  y 
)
constexpr

Definition at line 197 of file cstd.hh.

References openmsx::x.

◆ sin()

template<int ITERATIONS>
constexpr double cstd::sin ( double  x)
constexpr

Definition at line 246 of file cstd.hh.

◆ sin_iter()

template<int ITERATIONS>
constexpr double cstd::sin_iter ( double  x)
constexpr

Definition at line 204 of file cstd.hh.

References t, and openmsx::x.

◆ sort() [1/2]

template<typename RAIt , typename Compare = std::less<>>
constexpr void cstd::sort ( RAIt  first,
RAIt  last,
Compare  cmp = Compare{} 
)
constexpr

Definition at line 63 of file cstd.hh.

Referenced by PerfectMinimalHash::create().

◆ sort() [2/2]

template<typename RandomAccessRange , typename Compare = std::less<>>
constexpr void cstd::sort ( RandomAccessRange &&  range,
Compare  cmp = Compare{} 
)
constexpr

Definition at line 77 of file cstd.hh.

◆ sqrt()

constexpr double cstd::sqrt ( double  x)
constexpr

Definition at line 366 of file cstd.hh.

References openmsx::x.

Referenced by PerfectMinimalHash::create(), gl::length(), and gl::rsqrt().

◆ upow()

constexpr double cstd::upow ( double  x,
unsigned  u 
)
constexpr

Definition at line 149 of file cstd.hh.

References openmsx::x.

Referenced by exp(), and ipow().