diff options
-rw-r--r-- | compat/map.hpp | 9 | ||||
-rw-r--r-- | editor/camera.cpp | 1 | ||||
-rw-r--r-- | editor/editor.hpp | 2 |
3 files changed, 11 insertions, 1 deletions
diff --git a/compat/map.hpp b/compat/map.hpp index 3c1610d4..7983a805 100644 --- a/compat/map.hpp +++ b/compat/map.hpp @@ -14,6 +14,11 @@ constexpr auto map0(const F& fun, const std::array<T, N>& array, std::index_sequ return std::array { fun(array[Indexes])... }; } +#ifdef _MSC_VER +#pragma warning(push) +#pragma warning(disable : 4996) +#endif + template<typename T, typename F> [[deprecated("zero-length array!")]] CORRADE_ALWAYS_INLINE @@ -22,6 +27,10 @@ constexpr auto map0(const F&, const std::array<T, 0>&, std::index_sequence<>) return std::array<std::decay_t<std::invoke_result_t<std::decay_t<F>, const std::remove_cvref_t<T>&>>, 0>{}; } +#ifdef _MSC_VER +#pragma warning(pop) +#endif + } // namespace floormat::detail::map namespace floormat { diff --git a/editor/camera.cpp b/editor/camera.cpp index b74b048a..9e673ae9 100644 --- a/editor/camera.cpp +++ b/editor/camera.cpp @@ -6,6 +6,7 @@ #include "src/object.hpp" #include "src/world.hpp" #include "src/camera-offset.hpp" +#include <bit> #include <algorithm> namespace floormat { diff --git a/editor/editor.hpp b/editor/editor.hpp index 69a5277f..b4e4ff8e 100644 --- a/editor/editor.hpp +++ b/editor/editor.hpp @@ -68,7 +68,7 @@ public: Optional<global_coords> mouse_drag_pos(); using snap_mode = editor_snap_mode; - using button = enum editor_button; + using button = editor_button; }; } // namespace floormat |