Selaa lähdekoodia

Fixed test warnings

Christophe Riccio 8 vuotta sitten
vanhempi
sitoutus
f445a24f82
2 muutettua tiedostoa jossa 9 lisäystä ja 6 poistoa
  1. 3 3
      test/core/core_type_vec2.cpp
  2. 6 3
      test/core/core_type_vec4.cpp

+ 3 - 3
test/core/core_type_vec2.cpp

@@ -7,9 +7,9 @@
 #	include <type_traits>
 #endif
 
-static glm::vec2 v1;
-static glm::vec2 v2(1);
-static glm::vec2 v3(1, 1);
+static glm::vec2 g1;
+static glm::vec2 g2(1);
+static glm::vec2 g3(1, 1);
 
 int test_vec2_operators()
 {

+ 6 - 3
test/core/core_type_vec4.cpp

@@ -464,12 +464,12 @@ int test_vec4_perf_SoA(std::size_t Size)
 
 namespace heap
 {
-	class A
+	struct A
 	{
 		float f;
 	};
 
-	class B : public A
+	struct B : public A
 	{
 		float g;
 		glm::vec4 v;
@@ -477,11 +477,14 @@ namespace heap
 
 	int test()
 	{
-		int Error(0);
+		int Error = 0;
 
 		A* p = new B;
+		p->f = 0.0f;
 		delete p;
 
+		Error += sizeof(B) == sizeof(glm::vec4) + sizeof(float) * 2 ? 0 : 1;
+
 		return Error;
 	}
 }//namespace heap