diff options
author | Marshall Clow <mclow.lists@gmail.com> | 2015-06-30 18:15:41 +0000 |
---|---|---|
committer | Marshall Clow <mclow.lists@gmail.com> | 2015-06-30 18:15:41 +0000 |
commit | f8457a0735899ba71b7bb321cf88ff48b54c9d30 (patch) | |
tree | a1c8b315114dab918f4bb1f8a200aec9db9d475d /libcxx/test/std/containers/associative/multimap/multimap.ops/equal_range0.pass.cpp | |
parent | d9f09858a45aaeb1e258e41b04d6f78c345fbd8d (diff) | |
download | bcm5719-llvm-f8457a0735899ba71b7bb321cf88ff48b54c9d30.tar.gz bcm5719-llvm-f8457a0735899ba71b7bb321cf88ff48b54c9d30.zip |
Add tests for LWG#2299. While doing so, I noticed that the tests we have for the transparent comparators don't actually call them. Fix those tests, too. Now one of them is failing, due to a missing const in <map>. Add that (twice). Next step is to do the same for <unordered_map>
llvm-svn: 241091
Diffstat (limited to 'libcxx/test/std/containers/associative/multimap/multimap.ops/equal_range0.pass.cpp')
-rw-r--r-- | libcxx/test/std/containers/associative/multimap/multimap.ops/equal_range0.pass.cpp | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/libcxx/test/std/containers/associative/multimap/multimap.ops/equal_range0.pass.cpp b/libcxx/test/std/containers/associative/multimap/multimap.ops/equal_range0.pass.cpp new file mode 100644 index 00000000000..c0f07468ec5 --- /dev/null +++ b/libcxx/test/std/containers/associative/multimap/multimap.ops/equal_range0.pass.cpp @@ -0,0 +1,34 @@ +//===----------------------------------------------------------------------===// +// +// The LLVM Compiler Infrastructure +// +// This file is dual licensed under the MIT and the University of Illinois Open +// Source Licenses. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// +// +// XFAIL: c++03, c++11 + +// <map> + +// class multimap + +// iterator find(const key_type& k); +// const_iterator find(const key_type& k) const; +// +// The member function templates find, count, lower_bound, upper_bound, and +// equal_range shall not participate in overload resolution unless the +// qualified-id Compare::is_transparent is valid and denotes a type + + +#include <map> +#include <cassert> + +#include "is_transparent.h" + +int main() +{ + typedef std::multimap<int, double, transparent_less> M; + + M().equal_range(C2Int{5}); +} |