Changeset 2104
- Timestamp:
- Nov 21, 2012, 1:57:28 PM (10 years ago)
- Location:
- trunk/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/core/hash.cpp
r2097 r2104 123 123 } 124 124 125 uint32_t Hash<char const *>::operator ()(char const *s)125 static uint32_t HashCharString(char const *s) 126 126 { 127 127 uint32_t ret = 0xffffffffu, ch; … … 133 133 } 134 134 135 uint32_t Hash<char const *>::operator ()(char const *s) 136 { 137 return HashCharString(s); 138 } 139 140 uint32_t Hash<String>::operator ()(String const &s) 141 { 142 return HashCharString(&s[0]); 143 } 144 135 145 } /* namespace lol */ 136 146 -
trunk/src/lol/core/hash.h
r2097 r2104 38 38 }; 39 39 40 template<> class Hash<String> 41 { 42 public: 43 uint32_t operator()(String const &s); 44 }; 45 40 46 } /* namespace lol */ 41 47
Note: See TracChangeset
for help on using the changeset viewer.