mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-13 15:44:36 +00:00
Made fixes
This commit is contained in:
parent
a91e5a2590
commit
d3aaabc976
1 changed files with 24 additions and 17 deletions
|
|
@ -33,32 +33,39 @@
|
||||||
#include "platform/threads/mutex.h"
|
#include "platform/threads/mutex.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef USE_CLASSIC_SIMDICTIONARY
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
||||||
#include "TorqueConfig.h"
|
#include "TorqueConfig.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
class SimObject;
|
class SimObject;
|
||||||
|
|
||||||
#include "core/strings/stringFunctions.h"
|
|
||||||
|
|
||||||
struct my_hash {
|
|
||||||
inline size_t operator()(const char* val) const
|
|
||||||
{
|
|
||||||
return (long)val;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
struct eqstr {
|
|
||||||
inline bool operator()(const char *s1, const char *s2) const {
|
|
||||||
return dStrcmp(s1, s2) == 0;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef USE_CLASSIC_SIMDICTIONARY
|
#ifndef USE_CLASSIC_SIMDICTIONARY
|
||||||
typedef std::unordered_map<const char * , SimObject*, my_hash, eqstr> StringDictDef;
|
|
||||||
|
#include "core/strings/stringFunctions.h"
|
||||||
|
|
||||||
|
struct DictionaryHash
|
||||||
|
{
|
||||||
|
inline size_t operator()(const char* val) const
|
||||||
|
{
|
||||||
|
return (long)val;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
struct eqstr
|
||||||
|
{
|
||||||
|
inline bool operator()(const char *s1, const char *s2) const
|
||||||
|
{
|
||||||
|
return dStrcmp(s1, s2) == 0;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef USE_CLASSIC_SIMDICTIONARY
|
||||||
|
typedef std::unordered_map<const char * , SimObject*, DictionaryHash, eqstr> StringDictDef;
|
||||||
typedef std::unordered_map<U32 ,SimObject*> U32DictDef;
|
typedef std::unordered_map<U32 ,SimObject*> U32DictDef;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue