Fixed build errors with GCC and Clang #664 and #666

This commit is contained in:
Christophe Riccio 2017-08-06 16:29:55 +02:00
parent e4ffe16bed
commit 22c88fd821
3 changed files with 3 additions and 17 deletions

View File

@ -698,7 +698,7 @@
#if GLM_HAS_CONSTEXPR || GLM_HAS_CONSTEXPR_PARTIAL
# define GLM_CONSTEXPR constexpr
# if GLM_COMPILER & GLM_COMPILER_VC // Visual C++ has a bug #594 https://github.com/g-truc/glm/issues/594
# if ((GLM_COMPILER & GLM_COMPILER_VC) && (GLM_COMPILER <= GLM_COMPILER_VC14)) // Visual C++ has a bug #594 https://github.com/g-truc/glm/issues/594
# define GLM_CONSTEXPR_CTOR
# else
# define GLM_CONSTEXPR_CTOR constexpr

View File

@ -339,20 +339,6 @@ namespace detail
};
}//namespace detail
# if !GLM_HAS_DEFAULTED_FUNCTIONS
template<>
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_lowp>::vec()
{}
template<>
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_mediump>::vec()
{}
template<>
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_highp>::vec()
{}
# endif//!GLM_HAS_DEFAULTED_FUNCTIONS
template<>
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_lowp>::vec(float _s) :
data(_mm_set1_ps(_s))

View File

@ -228,7 +228,7 @@ namespace glm
template<typename T, precision P>
GLM_FUNC_QUALIFIER tquat<T, P> quatLookAtRH(vec<3, T, P> const& direction, vec<3, T, P> const& up)
{
tmat3x3<T, P> Result;
mat<3, 3, T, P> Result;
Result[2] = -normalize(direction);
Result[0] = normalize(cross(up, Result[2]));
@ -240,7 +240,7 @@ namespace glm
template<typename T, precision P>
GLM_FUNC_QUALIFIER tquat<T, P> quatLookAtLH(vec<3, T, P> const& direction, vec<3, T, P> const& up)
{
tmat3x3<T, P> Result;
mat<3, 3, T, P> Result;
Result[2] = normalize(direction);
Result[0] = normalize(cross(up, Result[2]));