mirror of
https://github.com/nlohmann/json.git
synced 2026-02-10 12:02:28 +00:00
Revert "💥 changed iterators to andom_access_iterator #593"
This reverts commit c77a0be5f3.
This commit is contained in:
@@ -240,8 +240,9 @@ TEST_CASE("algorithms")
|
||||
SECTION("sorting an object")
|
||||
{
|
||||
json j({{"one", 1}, {"two", 2}});
|
||||
std::sort(j.begin(), j.end());
|
||||
CHECK(j == json({{"one", 1}, {"two", 2}}));
|
||||
CHECK_THROWS_AS(std::sort(j.begin(), j.end()), json::invalid_iterator&);
|
||||
CHECK_THROWS_WITH(std::sort(j.begin(), j.end()),
|
||||
"[json.exception.invalid_iterator.209] cannot use offsets with object iterators");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user