33 template<
class LListBase,
class T>
38 for (
const T& val : lst)
45 template<
class LListBase,
class T>
50 LListBase::transfer(lst);
54 template<
class LListBase,
class T>
59 for (
const T& val : lst)
68 template<
class LListBase,
class T>
77 template<
class LListBase,
class T>
87 link*
p =
static_cast<link*
>(LListBase::removeHead());
94 template<
class LListBase,
class T>
97 this->pop_front(this->size());
102 template<
class LListBase,
class T>
106 LListBase::transfer(lst);
112 template<
class LListBase,
class T>
117 for (
const T& val : lst)
119 this->push_back(val);
124 template<
class LListBase,
class T>
129 LListBase::transfer(lst);
133 template<
class LListBase,
class T>
138 for (
const T& val : lst)
140 this->push_back(val);
void operator=(const LList< LListBase, T > &lst)
Copy assignment.
Template class for non-intrusive linked lists.
void pop_front(label n=1)
Remove first element(s) from the list (deletes pointers)
void transfer(LList< LListBase, T > &lst)
Transfer the contents of the argument into this List and annul the argument list. ...
LList()=default
Default construct.
~LList()
Destructor. Calls clear()
void clear()
Delete contents of list.