Advertisement
Guest User

Huge error

a guest
Nov 1st, 2013
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.22 KB | None | 0 0
  1. task1Main.cpp: In function ‘void getInput()’:
  2. task1Main.cpp:39:78: error: no match for ‘operator<<’ in ‘std::operator<< [with _Traits = std::char_traits<char>]((* &(& std::operator<< [with _Traits = std::char_traits<char>]((* & std::cout), ((const char*)"Add item ")))->std::basic_ostream<_CharT, _Traits>::operator<< [with _CharT = char, _Traits = std::char_traits<char>](vint.std::vector<_Tp, _Alloc>::operator[] [with _Tp = int, _Alloc = std::allocator<int>, std::vector<_Tp, _Alloc>::reference = int&, std::vector<_Tp, _Alloc>::size_type = long unsigned int](((long unsigned int)i)))), ((const char*)" in, the bucket size = ")) << getSize(Bucket&) [with Bucket = std::vector<int>]()’
  3. task1Main.cpp:39:78: note: candidates are:
  4. /usr/include/c++/4.6/ostream:110:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::basic_ostream<_CharT, _Traits>::__ostream_type& (*)(std::basic_ostream<_CharT, _Traits>::__ostream_type&)) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  5. /usr/include/c++/4.6/ostream:110:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&) {aka std::basic_ostream<char>& (*)(std::basic_ostream<char>&)}’
  6. /usr/include/c++/4.6/ostream:119:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::basic_ostream<_CharT, _Traits>::__ios_type& (*)(std::basic_ostream<_CharT, _Traits>::__ios_type&)) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>, std::basic_ostream<_CharT, _Traits>::__ios_type = std::basic_ios<char>]
  7. /usr/include/c++/4.6/ostream:119:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&) {aka std::basic_ios<char>& (*)(std::basic_ios<char>&)}’
  8. /usr/include/c++/4.6/ostream:129:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  9. /usr/include/c++/4.6/ostream:129:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘std::ios_base& (*)(std::ios_base&)’
  10. /usr/include/c++/4.6/ostream:167:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long int) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  11. /usr/include/c++/4.6/ostream:167:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘long int’
  12. /usr/include/c++/4.6/ostream:171:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  13. /usr/include/c++/4.6/ostream:171:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘long unsigned int’
  14. /usr/include/c++/4.6/ostream:175:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(bool) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  15. /usr/include/c++/4.6/ostream:175:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘bool’
  16. /usr/include/c++/4.6/bits/ostream.tcc:93:5: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(short int) [with _CharT = char, _Traits = std::char_traits<char>]
  17. /usr/include/c++/4.6/bits/ostream.tcc:93:5: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘short int’
  18. /usr/include/c++/4.6/ostream:182:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(short unsigned int) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  19. /usr/include/c++/4.6/ostream:182:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘short unsigned int’
  20. /usr/include/c++/4.6/bits/ostream.tcc:107:5: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(int) [with _CharT = char, _Traits = std::char_traits<char>]
  21. /usr/include/c++/4.6/bits/ostream.tcc:107:5: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘int’
  22. /usr/include/c++/4.6/ostream:193:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(unsigned int) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  23. /usr/include/c++/4.6/ostream:193:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘unsigned int’
  24. /usr/include/c++/4.6/ostream:202:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long int) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  25. /usr/include/c++/4.6/ostream:202:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘long long int’
  26. /usr/include/c++/4.6/ostream:206:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long long unsigned int) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  27. /usr/include/c++/4.6/ostream:206:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘long long unsigned int’
  28. /usr/include/c++/4.6/ostream:211:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(double) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  29. /usr/include/c++/4.6/ostream:211:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘double’
  30. /usr/include/c++/4.6/ostream:215:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(float) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  31. /usr/include/c++/4.6/ostream:215:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘float’
  32. /usr/include/c++/4.6/ostream:223:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long double) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  33. /usr/include/c++/4.6/ostream:223:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘long double’
  34. /usr/include/c++/4.6/ostream:227:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(const void*) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
  35. /usr/include/c++/4.6/ostream:227:7: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘const void*’
  36. /usr/include/c++/4.6/bits/ostream.tcc:121:5: note: std::basic_ostream<_CharT, _Traits>& std::basic_ostream<_CharT, _Traits>::operator<<(std::basic_ostream<_CharT, _Traits>::__streambuf_type*) [with _CharT = char, _Traits = std::char_traits<char>, std::basic_ostream<_CharT, _Traits>::__streambuf_type = std::basic_streambuf<char>]
  37. /usr/include/c++/4.6/bits/ostream.tcc:121:5: note: no known conversion for argument 1 from ‘std::vector<int>’ to ‘std::basic_ostream<char>::__streambuf_type* {aka std::basic_streambuf<char>*}’
  38. /usr/include/c++/4.6/bits/basic_string.h:2693:5: note: template<class _CharT, class _Traits, class _Alloc> std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, const std::basic_string<_CharT, _Traits, _Alloc>&)
  39. /usr/include/c++/4.6/ostream:451:5: note: template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, _CharT)
  40. /usr/include/c++/4.6/ostream:456:5: note: template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, char)
  41. /usr/include/c++/4.6/ostream:462:5: note: template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(std::basic_ostream<char, _Traits>&, char)
  42. /usr/include/c++/4.6/ostream:468:5: note: template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(std::basic_ostream<char, _Traits>&, signed char)
  43. /usr/include/c++/4.6/ostream:473:5: note: template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(std::basic_ostream<char, _Traits>&, unsigned char)
  44. /usr/include/c++/4.6/ostream:493:5: note: template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, const _CharT*)
  45. /usr/include/c++/4.6/bits/ostream.tcc:323:5: note: template<class _CharT, class _Traits> std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, const char*)
  46. /usr/include/c++/4.6/ostream:510:5: note: template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(std::basic_ostream<char, _Traits>&, const char*)
  47. /usr/include/c++/4.6/ostream:523:5: note: template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(std::basic_ostream<char, _Traits>&, const signed char*)
  48. /usr/include/c++/4.6/ostream:528:5: note: template<class _Traits> std::basic_ostream<char, _Traits>& std::operator<<(std::basic_ostream<char, _Traits>&, const unsigned char*)
  49. task1Main.cpp:55:14: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
  50. task1Main.cpp:24:20: warning: unused variable ‘oFileName’ [-Wunused-variable]
  51. In file included from task1Main.cpp:13:0:
  52. MyLib.h: In function ‘Bucket getSize(Bucket&) [with Bucket = std::vector<int>]’:
  53. task1Main.cpp:39:78: instantiated from here
  54. MyLib.h:16:16: error: could not convert ‘(& x)->std::vector<_Tp, _Alloc>::size [with _Tp = int, _Alloc = std::allocator<int>, std::vector<_Tp, _Alloc>::size_type = long unsigned int]()’ from ‘std::vector<int>::size_type {aka long unsigned int}’ to ‘std::vector<int>’
  55. MyLib.h: In function ‘Bucket getCapacity(Bucket&) [with Bucket = std::vector<int>]’:
  56. task1Main.cpp:39:118: instantiated from here
  57. MyLib.h:22:20: error: could not convert ‘(& x)->std::vector<_Tp, _Alloc>::capacity [with _Tp = int, _Alloc = std::allocator<int>, std::vector<_Tp, _Alloc>::size_type = long unsigned int]()’ from ‘std::vector<int>::size_type {aka long unsigned int}’ to ‘std::vector<int>’
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement