diff --git a/glm/core/_swizzle.hpp b/glm/core/_swizzle.hpp index 33815ff8..5da02a89 100644 --- a/glm/core/_swizzle.hpp +++ b/glm/core/_swizzle.hpp @@ -29,8 +29,6 @@ #ifndef glm_core_swizzle #define glm_core_swizzle -#include "_swizzle_func.hpp" - namespace glm { enum comp diff --git a/glm/core/type_vec1.hpp b/glm/core/type_vec1.hpp index 7ab9b88a..1f56c0e0 100644 --- a/glm/core/type_vec1.hpp +++ b/glm/core/type_vec1.hpp @@ -31,7 +31,13 @@ #include "../fwd.hpp" #include "type_vec.hpp" -#include "_swizzle.hpp" +#ifdef GLM_SWIZZLE +# if GLM_HAS_ANONYMOUS_UNION +# include "_swizzle.hpp" +# else +# include "_swizzle_func.hpp" +# endif +#endif //GLM_SWIZZLE namespace glm{ namespace detail diff --git a/glm/core/type_vec2.hpp b/glm/core/type_vec2.hpp index 6e8e0d3b..fa377698 100644 --- a/glm/core/type_vec2.hpp +++ b/glm/core/type_vec2.hpp @@ -31,7 +31,13 @@ #include "../fwd.hpp" #include "type_vec.hpp" -#include "_swizzle.hpp" +#ifdef GLM_SWIZZLE +# if GLM_HAS_ANONYMOUS_UNION +# include "_swizzle.hpp" +# else +# include "_swizzle_func.hpp" +# endif +#endif //GLM_SWIZZLE namespace glm{ namespace detail diff --git a/glm/core/type_vec3.hpp b/glm/core/type_vec3.hpp index 68603ae6..424ffdce 100644 --- a/glm/core/type_vec3.hpp +++ b/glm/core/type_vec3.hpp @@ -31,7 +31,13 @@ #include "../fwd.hpp" #include "type_vec.hpp" -#include "_swizzle.hpp" +#ifdef GLM_SWIZZLE +# if GLM_HAS_ANONYMOUS_UNION +# include "_swizzle.hpp" +# else +# include "_swizzle_func.hpp" +# endif +#endif //GLM_SWIZZLE namespace glm{ namespace detail diff --git a/glm/core/type_vec4.hpp b/glm/core/type_vec4.hpp index 3325c967..a1438d02 100644 --- a/glm/core/type_vec4.hpp +++ b/glm/core/type_vec4.hpp @@ -31,7 +31,13 @@ #include "../fwd.hpp" #include "type_vec.hpp" -#include "_swizzle.hpp" +#ifdef GLM_SWIZZLE +# if GLM_HAS_ANONYMOUS_UNION +# include "_swizzle.hpp" +# else +# include "_swizzle_func.hpp" +# endif +#endif //GLM_SWIZZLE namespace glm{ namespace detail