NRVec from std::list

This commit is contained in:
2022-02-18 19:03:19 +01:00
parent 10985a146b
commit 0e8c20770f
2 changed files with 11 additions and 0 deletions

7
vec.cc
View File

@@ -898,6 +898,13 @@ return -1;
}
template<typename T>
NRVec<T>::NRVec(const std::list<T> l)
{
resize(l.size());
int ii=0;
for(typename std::list<T>::const_iterator i=l.begin(); i!=l.end(); ++i) (*this)[ii++] = *i;
}
/***************************************************************************//**