[all-commits] [llvm/llvm-project] 65fcea: [libc++] Adds missing forward_list merge tests.
mordante via All-commits
all-commits at lists.llvm.org
Tue Nov 9 11:12:16 PST 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 65fceaebc79112d755cdda4a58828fdd9318e45f
https://github.com/llvm/llvm-project/commit/65fceaebc79112d755cdda4a58828fdd9318e45f
Author: Mark de Wever <koraq at xs4all.nl>
Date: 2021-11-09 (Tue, 09 Nov 2021)
Changed paths:
R libcxx/test/std/containers/sequences/forwardlist/forwardlist.ops/merge.pass.cpp
A libcxx/test/std/containers/sequences/forwardlist/forwardlist.ops/merge_lvalue.pass.cpp
A libcxx/test/std/containers/sequences/forwardlist/forwardlist.ops/merge_lvalue_pred.pass.cpp
R libcxx/test/std/containers/sequences/forwardlist/forwardlist.ops/merge_pred.pass.cpp
A libcxx/test/std/containers/sequences/forwardlist/forwardlist.ops/merge_rvalue.pass.cpp
A libcxx/test/std/containers/sequences/forwardlist/forwardlist.ops/merge_rvalue_pred.pass.cpp
Log Message:
-----------
[libc++] Adds missing forward_list merge tests.
During the review of D112660 it turned out the tests for
`std::forward_list::merge` are incomplete.
Adds tests for the rvalue reference overloads. The tests are extended to
better test the Effects [forward.list.ops]/25 and Remarks
[forward.list.ops]/27 of the function:
- x is empty after the merge.
- Pointers and references to the moved elements of x now refer to those
same elements but as members of *this.
- Iterators referring to the moved elements will continue to refer to
their elements, but they now behave as iterators into *this, not into x.
- The algorithm is stable.
Reviewed By: Quuxplusone, #libc, ldionne
Differential Revision: https://reviews.llvm.org/D113364
More information about the All-commits
mailing list