From 5000d814afeefd7eb7f250888b76d6723790f762 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 18 Oct 2022 12:54:53 -0400 Subject: 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. --- src/common/concepts.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/common/concepts.h') diff --git a/src/common/concepts.h b/src/common/concepts.h index a97555f6a..e8ce30dfe 100644 --- a/src/common/concepts.h +++ b/src/common/concepts.h @@ -34,4 +34,12 @@ concept DerivedFrom = requires { template concept ConvertibleTo = std::is_convertible_v; +// No equivalents in the stdlib + +template +concept IsArithmetic = std::is_arithmetic_v; + +template +concept IsIntegral = std::is_integral_v; + } // namespace Common -- cgit v1.2.3