From 0d826a27aded1c773f837faf0f1b4bcbe5f25a74 Mon Sep 17 00:00:00 2001 From: Loren Brichter Date: Tue, 21 May 2013 23:08:35 -0400 Subject: [PATCH] Fix warnings when compiling with -Wshadow & clang Fix a handful of places where parameters shadow fields. --- glm/core/_detail.hpp | 16 ++++++++-------- glm/core/type_vec1.inl | 4 ++-- glm/core/type_vec2.inl | 8 ++++---- glm/core/type_vec3.inl | 8 ++++---- glm/core/type_vec4.inl | 16 ++++++++-------- glm/gtc/quaternion.inl | 16 ++++++++-------- 6 files changed, 34 insertions(+), 34 deletions(-) diff --git a/glm/core/_detail.hpp b/glm/core/_detail.hpp index e6b42c26..01e2ecb0 100644 --- a/glm/core/_detail.hpp +++ b/glm/core/_detail.hpp @@ -136,12 +136,12 @@ namespace detail i(0) {} - GLM_FUNC_QUALIFIER uif32(float f) : - f(f) + GLM_FUNC_QUALIFIER uif32(float f_) : + f(f_) {} - GLM_FUNC_QUALIFIER uif32(unsigned int i) : - i(i) + GLM_FUNC_QUALIFIER uif32(unsigned int i_) : + i(i_) {} float f; @@ -154,12 +154,12 @@ namespace detail i(0) {} - GLM_FUNC_QUALIFIER uif64(double f) : - f(f) + GLM_FUNC_QUALIFIER uif64(double f_) : + f(f_) {} - GLM_FUNC_QUALIFIER uif64(uint64 i) : - i(i) + GLM_FUNC_QUALIFIER uif64(uint64 i_) : + i(i_) {} double f; diff --git a/glm/core/type_vec1.inl b/glm/core/type_vec1.inl index 6b12e03d..266b1b48 100644 --- a/glm/core/type_vec1.inl +++ b/glm/core/type_vec1.inl @@ -883,9 +883,9 @@ namespace detail template GLM_FUNC_QUALIFIER tref1::tref1 ( - T & x + T & x_ ) : - x(x) + x(x_) {} template diff --git a/glm/core/type_vec2.inl b/glm/core/type_vec2.inl index fbad911b..aa6bd794 100644 --- a/glm/core/type_vec2.inl +++ b/glm/core/type_vec2.inl @@ -972,11 +972,11 @@ namespace detail template tref2::tref2 ( - T & x, - T & y + T & x_, + T & y_ ) : - x(x), - y(y) + x(x_), + y(y_) {} template diff --git a/glm/core/type_vec3.inl b/glm/core/type_vec3.inl index 3bcf1c8a..14b28b33 100644 --- a/glm/core/type_vec3.inl +++ b/glm/core/type_vec3.inl @@ -1092,10 +1092,10 @@ namespace detail // tref definition template - GLM_FUNC_QUALIFIER tref3::tref3(T & x, T & y, T & z) : - x(x), - y(y), - z(z) + GLM_FUNC_QUALIFIER tref3::tref3(T & x_, T & y_, T & z_) : + x(x_), + y(y_), + z(z_) {} template diff --git a/glm/core/type_vec4.inl b/glm/core/type_vec4.inl index 744d2d0f..b8d17707 100644 --- a/glm/core/type_vec4.inl +++ b/glm/core/type_vec4.inl @@ -1309,15 +1309,15 @@ namespace detail template tref4::tref4 ( - T & x, - T & y, - T & z, - T & w + T & x_, + T & y_, + T & z_, + T & w_ ) : - x(x), - y(y), - z(z), - w(w) + x(x_), + y(y_), + z(z_), + w(w_) {} template diff --git a/glm/gtc/quaternion.inl b/glm/gtc/quaternion.inl index 8b83865a..eb041806 100644 --- a/glm/gtc/quaternion.inl +++ b/glm/gtc/quaternion.inl @@ -60,15 +60,15 @@ namespace detail template GLM_FUNC_QUALIFIER tquat::tquat ( - value_type const & w, - value_type const & x, - value_type const & y, - value_type const & z + value_type const & w_, + value_type const & x_, + value_type const & y_, + value_type const & z_ ) : - x(x), - y(y), - z(z), - w(w) + x(x_), + y(y_), + z(z_), + w(w_) {} //////////////////////////////////////////////////////////////