Arene Base
Fundamental Utilities For Safety Critical C++
Loading...
Searching...
No Matches
std::ratio_detail Namespace Reference

Function Documentation

◆ can_directly_compare()

auto std::ratio_detail::can_directly_compare ( fraction const & left,
fraction const & right ) -> bool
constexprnoexcept

Check if two fractions can be directly compared (by cross multiplying them) without overflowing.

Parameters
leftThe left side of the comparison
rightThe right side of the comparison
Returns
true if left < right can be directly computed without overflowing; false if not

◆ fraction_less()

auto std::ratio_detail::fraction_less ( fraction left,
fraction right ) -> bool
constexprnoexcept

Check if the left fraction is less than the right or not.

Parameters
leftThe fraction on the left side of the comparison
rightThe fraction on the right side of the comparison
Returns
true if left < right, false if not