In file included from /in/driver/main.cpp:5:0:
/in/hashtable.hpp: In member function 'void HashTable<Key, Value, Hash, KeyEqual>::rehash(size_t)':
/in/hashtable.hpp:416:54: error: 'newBucketSize' was not declared in this scope
size_t minBucketSize = findMinimumBucketSize(newBucketSize);
^~~~~~~~~~~~~
/in/hashtable.hpp:416:54: note: suggested alternative: 'minBucketSize'
size_t minBucketSize = findMinimumBucketSize(newBucketSize);
^~~~~~~~~~~~~
minBucketSize
/in/hashtable.hpp: In instantiation of 'void HashTable<Key, Value, Hash, KeyEqual>::rehash(size_t) [with Key = int; Value = int; Hash = std::hash<int>; KeyEqual = std::equal_to<int>; size_t = long unsigned int]':
/in/hashtable.hpp:399:23: required from 'Value& HashTable<Key, Value, Hash, KeyEqual>::operator[](const Key&) [with Key = int; Value = int; Hash = std::hash<int>; KeyEqual = std::equal_to<int>]'
/in/driver/main.cpp:129:94: required from here
/in/hashtable.hpp:419:43: error: no match for 'operator*' (operand type is 'HashTable<int, int, std::hash<int>, std::equal_to<int> >::HashTableData {aka std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >}')
for (const auto &bucket : *buckets) {
^~~~~~~~
/in/hashtable.hpp:420:21: error: unable to deduce 'auto&&' from 'bucket'
for (const auto &node : bucket) {
^~~
/in/hashtable.hpp:427:25: error: no match for 'operator=' (operand types are 'HashTable<int, int, std::hash<int>, std::equal_to<int> >::HashTableData {aka std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >}' and 'std::remove_reference<std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >&>::type {aka std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >}')
buckets = std::move(newBuckets);
~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/7/vector:69:0,
from /usr/include/c++/7/functional:61,
from /in/hashtable.hpp:4,
from /in/driver/main.cpp:5:
/usr/include/c++/7/bits/vector.tcc:179:5: note: candidate: std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(const std::vector<_Tp, _Alloc>&) [with _Tp = std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >; _Alloc = std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > >]
vector<_Tp, _Alloc>::
^~~~~~~~~~~~~~~~~~~
/usr/include/c++/7/bits/vector.tcc:179:5: note: no known conversion for argument 1 from 'std::remove_reference<std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >&>::type {aka std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >}' to 'const std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >&'
In file included from /usr/include/c++/7/vector:64:0,
from /usr/include/c++/7/functional:61,
from /in/hashtable.hpp:4,
from /in/driver/main.cpp:5:
/usr/include/c++/7/bits/stl_vector.h:461:7: note: candidate: std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::vector<_Tp, _Alloc>&&) [with _Tp = std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >; _Alloc = std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > >]
operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move())
^~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:461:7: note: no known conversion for argument 1 from 'std::remove_reference<std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >&>::type {aka std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >}' to 'std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >&&'
/usr/include/c++/7/bits/stl_vector.h:482:7: note: candidate: std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::initializer_list<_Tp>) [with _Tp = std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >; _Alloc = std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > >]
operator=(initializer_list<value_type> __l)
^~~~~~~~
/usr/include/c++/7/bits/stl_vector.h:482:7: note: no known conversion for argument 1 from 'std::remove_reference<std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >&>::type {aka std::unique_ptr<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >, std::default_delete<std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > > > >}' to 'std::initializer_list<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > >'
In file included from /in/driver/main.cpp:5:0:
/in/hashtable.hpp:429:46: error: base operand of '->' has non-pointer type 'HashTable<int, int, std::hash<int>, std::equal_to<int> >::HashTableData {aka std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >}'
firstBucketIt = std::find_if(buckets->begin(), buckets->end(), [](const HashNodeList &list) {
^~~~~~~
/in/hashtable.hpp:429:64: error: base operand of '->' has non-pointer type 'HashTable<int, int, std::hash<int>, std::equal_to<int> >::HashTableData {aka std::vector<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > >, std::allocator<std::forward_list<std::pair<const int, int>, std::allocator<std::pair<const int, int> > > > >}'
firstBucketIt = std::find_if(buckets->begin(), buckets->end(), [](const HashNodeList &list) {
^~~~~~~
/in/hashtable.hpp:415:24: error: unused parameter 'bucketSize' [-Werror=unused-parameter]
void rehash(size_t bucketSize) {
^~~~~~~~~~
cc1plus: all warnings being treated as errors