Skip to content
Snippets Groups Projects
Commit 36f54e1b authored by Andreas Dedner's avatar Andreas Dedner
Browse files

replace std::result_of with std::invoke_result to make std20 compilation work

Is available since std17
parent 1c7d360a
Branches
No related tags found
1 merge request!757replace std::result_of with std::invoke_result to make std20 compilation work
Pipeline #74709 passed
......@@ -30,7 +30,7 @@ namespace Dune
typedef typename GridView::template Codim< 0 >::Entity Element;
typedef typename Element::Geometry::LocalCoordinate LocalCoordinate;
typedef std::decay_t< std::result_of_t< LocalEvaluator( Element, LocalCoordinate ) > > Value;
typedef std::decay_t< std::invoke_result_t< LocalEvaluator, Element, LocalCoordinate > > Value;
explicit SimpleLocalFunction ( LocalEvaluator localEvaluator ) : localEvaluator_( std::move( localEvaluator ) ) {}
~SimpleLocalFunction() { unbind(); }
......@@ -147,7 +147,7 @@ namespace Dune
// ------------------
template< class GV, class LE,
class = std::result_of_t< std::decay_t< LE >( typename GV::template Codim< 0 >::Entity, typename GV::template Codim< 0 >::Geometry::LocalCoordinate ) > >
class = std::invoke_result_t< std::decay_t< LE >, typename GV::template Codim< 0 >::Entity, typename GV::template Codim< 0 >::Geometry::LocalCoordinate > >
inline static auto simpleGridFunction ( const GV &gridView, LE &&localEvaluator, PriorityTag< 1 > )
-> SimpleGridFunction< GV, std::decay_t< LE > >
{
......@@ -155,7 +155,7 @@ namespace Dune
}
template< class GV, class E,
class = std::result_of_t< std::decay_t< E >( typename GV::template Codim< 0 >::Geometry::GlobalCoordinate ) > >
class = std::invoke_result_t< std::decay_t< E >, typename GV::template Codim< 0 >::Geometry::GlobalCoordinate > >
inline static auto simpleGridFunction ( const GV &gridView, E &&evaluator, PriorityTag< 0 > )
-> SimpleGlobalGridFunction< GV, std::decay_t< E > >
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment