From 9a0822c445e56580fb3034224191ec825ea0274a Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Fri, 13 Oct 2017 15:05:05 +0200 Subject: options/tie: change "tie" overloads Adjust usages. There are ODR issues with MSVC and it doesn't support C++17 "static inline constexpr" _variables_. Otherwise, "signal_fun" could be a variable and not a function. The usages in accela/ewma2 dialog are more verbose now but the original API was silly. --- compat/util.hpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'compat') diff --git a/compat/util.hpp b/compat/util.hpp index c0d3e3fd..41c8def9 100644 --- a/compat/util.hpp +++ b/compat/util.hpp @@ -8,6 +8,7 @@ #include "macros.hpp" #include "value-templates.hpp" +#include #include #include #include @@ -80,3 +81,8 @@ inline auto clamp(const t& val, const u& min, const w& max) using tp = decltype(val + min + max); return ::util_detail::clamp, tp>::clamp_(val, min, max); } + +template +using cv_qualified = std::conditional_t>, std::decay_t, const t&>; + + -- cgit v1.2.3