From 1105b4d2c99e99750f42b7a39443bb03b40f4afa Mon Sep 17 00:00:00 2001 From: alberth Date: Sat, 8 Aug 2015 13:19:38 +0000 Subject: (svn r27363) -Codechange: Fix codestyle of one-line methods and header codestyle of derived structs. --- src/misc/hashtable.hpp | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'src/misc/hashtable.hpp') diff --git a/src/misc/hashtable.hpp b/src/misc/hashtable.hpp index e754a7d7b..1afe58cac 100644 --- a/src/misc/hashtable.hpp +++ b/src/misc/hashtable.hpp @@ -24,7 +24,10 @@ struct CHashTableSlotT inline CHashTableSlotT() : m_pFirst(NULL) {} /** hash table slot helper - clears the slot by simple forgetting its items */ - inline void Clear() {m_pFirst = NULL;} + inline void Clear() + { + m_pFirst = NULL; + } /** hash table slot helper - linear search for item with given key through the given blob - const version */ inline const Titem_ *Find(const Key &key) const @@ -168,14 +171,23 @@ protected: } /** static helper - return hash for the given item modulo number of slots */ - inline static int CalcHash(const Titem_ &item) {return CalcHash(item.GetKey());} + inline static int CalcHash(const Titem_ &item) + { + return CalcHash(item.GetKey()); + } public: /** item count */ - inline int Count() const {return m_num_items;} + inline int Count() const + { + return m_num_items; + } /** simple clear - forget all items - used by CSegmentCostCacheT.Flush() */ - inline void Clear() {for (int i = 0; i < Tcapacity; i++) m_slots[i].Clear();} + inline void Clear() + { + for (int i = 0; i < Tcapacity; i++) m_slots[i].Clear(); + } /** const item search */ const Titem_ *Find(const Tkey &key) const -- cgit v1.2.3-54-g00ecf