operator=(double) for multi_array
This commit is contained in:
parent
a55b8d8b9f
commit
db32888ce9
1 changed files with 11 additions and 0 deletions
|
@ -81,6 +81,8 @@ namespace MultiArrayTools
|
||||||
|
|
||||||
operator T() const;
|
operator T() const;
|
||||||
|
|
||||||
|
MultiArray& operator=(const T& in);
|
||||||
|
|
||||||
MultiArray& operator+=(const MultiArray& in);
|
MultiArray& operator+=(const MultiArray& in);
|
||||||
MultiArray& operator-=(const MultiArray& in);
|
MultiArray& operator-=(const MultiArray& in);
|
||||||
MultiArray& operator*=(const T& in);
|
MultiArray& operator*=(const T& in);
|
||||||
|
@ -321,6 +323,15 @@ namespace MultiArrayTools
|
||||||
std::move(mCont) );
|
std::move(mCont) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <typename T, class... SRanges>
|
||||||
|
MultiArray<T,SRanges...>& MultiArray<T,SRanges...>::operator=(const T& in)
|
||||||
|
{
|
||||||
|
for(auto& x: mCont){
|
||||||
|
x = in;
|
||||||
|
}
|
||||||
|
return *this;
|
||||||
|
}
|
||||||
|
|
||||||
template <typename T, class... SRanges>
|
template <typename T, class... SRanges>
|
||||||
MultiArray<T,SRanges...>& MultiArray<T,SRanges...>::operator+=(const MultiArray& in)
|
MultiArray<T,SRanges...>& MultiArray<T,SRanges...>::operator+=(const MultiArray& in)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue