Skip to content

Commit 6e6af4f

Browse files
committed
Adjust error messages
1 parent b32d2e0 commit 6e6af4f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libcxx/test/libcxx/iterators/assert.next.pass.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ int main(int, char**) {
2525
forward_iterator<int *> it(a+1);
2626
(void)std::next(it, 1); // should work fine
2727
(void)std::next(it, 0); // should work fine
28-
TEST_LIBCPP_ASSERT_FAILURE(std::next(it, -1), "Attempt to next(it, n) with negative n on a non-bidirectional iterator");
28+
TEST_LIBCPP_ASSERT_FAILURE(std::next(it, -1), "Attempt to advance(it, n) with negative n on a non-bidirectional iterator");
2929

3030
return 0;
3131
}

libcxx/test/libcxx/iterators/assert.prev.pass.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ int main(int, char**) {
3131
forward_iterator<int *> it(a+1);
3232
(void)std::prev(it, -1); // should work fine
3333
(void)std::prev(it, 0); // should work fine
34-
TEST_LIBCPP_ASSERT_FAILURE(std::prev(it, 1), "Attempt to prev(it, n) with a positive n on a non-bidirectional iterator");
34+
TEST_LIBCPP_ASSERT_FAILURE(std::prev(it, 1), "Attempt to advance(it, n) with negative n on a non-bidirectional iterator");
3535

3636
return 0;
3737
}

0 commit comments

Comments
 (0)