diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-06-12 19:29:42 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2008-06-12 19:29:42 +0000 |
commit | b3e3b1f14e12b4b0a395ef8e2a4848f132e2c22b (patch) | |
tree | 18a4627fa652e12055acf88bfac758df0ad85d89 /include/hashcomp.h | |
parent | 06a25cab68a58a4c9e985a394590b3288de33723 (diff) |
Now builds ok on gcc 4.3, not tested fully. Also UGLY, oh we hate you GCC, why couldnt you just use TR1 from the start???
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9894 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include/hashcomp.h')
-rw-r--r-- | include/hashcomp.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/include/hashcomp.h b/include/hashcomp.h index e93875e3e..777c4fe0e 100644 --- a/include/hashcomp.h +++ b/include/hashcomp.h @@ -688,6 +688,7 @@ BEGIN_HASHMAP_NAMESPACE size_t operator()(const std::string & s) const; }; #else + template<> struct hash<irc::string> { /** Hash an irc::string using RFC1459 case sensitivity rules @@ -697,14 +698,17 @@ BEGIN_HASHMAP_NAMESPACE size_t operator()(const irc::string &s) const; }; + /* XXX FIXME: Implement a hash function overriding std::string's that works with TR1! */ + +#ifdef HASHMAP_DEPRECATED + struct insensitive +#else template<> struct hash<std::string> +#endif { - /** Hash a std::string using RFC1459 case sensitivity rules - * @param s A string to hash - * @return The hash value - */ size_t operator()(const std::string &s) const; }; + #endif /** Convert a string to lower case respecting RFC1459 |