Compilation error: error: definition of implicit copy assignment operator in AppHighlightRangeData.h
https://bugs.webkit.org/show_bug.cgi?id=231717
rdar://problem/84230745
Reviewed by Tim Horton.
Per C++11 and later:
“The generation of the implicitly-defined copy assignment operator is
deprecated if T has a user-declared destructor or user-declared copy
constructor.”
A copy constructor is defined, so we need to declare a copy assignement operator.
* Modules/highlight/AppHighlightRangeData.h: Add copy assignment operator.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@284147 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog
index 981ae0b..e5d2029 100644
--- a/Source/WebCore/ChangeLog
+++ b/Source/WebCore/ChangeLog
@@ -1,3 +1,19 @@
+2021-10-13 Jean-Yves Avenard <jya@apple.com>
+
+ Compilation error: error: definition of implicit copy assignment operator in AppHighlightRangeData.h
+ https://bugs.webkit.org/show_bug.cgi?id=231717
+ rdar://problem/84230745
+
+ Reviewed by Tim Horton.
+
+ Per C++11 and later:
+ “The generation of the implicitly-defined copy assignment operator is
+ deprecated if T has a user-declared destructor or user-declared copy
+ constructor.”
+ A copy constructor is defined, so we need to declare a copy assignement operator.
+
+ * Modules/highlight/AppHighlightRangeData.h: Add copy assignment operator.
+
2021-10-13 Simon Fraser <simon.fraser@apple.com>
Use PlatformKeyboardEvent in KeyboardScrollingAnimator to fix a layering violation
diff --git a/Source/WebCore/Modules/highlight/AppHighlightRangeData.h b/Source/WebCore/Modules/highlight/AppHighlightRangeData.h
index f1fa524..cf6381a 100644
--- a/Source/WebCore/Modules/highlight/AppHighlightRangeData.h
+++ b/Source/WebCore/Modules/highlight/AppHighlightRangeData.h
@@ -99,6 +99,8 @@
{
}
+ AppHighlightRangeData& operator=(const AppHighlightRangeData&) = default;
+
const String& identifier() const { return m_identifier; }
const String& text() const { return m_text; }
const NodePath& startContainer() const { return m_startContainer; }