Sfoglia il codice sorgente

test: suppress a few warnings (memory)

Michele Caini 3 anni fa
parent
commit
9f22a3e23a
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 2 2
      test/entt/core/memory.cpp

+ 2 - 2
test/entt/core/memory.cpp

@@ -60,8 +60,8 @@ TEST(NextPowerOfTwo, Functionalities) {
     ASSERT_EQ(entt::next_power_of_two(17u), 32u);
     ASSERT_EQ(entt::next_power_of_two(32u), 32u);
     ASSERT_EQ(entt::next_power_of_two(33u), 64u);
-    ASSERT_EQ(entt::next_power_of_two(std::pow(2, 16)), std::pow(2, 16));
-    ASSERT_EQ(entt::next_power_of_two(std::pow(2, 16) + 1u), std::pow(2, 17));
+    ASSERT_EQ(entt::next_power_of_two(static_cast<std::size_t>(std::pow(2, 16))), static_cast<std::size_t>(std::pow(2, 16)));
+    ASSERT_EQ(entt::next_power_of_two(static_cast<std::size_t>(std::pow(2, 16) + 1u)), static_cast<std::size_t>(std::pow(2, 17)));
 }
 
 ENTT_DEBUG_TEST(NextPowerOfTwoDeathTest, Functionalities) {