mirror of
https://github.com/mangosfour/server.git
synced 2025-12-20 16:37:04 +00:00
Use (if available) TR1 unordered_map instead hash_map at Unix/Linux (in GCC 4.0.0 and later) and Windows (VC90 and later)
This commit is contained in:
parent
ac222e92b1
commit
5222f49820
25 changed files with 80 additions and 73 deletions
|
|
@ -22,7 +22,7 @@
|
|||
#include "Platform/Define.h"
|
||||
#include "Policies/Singleton.h"
|
||||
#include "zthread/FastMutex.h"
|
||||
#include "Utilities/HashMap.h"
|
||||
#include "Utilities/UnorderedMap.h"
|
||||
#include "Policies/ThreadingModel.h"
|
||||
|
||||
#include "ByteBuffer.h"
|
||||
|
|
@ -47,7 +47,7 @@ class HashMapHolder
|
|||
{
|
||||
public:
|
||||
|
||||
typedef HM_NAMESPACE::hash_map< uint64, T* > MapType;
|
||||
typedef UNORDERED_MAP< uint64, T* > MapType;
|
||||
typedef ZThread::FastMutex LockType;
|
||||
typedef MaNGOS::GeneralLock<LockType > Guard;
|
||||
|
||||
|
|
@ -89,8 +89,8 @@ class MANGOS_DLL_DECL ObjectAccessor : public MaNGOS::Singleton<ObjectAccessor,
|
|||
ObjectAccessor& operator=(const ObjectAccessor &);
|
||||
|
||||
public:
|
||||
typedef HM_NAMESPACE::hash_map<uint64, Corpse* > Player2CorpsesMapType;
|
||||
typedef HM_NAMESPACE::hash_map<Player*, UpdateData>::value_type UpdateDataValueType;
|
||||
typedef UNORDERED_MAP<uint64, Corpse* > Player2CorpsesMapType;
|
||||
typedef UNORDERED_MAP<Player*, UpdateData>::value_type UpdateDataValueType;
|
||||
|
||||
template<class T> static T* GetObjectInWorld(uint64 guid, T* /*fake*/)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue