generated from actions/typescript-action
-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix broken MySQL 8.1.0 build on macos-14 (#1133)
* apply patch: Bug#35137978: Equality operator needs to be updated after LWG-3865
- Loading branch information
1 parent
467898c
commit fc49b8d
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
42 changes: 42 additions & 0 deletions
42
patches/mysql/8.1.0/equality-operator-needs-to-be-updated.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
commit d4ecf88abba64baa56c2528fd1aa294c6fdbad24 | ||
Author: Georgi Kodinov <georgi.kodinov@oracle.com> | ||
Date: Thu Jul 20 14:49:31 2023 +0200 | ||
|
||
Bug#35137978: Equality operator needs to be updated after LWG-3865 | ||
|
||
The C++ Standardization Committee's Library Working Group recently resolved | ||
an issue, LWG-3865 "Sorting a range of pairs" (see | ||
https://cplusplus.github.io/LWG/issue3865 ), which changes how std::pair's | ||
comparison operators are defined. Such issues are considered "defect reports" | ||
and apply retroactively to all published Standards. | ||
|
||
Based on a suggestion by the Microsoft Visual Studio team. | ||
|
||
Change-Id: I8ac997fecfab9b53b4c3bdebd9ab995316aab6b7 | ||
|
||
diff --git a/sql/auth/auth_internal.h b/sql/auth/auth_internal.h | ||
index 2b1cf5324b4..324d0332d57 100644 | ||
--- a/sql/auth/auth_internal.h | ||
+++ b/sql/auth/auth_internal.h | ||
@@ -255,7 +255,7 @@ void revoke_dynamic_privileges_from_auth_id( | ||
const Role_id &id, const std::vector<std::string> &priv_list); | ||
bool operator==(const Role_id &a, const Auth_id_ref &b); | ||
bool operator==(const Auth_id_ref &a, const Role_id &b); | ||
-bool operator==(const std::pair<const Role_id, const Role_id> &a, | ||
+bool operator==(const std::pair<const Role_id, Role_id> &a, | ||
const Auth_id_ref &b); | ||
bool operator==(const Role_id &a, const Role_id &b); | ||
bool operator==(std::pair<const Role_id, std::pair<std::string, bool>> &a, | ||
diff --git a/sql/auth/sql_authorization.cc b/sql/auth/sql_authorization.cc | ||
index 96371df9b59..71d952303ce 100644 | ||
--- a/sql/auth/sql_authorization.cc | ||
+++ b/sql/auth/sql_authorization.cc | ||
@@ -7437,7 +7437,7 @@ bool operator==(const Role_id &a, const Auth_id_ref &b) { | ||
|
||
bool operator==(const Auth_id_ref &a, const Role_id &b) { return b == a; } | ||
|
||
-bool operator==(const std::pair<const Role_id, const Role_id> &a, | ||
+bool operator==(const std::pair<const Role_id, Role_id> &a, | ||
const Auth_id_ref &b) { | ||
return ((a.second.user().length() == b.first.length) && | ||
(a.second.host().length() == b.second.length) && |