1
0
mirror of https://github.com/anope/anope.git synced 2026-07-04 13:13:14 +02:00

Rename hash_map to unordered_map to match the underlying container.

This commit is contained in:
Sadie Powell
2024-03-09 13:22:48 +00:00
parent 9ead3f15c3
commit 39d288f99f
9 changed files with 11 additions and 11 deletions
+2 -2
View File
@@ -17,8 +17,8 @@
#include "memo.h"
#include "base.h"
typedef Anope::hash_map<NickAlias *> nickalias_map;
typedef Anope::hash_map<NickCore *> nickcore_map;
typedef Anope::unordered_map<NickAlias *> nickalias_map;
typedef Anope::unordered_map<NickCore *> nickcore_map;
typedef std::unordered_map<uint64_t, NickCore *> nickcoreid_map;
extern CoreExport Serialize::Checker<nickalias_map> NickAliasList;
+1 -1
View File
@@ -343,7 +343,7 @@ namespace Anope
using multimap = std::multimap<string, T, ci::less>;
template<typename T>
using hash_map = std::unordered_map<string, T, hash_ci, compare>;
using unordered_map = std::unordered_map<string, T, hash_ci, compare>;
#ifndef REPRODUCIBLE_BUILD
static const char *const compiled = __TIME__ " " __DATE__;
+1 -1
View File
@@ -13,7 +13,7 @@
#include "modes.h"
#include "serialize.h"
typedef Anope::hash_map<Channel *> channel_map;
typedef Anope::unordered_map<Channel *> channel_map;
extern CoreExport channel_map ChannelList;
+1 -1
View File
@@ -16,7 +16,7 @@
#include "serialize.h"
#include "bots.h"
typedef Anope::hash_map<ChannelInfo *> registered_channel_map;
typedef Anope::unordered_map<ChannelInfo *> registered_channel_map;
extern CoreExport Serialize::Checker<registered_channel_map> RegisteredChannelList;
+1 -1
View File
@@ -19,7 +19,7 @@
#include "account.h"
#include "sockets.h"
typedef Anope::hash_map<User *> user_map;
typedef Anope::unordered_map<User *> user_map;
extern CoreExport user_map UserListByNick, UserListByUID;
+1 -1
View File
@@ -19,7 +19,7 @@ enum TypeInfo
static bool simple;
struct SeenInfo;
static SeenInfo *FindInfo(const Anope::string &nick);
typedef Anope::hash_map<SeenInfo *> database_map;
typedef Anope::unordered_map<SeenInfo *> database_map;
database_map database;
struct SeenInfo final
+2 -2
View File
@@ -12,7 +12,7 @@
#include "module.h"
#include "modules/ns_cert.h"
static Anope::hash_map<NickCore *> certmap;
static Anope::unordered_map<NickCore *> certmap;
struct CertServiceImpl final
: CertService
@@ -21,7 +21,7 @@ struct CertServiceImpl final
NickCore *FindAccountFromCert(const Anope::string &cert) override
{
Anope::hash_map<NickCore *>::iterator it = certmap.find(cert);
Anope::unordered_map<NickCore *>::iterator it = certmap.find(cert);
if (it != certmap.end())
return it->second;
return NULL;
+1 -1
View File
@@ -103,7 +103,7 @@ bool WebCPanel::Index::OnRequest(HTTPProvider *server, const Anope::string &page
// Rate limit check.
Anope::string ip = client->clientaddr.addr();
Anope::hash_map<time_t>::iterator it = last_login_attempt.find(ip);
Anope::unordered_map<time_t>::iterator it = last_login_attempt.find(ip);
if (it != last_login_attempt.end())
{
time_t last_time = it->second;
+1 -1
View File
@@ -17,7 +17,7 @@ class Index final
{
static const int FLUSH_TIME = 60;
Anope::hash_map<time_t> last_login_attempt;
Anope::unordered_map<time_t> last_login_attempt;
time_t last_clear = 0;
public: