diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2023-02-08 21:00:44 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2023-02-08 21:00:44 +0100 |
commit | 2489c453c0b6cd93a9ade17d42b7aad4ec238750 (patch) | |
tree | 534ec50ce3613c4db61c3fbb246ca1dad0b8a000 /compat | |
parent | 55809dbf9b750b24321f72a0394b432316943a66 (diff) |
compat/prelude: don't declare size_t in global namespace
Diffstat (limited to 'compat')
-rw-r--r-- | compat/prelude.hpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/compat/prelude.hpp b/compat/prelude.hpp index 30273a31..ab2fdfd2 100644 --- a/compat/prelude.hpp +++ b/compat/prelude.hpp @@ -1,5 +1,6 @@ #pragma once +namespace floormat::types { #ifdef _MSC_VER #if defined _WIN64 typedef unsigned __int64 size_t; @@ -9,6 +10,7 @@ typedef unsigned int size_t; #else typedef __SIZE_TYPE__ size_t; #endif +} // namespace floormat::types namespace Corrade::Containers { @@ -30,9 +32,9 @@ template<typename T> class Vector3; template<typename T> class Vector4; } // namespace Magnum::Math namespace Magnum { -using Vector2uz = Math::Vector2<::size_t>; -using Vector3uz = Math::Vector3<::size_t>; -using Vector4uz = Math::Vector4<::size_t>; +using Vector2uz = Math::Vector2<floormat::types::size_t>; +using Vector3uz = Math::Vector3<floormat::types::size_t>; +using Vector4uz = Math::Vector4<floormat::types::size_t>; } // namespace Magnum namespace floormat { @@ -40,6 +42,7 @@ namespace floormat { using namespace ::Corrade::Containers; using namespace ::Corrade::Containers::Literals; using namespace ::Magnum::Math::Literals; + using namespace ::floormat::types; using Debug [[maybe_unused]] = ::Corrade::Utility::Debug; using Error [[maybe_unused]] = ::Corrade::Utility::Error; namespace Path = Corrade::Utility::Path; // NOLINT(misc-unused-alias-decls) |