mirror of
https://github.com/llvm-mirror/libcxx.git
synced 2025-10-24 03:32:35 +08:00
[libcxx] Fix usage of _C2, which is a "nasty macro" in some environments
The problem was pointed out in https://reviews.llvm.org/D48896#inline-475775. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@345834 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
32
include/map
32
include/map
@@ -1323,33 +1323,33 @@ public:
|
||||
{
|
||||
return __tree_.template __node_handle_extract<node_type>(__it.__i_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(map<key_type, mapped_type, _C2, allocator_type>& __source)
|
||||
void merge(map<key_type, mapped_type, _Compare2, allocator_type>& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
__tree_.__node_handle_merge_unique(__source.__tree_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(map<key_type, mapped_type, _C2, allocator_type>&& __source)
|
||||
void merge(map<key_type, mapped_type, _Compare2, allocator_type>&& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
__tree_.__node_handle_merge_unique(__source.__tree_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(multimap<key_type, mapped_type, _C2, allocator_type>& __source)
|
||||
void merge(multimap<key_type, mapped_type, _Compare2, allocator_type>& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
__tree_.__node_handle_merge_unique(__source.__tree_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(multimap<key_type, mapped_type, _C2, allocator_type>&& __source)
|
||||
void merge(multimap<key_type, mapped_type, _Compare2, allocator_type>&& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
@@ -1942,33 +1942,33 @@ public:
|
||||
return __tree_.template __node_handle_extract<node_type>(
|
||||
__it.__i_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(multimap<key_type, mapped_type, _C2, allocator_type>& __source)
|
||||
void merge(multimap<key_type, mapped_type, _Compare2, allocator_type>& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
return __tree_.__node_handle_merge_multi(__source.__tree_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(multimap<key_type, mapped_type, _C2, allocator_type>&& __source)
|
||||
void merge(multimap<key_type, mapped_type, _Compare2, allocator_type>&& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
return __tree_.__node_handle_merge_multi(__source.__tree_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(map<key_type, mapped_type, _C2, allocator_type>& __source)
|
||||
void merge(map<key_type, mapped_type, _Compare2, allocator_type>& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
return __tree_.__node_handle_merge_multi(__source.__tree_);
|
||||
}
|
||||
template <class _C2>
|
||||
template <class _Compare2>
|
||||
_LIBCPP_INLINE_VISIBILITY
|
||||
void merge(map<key_type, mapped_type, _C2, allocator_type>&& __source)
|
||||
void merge(map<key_type, mapped_type, _Compare2, allocator_type>&& __source)
|
||||
{
|
||||
_LIBCPP_ASSERT(__source.get_allocator() == get_allocator(),
|
||||
"merging container with incompatible allocator");
|
||||
|
||||
Reference in New Issue
Block a user