Clean up EIGEN_STATIC_ASSERT to only use standard c++11 static_assert.

This commit is contained in:
Rasmus Munk Larsen
2021-09-16 20:43:54 +00:00
parent 7b975acb1f
commit 6cadab6896
48 changed files with 269 additions and 663 deletions

View File

@@ -7,8 +7,6 @@
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
#define EIGEN_NO_STATIC_ASSERT
#include "main.h"
template<typename Scalar, bool is_integer = NumTraits<Scalar>::IsInteger>
@@ -320,16 +318,6 @@ template<typename Scalar> void dynamicVectorConstruction()
VERIFY(v.cols() == 1);
VERIFY_IS_EQUAL(v, (VectorX {{raw[0], raw[1], raw[2], raw[3]}}));
}
{
VERIFY_RAISES_ASSERT((VectorX {raw[0], raw[1], raw[2], raw[3]}));
}
{
VERIFY_RAISES_ASSERT((VectorX {
{raw[0], raw[1], raw[2], raw[3]},
{raw[0], raw[1], raw[2], raw[3]},
}));
}
}
EIGEN_DECLARE_TEST(initializer_list_construction)