зеркало из https://github.com/microsoft/STL.git
<xhash>: Fix compiler error when dllexporting a class derived from unordered_set (#1639)
This commit is contained in:
Родитель
df18ae1ae0
Коммит
7f08bb3887
|
@ -1841,6 +1841,7 @@ protected:
|
|||
}
|
||||
}
|
||||
|
||||
template <bool _Multi2 = _Traits::_Multi, enable_if_t<_Multi2, int> = 0>
|
||||
_NODISCARD bool _Multi_equal(const _Hash& _Right) const {
|
||||
static_assert(_Traits::_Multi, "This function only works with multi containers");
|
||||
_STL_INTERNAL_CHECK(this->size() == _Right.size());
|
||||
|
|
|
@ -174,6 +174,7 @@ tests\GH_001123_random_cast_out_of_range
|
|||
tests\GH_001411_core_headers
|
||||
tests\GH_001530_binomial_accuracy
|
||||
tests\GH_001541_case_sensitive_boolalpha
|
||||
tests\GH_001638_dllexport_derived_classes
|
||||
tests\LWG2597_complex_branch_cut
|
||||
tests\LWG3018_shared_ptr_function
|
||||
tests\P0019R8_atomic_ref
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
# Copyright (c) Microsoft Corporation.
|
||||
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||
|
||||
RUNALL_INCLUDE ..\impure_matrix.lst
|
|
@ -0,0 +1,52 @@
|
|||
// Copyright (c) Microsoft Corporation.
|
||||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
||||
|
||||
#include <array>
|
||||
#include <deque>
|
||||
#include <forward_list>
|
||||
#include <list>
|
||||
#include <map>
|
||||
#include <queue>
|
||||
#include <set>
|
||||
#include <stack>
|
||||
#include <unordered_map>
|
||||
#include <unordered_set>
|
||||
#include <vector>
|
||||
|
||||
#if _HAS_CXX20
|
||||
#include <span>
|
||||
#endif // _HAS_CXX20
|
||||
|
||||
using namespace std;
|
||||
|
||||
int main() {} // COMPILE-ONLY
|
||||
|
||||
#pragma warning(disable : 4251) // class 'A' needs to have dll-interface to be used by clients of class 'B'
|
||||
#pragma warning(disable : 4275) // non dll-interface struct 'A' used as base for dll-interface class 'B'
|
||||
|
||||
struct __declspec(dllexport) ExportedArray : array<int, 3> {};
|
||||
struct __declspec(dllexport) ExportedArrayZero : array<int, 0> {};
|
||||
struct __declspec(dllexport) ExportedDeque : deque<int> {};
|
||||
struct __declspec(dllexport) ExportedForwardList : forward_list<int> {};
|
||||
struct __declspec(dllexport) ExportedList : list<int> {};
|
||||
struct __declspec(dllexport) ExportedVector : vector<int> {};
|
||||
struct __declspec(dllexport) ExportedVectorBool : vector<bool> {};
|
||||
|
||||
struct __declspec(dllexport) ExportedMap : map<int, int> {};
|
||||
struct __declspec(dllexport) ExportedMultimap : multimap<int, int> {};
|
||||
struct __declspec(dllexport) ExportedSet : set<int> {};
|
||||
struct __declspec(dllexport) ExportedMultiset : multiset<int> {};
|
||||
|
||||
struct __declspec(dllexport) ExportedUnorderedMap : unordered_map<int, int> {};
|
||||
struct __declspec(dllexport) ExportedUnorderedMultimap : unordered_multimap<int, int> {};
|
||||
struct __declspec(dllexport) ExportedUnorderedSet : unordered_set<int> {};
|
||||
struct __declspec(dllexport) ExportedUnorderedMultiset : unordered_multiset<int> {};
|
||||
|
||||
struct __declspec(dllexport) ExportedQueue : queue<int> {};
|
||||
struct __declspec(dllexport) ExportedPriorityQueue : priority_queue<int> {};
|
||||
struct __declspec(dllexport) ExportedStack : stack<int> {};
|
||||
|
||||
#if _HAS_CXX20
|
||||
struct __declspec(dllexport) ExportedSpan : span<int> {};
|
||||
struct __declspec(dllexport) ExportedSpanThree : span<int, 3> {};
|
||||
#endif // _HAS_CXX20
|
Загрузка…
Ссылка в новой задаче