Skip to content
Snippets Groups Projects
Commit 9c1d09e1 authored by Andreas Buhr's avatar Andreas Buhr
Browse files

replace dune_static_assert by static_assert

parent 4cfda54b
No related branches found
No related tags found
No related merge requests found
......@@ -15,7 +15,6 @@
#include <iostream>
#include <dune/common/deprecated.hh>
#include <dune/common/static_assert.hh>
#include <boost/static_assert.hpp>
#include <boost/fusion/include/void.hpp>
......@@ -63,9 +62,9 @@ namespace Common {
template <class SomeRangeType, class OtherRangeType>
static double colonProduct(const SomeRangeType& arg1, const OtherRangeType& arg2)
{
dune_static_assert(SomeRangeType::cols == SomeRangeType::rows && OtherRangeType::cols == OtherRangeType::rows
&& int(OtherRangeType::cols) == int(SomeRangeType::rows),
"RangeTypes_dont_fit");
static_assert(SomeRangeType::cols == SomeRangeType::rows && OtherRangeType::cols == OtherRangeType::rows
&& int(OtherRangeType::cols) == int(SomeRangeType::rows),
"RangeTypes_dont_fit");
double ret = 0.0;
// iterators
......@@ -190,8 +189,8 @@ public:
template <class stl_container_type>
MinMaxAvg(const stl_container_type& elements)
{
dune_static_assert((boost::is_same<ElementType, typename stl_container_type::value_type>::value),
"cannot assign mismatching types");
static_assert((boost::is_same<ElementType, typename stl_container_type::value_type>::value),
"cannot assign mismatching types");
acc_ = std::for_each(elements.begin(), elements.end(), acc_);
}
......
......@@ -11,7 +11,6 @@
// dune-common
#include <dune/common/densematrix.hh>
#include <dune/common/static_assert.hh>
#include <dune/stuff/common/debug.hh>
#include <dune/stuff/common/math.hh>
......@@ -68,7 +67,7 @@ class MatrixDiagonal : public FieldVector<typename FieldMatrixType::field_type,
public:
MatrixDiagonal(const FieldMatrixType& matrix)
{
dune_static_assert(FieldMatrixType::rows == FieldMatrixType::cols, "Matrix must be square!");
static_assert(FieldMatrixType::rows == FieldMatrixType::cols, "Matrix must be square!");
// CompileTimeChecker< FieldMatrixType::rows == FieldMatrixType::cols > matrix_must_be_square;
for (size_t i = 0; i < FieldMatrixType::rows; i++)
......
......@@ -16,7 +16,6 @@
#include <algorithm>
#include <dune/common/version.hh>
#include <dune/common/array.hh>
#include <dune/common/static_assert.hh>
#include <dune/common/deprecated.hh>
#include <dune/common/exceptions.hh>
......
......@@ -18,7 +18,6 @@
#include <dune/common/array.hh>
#include <dune/common/deprecated.hh>
#include <dune/common/static_assert.hh>
#include <ostream>
#include <iomanip>
#include <vector>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment