diff options
Diffstat (limited to 'libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp')
| -rw-r--r-- | libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp b/libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp index aff6ba7ccaf..e15316999be 100644 --- a/libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp +++ b/libcxx/test/containers/unord/unord.multiset/emplace_hint.pass.cpp @@ -16,6 +16,10 @@ // template <class... Args> // iterator emplace_hint(const_iterator p, Args&&... args); +#if _LIBCPP_DEBUG2 >= 1 +#define _LIBCPP_ASSERT(x, m) ((x) ? (void)0 : std::exit(0)) +#endif + #include <unordered_set> #include <cassert> @@ -62,5 +66,15 @@ int main() assert(*r == Emplaceable(5, 6)); } #endif +#if _LIBCPP_DEBUG2 >= 1 + { + typedef std::unordered_multiset<Emplaceable> C; + typedef C::iterator R; + C c1; + C c2; + R r = c1.emplace_hint(c2.begin(), 5, 6); + assert(false); + } +#endif #endif // _LIBCPP_HAS_NO_RVALUE_REFERENCES } |

