Skip to content
Snippets Groups Projects
Commit 74f4a117 authored by Elias Pipping's avatar Elias Pipping Committed by Elias Pipping
Browse files

Use nullptr

parent b8e40cf0
No related branches found
No related tags found
No related merge requests found
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
#include <vector> #include <vector>
#include <dune/common/nullptr.hh>
#include <dune/common/fmatrix.hh> #include <dune/common/fmatrix.hh>
#include <dune/common/fvector.hh> #include <dune/common/fvector.hh>
#include <dune/istl/bcrsmatrix.hh> #include <dune/istl/bcrsmatrix.hh>
...@@ -45,7 +46,7 @@ class GlobalRuinaNonlinearity ...@@ -45,7 +46,7 @@ class GlobalRuinaNonlinearity
if ((*nodalIntegrals)[i][0] == 0) if ((*nodalIntegrals)[i][0] == 0)
return trivialNonlinearity; return trivialNonlinearity;
if (restrictions[i] != NULL) if (restrictions[i] != nullptr)
return restrictions[i]; return restrictions[i];
auto const func = make_shared<RuinaFunction const>( auto const func = make_shared<RuinaFunction const>(
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
#define MY_BLOCK_PROBLEM_HH #define MY_BLOCK_PROBLEM_HH
#include <dune/common/bitsetvector.hh> #include <dune/common/bitsetvector.hh>
#include <dune/common/nullptr.hh>
#include <dune/common/parametertree.hh> #include <dune/common/parametertree.hh>
#include <dune/solvers/common/staticmatrixtools.hh> #include <dune/solvers/common/staticmatrixtools.hh>
...@@ -242,7 +243,7 @@ class MyBlockProblem<MyConvexProblemTypeTEMPLATE>::IterateObject { ...@@ -242,7 +243,7 @@ class MyBlockProblem<MyConvexProblemTypeTEMPLATE>::IterateObject {
assert(false); assert(false);
} }
LocalMatrixType const *localA = NULL; LocalMatrixType const *localA = nullptr;
LocalVectorType localb(problem.f[m]); LocalVectorType localb(problem.f[m]);
typename MatrixType::row_type::ConstIterator it; typename MatrixType::row_type::ConstIterator it;
...@@ -254,7 +255,7 @@ class MyBlockProblem<MyConvexProblemTypeTEMPLATE>::IterateObject { ...@@ -254,7 +255,7 @@ class MyBlockProblem<MyConvexProblemTypeTEMPLATE>::IterateObject {
else else
it->mmv(u[j], localb); // localb -= A[m][j] * u[j] it->mmv(u[j], localb); // localb -= A[m][j] * u[j]
} }
assert(localA != NULL); assert(localA != nullptr);
auto const phi = problem.phi.restriction(m); auto const phi = problem.phi.restriction(m);
Dune::SampleFunctional<block_size> localJ(*localA, localb, phi, Dune::SampleFunctional<block_size> localJ(*localA, localb, phi,
......
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