mirror of
https://github.com/monero-project/monero.git
synced 2024-12-14 20:36:31 +02:00
cryptonote: Add const-qualifier on comparison functor
The original code did not compile with GCC 8.2.1 in C++17 mode, since comparison functions for std::set's must be invocable as const.
This commit is contained in:
parent
5d2fdc2e8c
commit
9bf0e53751
@ -61,7 +61,7 @@ namespace cryptonote
|
|||||||
class txCompare
|
class txCompare
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
bool operator()(const tx_by_fee_and_receive_time_entry& a, const tx_by_fee_and_receive_time_entry& b)
|
bool operator()(const tx_by_fee_and_receive_time_entry& a, const tx_by_fee_and_receive_time_entry& b) const
|
||||||
{
|
{
|
||||||
// sort by greatest first, not least
|
// sort by greatest first, not least
|
||||||
if (a.first.first > b.first.first) return true;
|
if (a.first.first > b.first.first) return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user