Explicitly defaulted and deleted members

Better than a bit obscure implicit ones.

No functional change.
This commit is contained in:
Marco Costalba
2015-01-21 13:18:19 +01:00
parent 2ca2c3f35b
commit 96e36a7897
6 changed files with 12 additions and 17 deletions

View File

@@ -45,11 +45,10 @@ namespace Time {
template<class Entry, int Size>
struct HashTable {
HashTable() : table(Size, Entry()) {}
Entry* operator[](Key key) { return &table[(uint32_t)key & (Size - 1)]; }
private:
std::vector<Entry> table;
std::vector<Entry> table = std::vector<Entry>(Size);
};