1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
https://bugs.gentoo.org/787851
From 6d448928a88f586195dadd9fae9cb1b19e589d94 Mon Sep 17 00:00:00 2001
From: Sam James <sam@gentoo.org>
Date: Tue, 15 Jun 2021 03:05:34 +0000
Subject: [PATCH] Fix build with GCC 11
diff --git a/src/ObjectSystem/configSymbol.hh b/src/ObjectSystem/configSymbol.hh
index 90b00d9..d037dab 100644
--- a/src/ObjectSystem/configSymbol.hh
+++ b/src/ObjectSystem/configSymbol.hh
@@ -50,7 +50,7 @@ public:
private:
struct symbolLt
{
- bool operator()(const Symbol* d1, const Symbol* d2)
+ bool operator()(const Symbol* d1, const Symbol* d2) const
{
return d1->compare(d2) < 0;
}
diff --git a/src/ObjectSystem/objectMap.cc b/src/ObjectSystem/objectMap.cc
index 0dbcaf0..722aa29 100644
--- a/src/ObjectSystem/objectMap.cc
+++ b/src/ObjectSystem/objectMap.cc
@@ -50,7 +50,7 @@ ConfigSymbol::MessageQueue::markReachableNodes() const
struct ConfigSymbol::dagNodeLt
{
- bool operator()(const DagNode* d1, const DagNode* d2)
+ bool operator()(const DagNode* d1, const DagNode* d2) const
{
return d1->compare(d2) < 0;
}
diff --git a/src/ObjectSystem/objectSystemRewritingContext.hh b/src/ObjectSystem/objectSystemRewritingContext.hh
index 33785ec..32f4d94 100644
--- a/src/ObjectSystem/objectSystemRewritingContext.hh
+++ b/src/ObjectSystem/objectSystemRewritingContext.hh
@@ -62,7 +62,7 @@ protected:
private:
struct dagNodeLt
{
- bool operator()(const DagNode* d1, const DagNode* d2)
+ bool operator()(const DagNode* d1, const DagNode* d2) const
{
return d1->compare(d2) < 0;
}
diff --git a/src/Mixfix/entity.hh b/src/Mixfix/entity.hh
index eb8ad58..a221de4 100644
--- a/src/Mixfix/entity.hh
+++ b/src/Mixfix/entity.hh
@@ -53,7 +53,7 @@ public:
private:
struct UserLt
{
- bool operator()(const User* user1, const User* user2)
+ bool operator()(const User* user1, const User* user2) const
{
//
// Direct < comparison of unrelated pointers is undefined. But since the casting
--
2.32.0
|