diff options
| author | 2018-08-08 23:30:40 -0400 | |
|---|---|---|
| committer | 2018-08-08 23:30:40 -0400 | |
| commit | 5b1b758326485e8fe868d81f2e63ea1b66bd1efe (patch) | |
| tree | 3f2f42a513eec4ee50fa0f4a2e1ec17b0d200f7c /src | |
| parent | Merge pull request #982 from bunnei/stub-unk-63 (diff) | |
| parent | vector_math: Use variable template version of is_signed in Vec classes (diff) | |
| download | yuzu-5b1b758326485e8fe868d81f2e63ea1b66bd1efe.tar.gz yuzu-5b1b758326485e8fe868d81f2e63ea1b66bd1efe.tar.xz yuzu-5b1b758326485e8fe868d81f2e63ea1b66bd1efe.zip | |
Merge pull request #987 from lioncash/vec
vector_math: Use variable template version of is_signed in Vec classes
Diffstat (limited to 'src')
| -rw-r--r-- | src/common/vector_math.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/common/vector_math.h b/src/common/vector_math.h index 5c94fcda3..8feb49941 100644 --- a/src/common/vector_math.h +++ b/src/common/vector_math.h | |||
| @@ -78,7 +78,7 @@ public: | |||
| 78 | } | 78 | } |
| 79 | 79 | ||
| 80 | template <typename U = T> | 80 | template <typename U = T> |
| 81 | constexpr Vec2<std::enable_if_t<std::is_signed<U>::value, U>> operator-() const { | 81 | constexpr Vec2<std::enable_if_t<std::is_signed_v<U>, U>> operator-() const { |
| 82 | return {-x, -y}; | 82 | return {-x, -y}; |
| 83 | } | 83 | } |
| 84 | constexpr Vec2<decltype(T{} * T{})> operator*(const Vec2& other) const { | 84 | constexpr Vec2<decltype(T{} * T{})> operator*(const Vec2& other) const { |
| @@ -227,7 +227,7 @@ public: | |||
| 227 | } | 227 | } |
| 228 | 228 | ||
| 229 | template <typename U = T> | 229 | template <typename U = T> |
| 230 | constexpr Vec3<std::enable_if_t<std::is_signed<U>::value, U>> operator-() const { | 230 | constexpr Vec3<std::enable_if_t<std::is_signed_v<U>, U>> operator-() const { |
| 231 | return {-x, -y, -z}; | 231 | return {-x, -y, -z}; |
| 232 | } | 232 | } |
| 233 | 233 | ||
| @@ -436,7 +436,7 @@ public: | |||
| 436 | } | 436 | } |
| 437 | 437 | ||
| 438 | template <typename U = T> | 438 | template <typename U = T> |
| 439 | constexpr Vec4<std::enable_if_t<std::is_signed<U>::value, U>> operator-() const { | 439 | constexpr Vec4<std::enable_if_t<std::is_signed_v<U>, U>> operator-() const { |
| 440 | return {-x, -y, -z, -w}; | 440 | return {-x, -y, -z, -w}; |
| 441 | } | 441 | } |
| 442 | 442 | ||