DUNE-ACFEM (unstable)

Expressions store their arguments as copies if constructed from rvalue references or as references if constructed from lvalues. More...

Classes

struct  Dune::ACFem::Expressions::IsExpression< T, VoidType< void, decltype(std::decay_t< T >::arity()) > >
 Identify something conforming to the expression interface. More...
 
struct  Dune::ACFem::Expressions::IsExpressionOfArity< N, T >
 TrueType if T is an expression of arity N, otherwise FalseType. More...
 
struct  Dune::ACFem::Expressions::IsUnaryExpression< T >
 TrueType if T is an expression of arity 1, otherwise FalseType. More...
 
struct  Dune::ACFem::Expressions::IsBinaryExpression< T >
 TrueType if T is an expression of arity 2, otherwise FalseType. More...
 
struct  Dune::ACFem::Expressions::SameOperandFunctors< T, SFINAE >
 @interal SFINAE default for examining the functors of operands when we do not know whether T has sufficiently many operands. More...
 
struct  Dune::ACFem::Expressions::SameOperandFunctors< T, std::enable_if_t< IsUnaryExpression< T >::value > >
 
struct  Dune::ACFem::Expressions::SameOperandFunctors< T, std::enable_if_t<(IsBinaryExpression< T >::value &&std::is_same< Functor< Operand< 0, T > >, Functor< Operand< 1, T > > >::value)> >
 
struct  Dune::ACFem::Expressions::SameOperandFunctors< T, std::enable_if_t<(IsExpression< T >::value &&Arity< T >::value > 2)> >
 

Typedefs

template<class T >
using Dune::ACFem::Expressions::IsConstantExprArg = BoolConstant<!ExpressionTraits< T >::isVolatile &&(ExpressionTraits< T >::isTypedValue||ExpressionTraits< T >::isConstant||(!std::is_reference< T >::value &&ExpressionTraits< T >::isIndependent))>
 Evaluate to true if an instance of T can be treated as constant argument to an expresion. More...
 

Functions

template<std::size_t I, class T >
constexpr void Dune::ACFem::Expressions::danglingReferenceCheck (T &&t, IndexConstant< I >=IndexConstant< I >{})
 
template<class F , class... T>
constexpr auto Dune::ACFem::Expressions::storage (const F &f, T &&... t)
 Generate an expression storage container.
 

Variables

template<class T >
static constexpr bool Dune::ACFem::Expressions::EmitByValueV = IsTypedValue<T>::value && !StorageImpl::HasSubExpressionOperation<T>::value
 Force some things to always be emitted as non-references.
 

Detailed Description

Expressions store their arguments as copies if constructed from rvalue references or as references if constructed from lvalues.

Typedef Documentation

◆ IsConstantExprArg

template<class T >
using Dune::ACFem::Expressions::IsConstantExprArg = typedef BoolConstant<!ExpressionTraits<T>::isVolatile && (ExpressionTraits<T>::isTypedValue || ExpressionTraits<T>::isConstant || (!std::is_reference<T>::value && ExpressionTraits<T>::isIndependent))>

Evaluate to true if an instance of T can be treated as constant argument to an expresion.

Knowledge about this opens optimization possibilities.

Parameters
[in]TSome type, references are allowed.

Function Documentation

◆ danglingReferenceCheck()

template<std::size_t I, class T >
constexpr void Dune::ACFem::Expressions::danglingReferenceCheck ( T &&  t,
IndexConstant< I >  = IndexConstant<I>{} 
)
constexpr

Check for dangling reference returned from operand() call.

Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Dec 28, 23:30, 2024)