diff options
Diffstat (limited to 'src/mbgl/map/update.hpp')
-rw-r--r-- | src/mbgl/map/update.hpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/mbgl/map/update.hpp b/src/mbgl/map/update.hpp index 82d98284f5..ab8b10c651 100644 --- a/src/mbgl/map/update.hpp +++ b/src/mbgl/map/update.hpp @@ -1,6 +1,7 @@ #pragma once #include <mbgl/util/traits.hpp> +#include <mbgl/util/util.hpp> namespace mbgl { @@ -11,15 +12,15 @@ enum class Update { AnnotationData = 1 << 7 }; -constexpr Update operator|(Update lhs, Update rhs) { +MBGL_CONSTEXPR Update operator|(Update lhs, Update rhs) { return Update(mbgl::underlying_type(lhs) | mbgl::underlying_type(rhs)); } -constexpr Update& operator|=(Update& lhs, const Update& rhs) { +MBGL_CONSTEXPR Update& operator|=(Update& lhs, const Update& rhs) { return (lhs = lhs | rhs); } -constexpr bool operator& (Update lhs, Update rhs) { +MBGL_CONSTEXPR bool operator& (Update lhs, Update rhs) { return mbgl::underlying_type(lhs) & mbgl::underlying_type(rhs); } |