summaryrefslogtreecommitdiff
path: root/src/event_manager.hh
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2017-03-15 17:55:34 +0000
committerMaxime Coste <mawww@kakoune.org>2017-03-15 18:00:58 +0000
commitdb9b863222dbd51154c422cf85bc8fafacd5b25b (patch)
treec64d4a42ff62372736d747a1ab25568954ba6e32 /src/event_manager.hh
parenta49e175727928b8b45c0c2ccdb01f143ea6d18c2 (diff)
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.
Diffstat (limited to 'src/event_manager.hh')
-rw-r--r--src/event_manager.hh4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/event_manager.hh b/src/event_manager.hh
index f4fa503e..e83672b9 100644
--- a/src/event_manager.hh
+++ b/src/event_manager.hh
@@ -2,8 +2,8 @@
#define event_manager_hh_INCLUDED
#include "clock.hh"
+#include "meta.hh"
#include "utils.hh"
-#include "flags.hh"
#include "vector.hh"
#include <functional>
@@ -28,7 +28,7 @@ enum class FdEvents
Except = 1 << 2,
};
-template<> struct WithBitOps<FdEvents> : std::true_type {};
+constexpr bool with_bit_ops(Meta::Type<FdEvents>) { return true; }
class FDWatcher
{