diff options
author | w00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-08-15 11:32:49 +0000 |
---|---|---|
committer | w00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-08-15 11:32:49 +0000 |
commit | 01ce98f2746be837a64f5f9ed2c36eeaabae7462 (patch) | |
tree | 83e0a640f913a78861cc321bc9aaf67089b2b305 /include/typedefs.h | |
parent | 74a515a72f08fc85d8d59cb7207fba9ece51215f (diff) |
win: Last part of support required for VS2010:
NEEDS COMPILE TESTING ON: gcc3 (if possible), gcc4, vs2008.
- Check for vs2010 in hash_map.h
- use unordered_map if it exists
- change all map creations to:
#if defined(WINDOWS) && !defined(HASHMAP_DEPRECATED)
// old windows crap
#else
#if HASHMAP_DEPRECATED
// tr1/gcc crap
#endif
#endif
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11524 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include/typedefs.h')
-rw-r--r-- | include/typedefs.h | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/include/typedefs.h b/include/typedefs.h index ca3efcc70..a40e6cfc2 100644 --- a/include/typedefs.h +++ b/include/typedefs.h @@ -14,8 +14,10 @@ #ifndef __TYPEDEF_H__ #define __TYPEDEF_H__ -#ifndef WIN32 - +#if defined(WINDOWS) && !defined(HASHMAP_DEPRECATED) + typedef nspace::hash_map<std::string, User*, nspace::hash_compare<std::string, std::less<std::string> > > user_hash; + typedef nspace::hash_map<std::string, Channel*, nspace::hash_compare<std::string, std::less<std::string> > > chan_hash; +#else #ifdef HASHMAP_DEPRECATED typedef nspace::hash_map<std::string, User*, nspace::insensitive, irc::StrHashComp> user_hash; typedef nspace::hash_map<std::string, Channel*, nspace::insensitive, irc::StrHashComp> chan_hash; @@ -23,10 +25,6 @@ typedef nspace::hash_map<std::string, User*, nspace::hash<std::string>, irc::StrHashComp> user_hash; typedef nspace::hash_map<std::string, Channel*, nspace::hash<std::string>, irc::StrHashComp> chan_hash; #endif -#else - - typedef nspace::hash_map<std::string, User*, nspace::hash_compare<std::string, std::less<std::string> > > user_hash; - typedef nspace::hash_map<std::string, Channel*, nspace::hash_compare<std::string, std::less<std::string> > > chan_hash; #endif /** Server name cache |