From db9b863222dbd51154c422cf85bc8fafacd5b25b Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Wed, 15 Mar 2017 17:55:34 +0000 Subject: Migrate WithBitOps template specialization to with_bit_ops function This way we dont depend on knowing the base template to enable bit ops on an enum type. --- src/shell_manager.hh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/shell_manager.hh') diff --git a/src/shell_manager.hh b/src/shell_manager.hh index 1336ca9b..df2429d6 100644 --- a/src/shell_manager.hh +++ b/src/shell_manager.hh @@ -3,7 +3,6 @@ #include "array_view.hh" #include "env_vars.hh" -#include "flags.hh" #include "string.hh" #include "utils.hh" #include "completion.hh" @@ -31,6 +30,7 @@ public: None = 0, WaitForStdout = 1 }; + friend constexpr bool with_bit_ops(Meta::Type) { return true; } std::pair eval(StringView cmdline, const Context& context, StringView input = {}, @@ -49,8 +49,6 @@ private: Vector m_env_vars; }; -template<> struct WithBitOps : std::true_type {}; - } #endif // shell_manager_hh_INCLUDED -- cgit v1.2.3