From 1183d39f4370e6d731d4033d0c4be446c9a73612 Mon Sep 17 00:00:00 2001 From: Groove Date: Sun, 15 Jul 2018 19:15:49 +0200 Subject: [PATCH] Fixed VC12 build, added VC 14 test --- .appveyor.yml | 1 + test/core/core_type_ctor.cpp | 40 ++++++++++++++++++------------------ 2 files changed, 21 insertions(+), 20 deletions(-) diff --git a/.appveyor.yml b/.appveyor.yml index fe933b0c..aadaf547 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -2,6 +2,7 @@ clone_folder: c:\dev\glm-cmake os: - Visual Studio 2013 + - Visual Studio 2015 - Visual Studio 2017 platform: diff --git a/test/core/core_type_ctor.cpp b/test/core/core_type_ctor.cpp index 5cc9fa09..6cf4d4dc 100644 --- a/test/core/core_type_ctor.cpp +++ b/test/core/core_type_ctor.cpp @@ -98,7 +98,7 @@ static int test_mat2x2_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -112,7 +112,7 @@ static int test_mat2x2_ctor() B.f = glm::mat2x2(1); Error += glm::all(glm::equal(B.i[0], glm::vec2(1, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -121,7 +121,7 @@ static int test_mat2x3_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -135,7 +135,7 @@ static int test_mat2x3_ctor() B.f = glm::mat2x3(1); Error += glm::all(glm::equal(B.i[0], glm::vec3(1, 0, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -144,7 +144,7 @@ static int test_mat2x4_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -160,7 +160,7 @@ static int test_mat2x4_ctor() glm::vec4 const D(1, 0, 0, 0); Error += glm::all(glm::equal(B.i[0], D)) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -169,7 +169,7 @@ static int test_mat3x2_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -183,7 +183,7 @@ static int test_mat3x2_ctor() B.f = glm::mat3x2(1); Error += glm::all(glm::equal(B.i[0], glm::vec2(1, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -192,7 +192,7 @@ static int test_mat3x3_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -206,7 +206,7 @@ static int test_mat3x3_ctor() B.f = glm::mat3x3(1); Error += glm::all(glm::equal(B.i[0], glm::vec3(1, 0, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -215,7 +215,7 @@ static int test_mat3x4_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -229,7 +229,7 @@ static int test_mat3x4_ctor() B.f = glm::mat3x4(1); Error += glm::all(glm::equal(B.i[0], glm::vec4(1, 0, 0, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -238,7 +238,7 @@ static int test_mat4x2_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -252,7 +252,7 @@ static int test_mat4x2_ctor() B.f = glm::mat4x2(1); Error += glm::all(glm::equal(B.i[0], glm::vec2(1, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -261,7 +261,7 @@ static int test_mat4x3_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -275,7 +275,7 @@ static int test_mat4x3_ctor() B.f = glm::mat4x3(1); Error += glm::all(glm::equal(B.i[0], glm::vec3(1, 0, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -284,7 +284,7 @@ static int test_mat4x4_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -298,7 +298,7 @@ static int test_mat4x4_ctor() B.f = glm::mat4(1); Error += glm::all(glm::equal(B.i[0], glm::vec4(1, 0, 0, 0))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; } @@ -307,7 +307,7 @@ static int test_quat_ctor() { int Error = 0; -# if GLM_HAS_DEFAULTED_FUNCTIONS +# if GLM_LANG & GLM_LANG_CXX11_FLAG { union pack { @@ -321,7 +321,7 @@ static int test_quat_ctor() B.f = glm::quat(1, 1, 1, 1); Error += glm::all(glm::equal(B.i, glm::quat(1, 1, 1, 1))) ? 0 : 1; } -# endif//GLM_HAS_DEFAULTED_FUNCTIONS +# endif//GLM_LANG & GLM_LANG_CXX11_FLAG return Error; }