mirror of
https://github.com/citra-emu/citra-canary.git
synced 2024-12-24 19:25:34 +00:00
Merge pull request #1239 from wwylele/silent-vec-warning
Common: silence Vec warnings on msvc
This commit is contained in:
commit
f971aceac3
|
@ -32,6 +32,7 @@
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
#include <type_traits>
|
||||||
|
|
||||||
namespace Math {
|
namespace Math {
|
||||||
|
|
||||||
|
@ -90,6 +91,7 @@ public:
|
||||||
{
|
{
|
||||||
x-=other.x; y-=other.y;
|
x-=other.x; y-=other.y;
|
||||||
}
|
}
|
||||||
|
template<typename Q = T,class = typename std::enable_if<std::is_signed<Q>::value>::type>
|
||||||
Vec2<decltype(-T{})> operator -() const
|
Vec2<decltype(-T{})> operator -() const
|
||||||
{
|
{
|
||||||
return MakeVec(-x,-y);
|
return MakeVec(-x,-y);
|
||||||
|
@ -220,6 +222,7 @@ public:
|
||||||
{
|
{
|
||||||
x-=other.x; y-=other.y; z-=other.z;
|
x-=other.x; y-=other.y; z-=other.z;
|
||||||
}
|
}
|
||||||
|
template<typename Q = T,class = typename std::enable_if<std::is_signed<Q>::value>::type>
|
||||||
Vec3<decltype(-T{})> operator -() const
|
Vec3<decltype(-T{})> operator -() const
|
||||||
{
|
{
|
||||||
return MakeVec(-x,-y,-z);
|
return MakeVec(-x,-y,-z);
|
||||||
|
@ -390,6 +393,7 @@ public:
|
||||||
{
|
{
|
||||||
x-=other.x; y-=other.y; z-=other.z; w-=other.w;
|
x-=other.x; y-=other.y; z-=other.z; w-=other.w;
|
||||||
}
|
}
|
||||||
|
template<typename Q = T,class = typename std::enable_if<std::is_signed<Q>::value>::type>
|
||||||
Vec4<decltype(-T{})> operator -() const
|
Vec4<decltype(-T{})> operator -() const
|
||||||
{
|
{
|
||||||
return MakeVec(-x,-y,-z,-w);
|
return MakeVec(-x,-y,-z,-w);
|
||||||
|
|
Loading…
Reference in a new issue