Skip to content

Commit 4986d1c

Browse files
committed
TODO: Improve the tests for insert and emplace
1 parent 20fd6fc commit 4986d1c

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

libcxx/test/std/containers/sequences/vector/vector.modifiers/emplace.pass.cpp

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,3 +168,16 @@ int main(int, char**)
168168
#endif
169169
return 0;
170170
}
171+
172+
// TODO:
173+
// Add emplace test like
174+
//
175+
// std::vector<int> v = {1, 2, 3, 4};
176+
// v.reserve(10000);
177+
// v.emplace(v.begin() + 1, 999);
178+
179+
// TODO:
180+
// Add tests for emplacing and inserting from an element in the vector itself
181+
182+
// TODO:
183+
// There is a bug in emplace, we should be using __uninitialized_allocator_relocate_backward. Also why is this not caught by the tests?

0 commit comments

Comments
 (0)