Skip to content

Commit

Permalink
Compability with CDT 4.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
aamirpashaa committed Dec 5, 2023
1 parent 3d270c2 commit a78a639
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion contracts/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ option(SYSTEM_BLOCKCHAIN_PARAMETERS
find_package(cdt)

set(CDT_VERSION_MIN "3.0")
set(CDT_VERSION_SOFT_MAX "3.0")
set(CDT_VERSION_SOFT_MAX "4.0")
# set(CDT_VERSION_HARD_MAX "")

# Check the version of CDT
Expand Down
5 changes: 2 additions & 3 deletions contracts/eosio.system/src/voting.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <cmath>

// TELOS BEGIN
#include <boost/container/flat_map.hpp>
#include "system_rotation.cpp"
// TELOS END

Expand Down Expand Up @@ -346,7 +345,7 @@ namespace eosiosystem {
}

auto new_vote_weight = inverse_vote_weight((double)totalStaked, (double) producers.size());
boost::container::flat_map<name, std::pair< double, bool > > producer_deltas;
std::map<name, std::pair< double, bool > > producer_deltas;

// print("\n Voter : ", voter->last_stake, " = ", voter->last_vote_weight, " = ", proxy, " = ", producers.size(), " = ", totalStaked, " = ", new_vote_weight);

Expand Down Expand Up @@ -557,7 +556,7 @@ namespace eosiosystem {
p.total_votes = 0;
});
}
boost::container::flat_map< name, bool> processed_proxies;
std::map< name, bool> processed_proxies;
for (auto voter = _voters.begin(); voter != _voters.end(); ++voter) {
if(voter->proxy && !processed_proxies[voter->proxy]){
auto proxy = _voters.find(voter->proxy.value);
Expand Down

0 comments on commit a78a639

Please sign in to comment.