forked from mirrors/gecko-dev
Bug 1828784 - Work around VS 2019+ SDK issue. r=glandium
This is enough to prevent the undesired instantiation. Differential Revision: https://phabricator.services.mozilla.com/D175920
This commit is contained in:
parent
a73c63f734
commit
b8f531e854
2 changed files with 6 additions and 5 deletions
|
|
@ -47,8 +47,8 @@ class GCVector {
|
||||||
public:
|
public:
|
||||||
using ElementType = T;
|
using ElementType = T;
|
||||||
|
|
||||||
explicit GCVector(AllocPolicy alloc = AllocPolicy())
|
explicit GCVector(AllocPolicy alloc) : vector(std::move(alloc)) {}
|
||||||
: vector(std::move(alloc)) {}
|
GCVector() : GCVector(AllocPolicy()) {}
|
||||||
|
|
||||||
GCVector(GCVector&& vec) : vector(std::move(vec.vector)) {}
|
GCVector(GCVector&& vec) : vector(std::move(vec.vector)) {}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -341,9 +341,8 @@ template <typename T, size_t MinInlineCapacity = 0,
|
||||||
class AllocPolicy = MallocAllocPolicy>
|
class AllocPolicy = MallocAllocPolicy>
|
||||||
class MOZ_NON_PARAM Vector final : private AllocPolicy {
|
class MOZ_NON_PARAM Vector final : private AllocPolicy {
|
||||||
/* utilities */
|
/* utilities */
|
||||||
|
|
||||||
static constexpr bool kElemIsPod =
|
static constexpr bool kElemIsPod =
|
||||||
std::is_trivial<T>::value && std::is_standard_layout<T>::value;
|
std::is_trivial_v<T> && std::is_standard_layout_v<T>;
|
||||||
typedef detail::VectorImpl<T, MinInlineCapacity, AllocPolicy, kElemIsPod>
|
typedef detail::VectorImpl<T, MinInlineCapacity, AllocPolicy, kElemIsPod>
|
||||||
Impl;
|
Impl;
|
||||||
friend struct detail::VectorImpl<T, MinInlineCapacity, AllocPolicy,
|
friend struct detail::VectorImpl<T, MinInlineCapacity, AllocPolicy,
|
||||||
|
|
@ -540,7 +539,9 @@ class MOZ_NON_PARAM Vector final : private AllocPolicy {
|
||||||
|
|
||||||
typedef T ElementType;
|
typedef T ElementType;
|
||||||
|
|
||||||
explicit Vector(AllocPolicy = AllocPolicy());
|
explicit Vector(AllocPolicy);
|
||||||
|
Vector() : Vector(AllocPolicy()) {}
|
||||||
|
|
||||||
Vector(Vector&&); /* Move constructor. */
|
Vector(Vector&&); /* Move constructor. */
|
||||||
Vector& operator=(Vector&&); /* Move assignment. */
|
Vector& operator=(Vector&&); /* Move assignment. */
|
||||||
~Vector();
|
~Vector();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue