You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
chromium/chromium-76.0.3809.100-gcc-...

43 lines
1.6 KiB

From abe74a7f0c53a43a9706a42d71b7ff4a5da53380 Mon Sep 17 00:00:00 2001
From: Jose Dapena Paz <jose.dapena@lge.com>
Date: Tue, 11 Jun 2019 10:27:19 +0200
Subject: [PATCH] GCC: add noexcept move assignment in history::URLRow
In GCC, build is failing because history::QueryURLResult declares its move
assignment operator as noexcept using default implementation. That requires
its members to provide a move assignment operator that is noexcept too.
But URLRow was missing noexcept declaration in move assignment operator (even
though it was providing noexcept to its move constructor).
Bug: 819294
Change-Id: I726e3cf7a4a50c9206a5d0fba8a561d363483d4f
---
diff --git a/components/history/core/browser/url_row.cc b/components/history/core/browser/url_row.cc
index 44c22fd..aec0101 100644
--- a/components/history/core/browser/url_row.cc
+++ b/components/history/core/browser/url_row.cc
@@ -26,7 +26,7 @@
}
URLRow& URLRow::operator=(const URLRow& other) = default;
-URLRow& URLRow::operator=(URLRow&& other) = default;
+URLRow& URLRow::operator=(URLRow&& other) noexcept = default;
void URLRow::Swap(URLRow* other) {
std::swap(id_, other->id_);
diff --git a/components/history/core/browser/url_row.h b/components/history/core/browser/url_row.h
index 8f6f9cf..31a1ef8 100644
--- a/components/history/core/browser/url_row.h
+++ b/components/history/core/browser/url_row.h
@@ -35,7 +35,7 @@
virtual ~URLRow();
URLRow& operator=(const URLRow& other);
- URLRow& operator=(URLRow&& other);
+ URLRow& operator=(URLRow&& other) noexcept;
URLID id() const { return id_; }