Warning, /graphics/krita/3rdparty/ext_qt/0139-Fix-Wdeprecated-copy-warnings.patch is written in an unsupported language. File is not indexed.

0001 From 4bbbe3b388befb858b4c783506ab94f62f099885 Mon Sep 17 00:00:00 2001
0002 From: Fabian Kosmale <fabian.kosmale@qt.io>
0003 Date: Tue, 26 May 2020 16:57:36 +0200
0004 Subject: [PATCH 139/139] Fix -Wdeprecated-copy warnings
0005 
0006 Mostly by avoiding custom functions when the compiler generated ones
0007 work just fine
0008 
0009 (cherry-picked from commit f28b48b90e3230d1ce6bbcd5031ecb50089ec12b)
0010 Fixes: QTBUG-85998
0011 Change-Id: If8152fd24c9084bd85be3741fc218709e50fc375
0012 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
0013 
0014 (cherry picked from commit ed27157ca9a2c482bcfc79cf1f6f0e496b6a947c)
0015 Signed-off-by: L. E. Segovia <amy@amyspark.me>
0016 ---
0017  src/3rdparty/masm/stubs/wtf/Vector.h      | 1 -
0018  src/3rdparty/masm/wtf/CheckedArithmetic.h | 3 +++
0019  src/3rdparty/masm/wtf/PageBlock.h         | 8 --------
0020  src/qml/jsruntime/qv4scopedvalue_p.h      | 8 +++-----
0021  src/qml/qml/qqmltypenamecache_p.h         | 6 ------
0022  5 files changed, 6 insertions(+), 20 deletions(-)
0023 
0024 diff --git a/src/3rdparty/masm/stubs/wtf/Vector.h b/src/3rdparty/masm/stubs/wtf/Vector.h
0025 index f4f4dc5c..346a8010 100644
0026 --- a/src/3rdparty/masm/stubs/wtf/Vector.h
0027 +++ b/src/3rdparty/masm/stubs/wtf/Vector.h
0028 @@ -55,7 +55,6 @@ class Vector : public std::vector<T> {
0029  public:
0030      Vector() {}
0031      Vector(int initialSize) : std::vector<T>(initialSize) {}
0032 -    Vector(const Vector &other) : std::vector<T>(other) {}
0033      Vector(std::initializer_list<T> list) : std::vector<T>(list) {}
0034  
0035      inline void append(const T& value)
0036 diff --git a/src/3rdparty/masm/wtf/CheckedArithmetic.h b/src/3rdparty/masm/wtf/CheckedArithmetic.h
0037 index dd4acbb9..7d36ca5c 100644
0038 --- a/src/3rdparty/masm/wtf/CheckedArithmetic.h
0039 +++ b/src/3rdparty/masm/wtf/CheckedArithmetic.h
0040 @@ -430,6 +430,9 @@ public:
0041      {
0042      }
0043  
0044 +    Checked(const Checked &) = default;
0045 +
0046 +
0047      Checked(ResultOverflowedTag)
0048          : m_value(0)
0049      {
0050 diff --git a/src/3rdparty/masm/wtf/PageBlock.h b/src/3rdparty/masm/wtf/PageBlock.h
0051 index 9e2e5610..d85c39cb 100644
0052 --- a/src/3rdparty/masm/wtf/PageBlock.h
0053 +++ b/src/3rdparty/masm/wtf/PageBlock.h
0054 @@ -42,7 +42,6 @@ inline bool isPowerOfTwo(size_t size) { return !(size & (size - 1)); }
0055  class PageBlock {
0056  public:
0057      PageBlock();
0058 -    PageBlock(const PageBlock&);
0059      PageBlock(void*, size_t, bool hasGuardPages);
0060      
0061      void* realBase() const { return m_realBase; }
0062 @@ -74,13 +73,6 @@ inline PageBlock::PageBlock()
0063  {
0064  }
0065  
0066 -inline PageBlock::PageBlock(const PageBlock& other)
0067 -    : m_realBase(other.m_realBase)
0068 -    , m_base(other.m_base)
0069 -    , m_size(other.m_size)
0070 -{
0071 -}
0072 -
0073  inline PageBlock::PageBlock(void* base, size_t size, bool hasGuardPages)
0074      : m_realBase(base)
0075      , m_base(static_cast<char*>(base) + ((base && hasGuardPages) ? pageSize() : 0))
0076 diff --git a/src/qml/jsruntime/qv4scopedvalue_p.h b/src/qml/jsruntime/qv4scopedvalue_p.h
0077 index e4aceef3..12447a86 100644
0078 --- a/src/qml/jsruntime/qv4scopedvalue_p.h
0079 +++ b/src/qml/jsruntime/qv4scopedvalue_p.h
0080 @@ -172,6 +172,9 @@ private:
0081  
0082  struct ScopedValue
0083  {
0084 +    ScopedValue(const ScopedValue &) = default;
0085 +    ScopedValue(ScopedValue &&) = default;
0086 +
0087      ScopedValue(const Scope &scope)
0088      {
0089          ptr = scope.alloc<Scope::Uninitialized>();
0090 @@ -381,11 +384,6 @@ struct Scoped
0091          return *this;
0092      }
0093  
0094 -    Scoped<T> &operator=(const Scoped<T> &other) {
0095 -        *ptr = *other.ptr;
0096 -        return *this;
0097 -    }
0098 -
0099      Scoped<T> &operator=(T *t) {
0100          setPointer(t);
0101          return *this;
0102 diff --git a/src/qml/qml/qqmltypenamecache_p.h b/src/qml/qml/qqmltypenamecache_p.h
0103 index 28b5e7f0..7ec93868 100644
0104 --- a/src/qml/qml/qqmltypenamecache_p.h
0105 +++ b/src/qml/qml/qqmltypenamecache_p.h
0106 @@ -97,7 +97,6 @@ public:
0107          inline Result(const QQmlImportRef *importNamespace);
0108          inline Result(const QQmlType &type);
0109          inline Result(int scriptIndex);
0110 -        inline Result(const Result &);
0111  
0112          inline bool isValid() const;
0113  
0114 @@ -181,11 +180,6 @@ QQmlTypeNameCache::Result::Result(int scriptIndex)
0115  {
0116  }
0117  
0118 -QQmlTypeNameCache::Result::Result(const Result &o)
0119 -: type(o.type), importNamespace(o.importNamespace), scriptIndex(o.scriptIndex)
0120 -{
0121 -}
0122 -
0123  bool QQmlTypeNameCache::Result::isValid() const
0124  {
0125      return type.isValid() || importNamespace || scriptIndex != -1;
0126 -- 
0127 2.37.3
0128