Browse Source

MSVC 2013 compatibility: {}-related issues.

pull/107/head
Vladimír Vondruš 11 years ago
parent
commit
a89a692ddd
  1. 6
      src/Magnum/Math/Test/MatrixTest.cpp
  2. 3
      src/Magnum/Math/Test/RangeTest.cpp
  3. 6
      src/Magnum/Math/Test/RectangularMatrixTest.cpp
  4. 3
      src/Magnum/Math/Test/VectorTest.cpp

6
src/Magnum/Math/Test/MatrixTest.cpp

@ -294,12 +294,14 @@ void MatrixTest::invertedOrthogonal() {
template<class T> class BasicVec2: public Math::Vector<2, T> {
public:
template<class ...U> constexpr BasicVec2(U&&... args): Math::Vector<2, T>{args...} {}
/* MSVC 2015 can't handle {} here */
template<class ...U> constexpr BasicVec2(U&&... args): Math::Vector<2, T>(args...) {}
};
template<class T> class BasicMat2: public Math::Matrix<2, T> {
public:
template<class ...U> constexpr BasicMat2(U&&... args): Math::Matrix<2, T>{args...} {}
/* MSVC 2015 can't handle {} here */
template<class ...U> constexpr BasicMat2(U&&... args): Math::Matrix<2, T>(args...) {}
MAGNUM_MATRIX_SUBCLASS_IMPLEMENTATION(2, BasicMat2, BasicVec2)
};

3
src/Magnum/Math/Test/RangeTest.cpp

@ -448,7 +448,8 @@ void RangeTest::scaled() {
template<class T> class BasicRect: public Math::Range<2, T> {
public:
template<class ...U> constexpr BasicRect(U&&... args): Math::Range<2, T>{args...} {}
/* MSVC 2015 can't handle {} here */
template<class ...U> constexpr BasicRect(U&&... args): Math::Range<2, T>(args...) {}
MAGNUM_RANGE_SUBCLASS_IMPLEMENTATION(2, BasicRect, Vector2)
};

6
src/Magnum/Math/Test/RectangularMatrixTest.cpp

@ -438,7 +438,8 @@ void RectangularMatrixTest::vector() {
template<std::size_t size, class T> class BasicMat: public Math::RectangularMatrix<size, size, T> {
public:
template<class ...U> constexpr BasicMat(U&&... args): Math::RectangularMatrix<size, size, T>{args...} {}
/* MSVC 2015 can't handle {} here */
template<class ...U> constexpr BasicMat(U&&... args): Math::RectangularMatrix<size, size, T>(args...) {}
MAGNUM_RECTANGULARMATRIX_SUBCLASS_IMPLEMENTATION(size, size, BasicMat<size, T>)
};
@ -447,7 +448,8 @@ MAGNUM_MATRIX_OPERATOR_IMPLEMENTATION(BasicMat<size, T>)
template<class T> class BasicMat2x2: public BasicMat<2, T> {
public:
template<class ...U> constexpr BasicMat2x2(U&&... args): BasicMat<2, T>{args...} {}
/* MSVC 2015 can't handle {} here */
template<class ...U> constexpr BasicMat2x2(U&&... args): BasicMat<2, T>(args...) {}
MAGNUM_RECTANGULARMATRIX_SUBCLASS_IMPLEMENTATION(2, 2, BasicMat2x2<T>)
};

3
src/Magnum/Math/Test/VectorTest.cpp

@ -468,7 +468,8 @@ void VectorTest::angle() {
template<class T> class BasicVec2: public Math::Vector<2, T> {
public:
template<class ...U> constexpr BasicVec2(U&&... args): Math::Vector<2, T>{args...} {}
/* MSVC 2015 can't handle {} here */
template<class ...U> constexpr BasicVec2(U&&... args): Math::Vector<2, T>(args...) {}
MAGNUM_VECTOR_SUBCLASS_IMPLEMENTATION(2, BasicVec2)
};

Loading…
Cancel
Save