rename operation base operator() to to() (avoid conflicts)

This commit is contained in:
Christian Zimmermann 2019-02-06 19:34:17 +01:00
parent 60ceb6e9a1
commit 697aac6b94
2 changed files with 3 additions and 3 deletions

View file

@ -89,10 +89,10 @@ namespace MultiArrayTools
template <typename T, class OperationClass>
template <class... Indices>
auto OperationBase<T,OperationClass>::operator()(const std::shared_ptr<Indices>&... inds) const
auto OperationBase<T,OperationClass>::to(const std::shared_ptr<Indices>&... inds) const
-> MultiArray<T,typename Indices::RangeType...>
{
MultiArray<T,typename Indices::RangeType...> out(inds->range()... , static_cast<T>(0));
MultiArray<T,typename Indices::RangeType...> out(inds->range()...);
out(inds...) = THIS();
return out;
}

View file

@ -66,7 +66,7 @@ namespace MultiArrayTools
-> ConstOperationRoot<T,typename Indices::RangeType...>;
template <class... Indices>
auto operator()(const std::shared_ptr<Indices>&... inds) const
auto to(const std::shared_ptr<Indices>&... inds) const
-> MultiArray<T,typename Indices::RangeType...>;
template <typename R, class... Args> // Args = Operation Classes