Skip to content

Commit ff17269

Browse files
committed
Revert changes, will need to spin off into it's own thing
1 parent c9233ed commit ff17269

1 file changed

Lines changed: 4 additions & 8 deletions

File tree

include/rstl/list.hpp

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,8 @@ class list {
2929
~list();
3030
node* do_erase(node* item);
3131

32-
iterator push_front(const T& val) {
33-
do_insert_before(x4_start, val);
34-
return begin();
35-
}
36-
iterator push_back(const T& val) {
37-
do_insert_before(x8_end, val);
38-
return end();
39-
}
32+
void push_front(const T& val) { do_insert_before(x4_start, val); }
33+
void push_back(const T& val) { do_insert_before(x8_end, val); }
4034
void clear() { erase(begin(), end()); }
4135

4236
size_t size() const { return x14_count; }
@@ -52,6 +46,8 @@ class list {
5246
iterator erase(const iterator& start, const iterator& end) {
5347
node* last = end.get_node();
5448
node* it = start.get_node();
49+
for (node* t = it; t != last; t = t->get_next()) {
50+
}
5551

5652
while (it != last) {
5753
it = do_erase(it);

0 commit comments

Comments
 (0)