From cb4c9a6a9459a1c9bee1b22cabb5e8aa154968d9 Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Fri, 8 Jun 2018 17:11:45 +0200 Subject: bug #1531: make dedicatd unit testing for NumDimensions --- test/num_dimensions.cpp | 90 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 test/num_dimensions.cpp (limited to 'test/num_dimensions.cpp') diff --git a/test/num_dimensions.cpp b/test/num_dimensions.cpp new file mode 100644 index 000000000..f5209283d --- /dev/null +++ b/test/num_dimensions.cpp @@ -0,0 +1,90 @@ +// This file is part of Eigen, a lightweight C++ template library +// for linear algebra. +// +// Copyright (C) 2018 Gael Guennebaud +// +// This Source Code Form is subject to the terms of the Mozilla +// 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/. + +#include "main.h" +#include + +template +void check_dim(const Xpr& ) { + STATIC_CHECK( Xpr::NumDimensions == ExpectedDim ); +} + +#if EIGEN_HAS_CXX11 +template