Some tests assume that iteration through an unordered multimap elements will return them in the same order as at the container creation. This assumption is not true since the container is unordered, so that no specific order of elements is ever guaranteed for such container. This patch introduces checks verifying that any iteration will return elements exactly from a set of valid values and without repetition, but in no particular order.
Hmm, I'm confused by this change request. All the tests I patched are intended to test unordered_multimap container, which was introduced in C++11. So, they won't compile in C++03 mode in any case. Please, clarify the reason for the patch change.
I just had a discussion with other libc++ maintainers and we'd like to conserve the order-dependent tests, but only for libc++. Could you please keep the order-dependent tests in a suitably-named file under test/libcxx/<...> instead of test/std/<...>? Tests under test/libcxx/ are libc++-specific.
Initializer-list construction replaced with insert() throughout the tests.
I would suggest someone from libc++ test suite developers/maintainers team to do this, if it is necessary for them, before the patch is applied to test/std/<...> tests. I'm not a member of this team, but just yet another external user of test/std/<...> tests. So, I'd like to avoid intervening into another expert team's job by trying to solve their internal tasks having no sufficient expertize to do this.