#ifndef SPROUT_RATIONAL_CONVERSION_HPP #define SPROUT_RATIONAL_CONVERSION_HPP #include #include namespace sprout { // // rational_cast // template inline SPROUT_CONSTEXPR T rational_cast(sprout::rational const& src) { return static_cast(src.numerator()) / static_cast(src.denominator()); } } // namespace sprout #endif // SPROUT_RATIONAL_CONVERSION_HPP