mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-15 11:57:57 -05:00
fixed_point: Use variable templates and concepts where applicable
Makes a few things a little less noisy and removes the need for SFINAE in quite a few functions.
This commit is contained in:
@ -34,4 +34,12 @@ concept DerivedFrom = requires {
|
||||
template <typename From, typename To>
|
||||
concept ConvertibleTo = std::is_convertible_v<From, To>;
|
||||
|
||||
// No equivalents in the stdlib
|
||||
|
||||
template <typename T>
|
||||
concept IsArithmetic = std::is_arithmetic_v<T>;
|
||||
|
||||
template <typename T>
|
||||
concept IsIntegral = std::is_integral_v<T>;
|
||||
|
||||
} // namespace Common
|
||||
|
Reference in New Issue
Block a user