Namespace containing the details of the implmentation for general stator components.
|
| template<class T > |
| std::pair< int, int > | BP (const T &v) |
| | Returns the binding powers (precedence) of binary operators. More...
|
| |
| template<class LHS , class Op , class RHS > |
| std::pair< int, int > | BP (const sym::BinaryOp< LHS, Op, RHS > &v) |
| | Returns the binding powers (precedence) of binary operators (specialisation for binary ops). More...
|
| |
| std::pair< int, int > | BP (const sym::Expr &v) |
| | Returns the binding powers (precedence) of binary operators (specialisation for Expr). More...
|
| |
| template<class Config > |
| std::string | paren_wrap (std::string arg) |
| |
| template<class T > |
| auto | store (const T &val) -> decltype(store_impl(val, select_overload |
| |
| template<class T > |
| auto | store_impl (T val, choice< 0 >) -> decltype(typename std::decay< decltype(std::declval< T >().eval())>::type(val)) |
| |
| template<class T > |
| auto | store_impl (T val, choice< 1 >) -> decltype(typename std::decay< T >::type(val)) |
| |
◆ last_choice
◆ BP() [1/3]
template<class T >
| std::pair<int, int> stator::detail::BP |
( |
const T & |
v | ) |
|
As unary operators/tokens have no arguments which can be bound by other operators, we return a large binding power (which should exclude them from any binding power calculations).
Definition at line 163 of file print.hpp.
◆ BP() [2/3]
template<class LHS , class Op , class RHS >
| std::pair<int, int> stator::detail::BP |
( |
const sym::BinaryOp< LHS, Op, RHS > & |
v | ) |
|
◆ BP() [3/3]
| std::pair<int, int> stator::detail::BP |
( |
const sym::Expr & |
v | ) |
|
◆ paren_wrap()
template<class Config >
| std::string stator::detail::paren_wrap |
( |
std::string |
arg | ) |
|
◆ store()
Determine the type which can permanently store the passed Type (an extension of std::decay).
This should determine the underlying type which is capable of storing a given type. Generally, this is just std::decay; however, libraries (such as Eigen) uses delayed evaluation thus we need to determine the resulting type to avoid aliasing issues.
StoreType<decltype(A + B)>::type val = A + B;
Definition at line 94 of file config.hpp.
◆ store_impl() [1/2]
template<class T >
| auto stator::detail::store_impl |
( |
T |
val, |
|
|
choice< 0 > |
|
|
) |
| -> decltype( typename std::decay<decltype(std::declval<T>().eval())>::type(val) ) |
◆ store_impl() [2/2]
template<class T >
| auto stator::detail::store_impl |
( |
T |
val, |
|
|
choice< 1 > |
|
|
) |
| -> decltype( typename std::decay<T>::type(val) ) |