Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.95 KB | None | 0 0
  1. In file included from Console.hpp:4:0,
  2. from main.cpp:1:
  3. /usr/include/c++/5.3.0/functional: In instantiation of 'struct std::_Bind_check_arity<unsigned int (A::*)(const std::vector<std::basic_string<char> >&), A&>':
  4. /usr/include/c++/5.3.0/functional:1439:12: required from 'struct std::_Bind_helper<false, unsigned int (A::*)(const std::vector<std::basic_string<char> >&), A&>'
  5. /usr/include/c++/5.3.0/functional:1462:5: required by substitution of 'template<class _Func, class ... _BoundArgs> typename std::_Bind_helper<std::__is_socketlike<_Func>::value, _Func, _BoundArgs ...>::type std::bind(_Func&&, _BoundArgs&& ...) [with _Func = unsigned int (A::*)(const std::vector<std::basic_string<char> >&); _BoundArgs = {A&}]'
  6. main.cpp:51:67: required from here
  7. /usr/include/c++/5.3.0/functional:1426:7: error: static assertion failed: Wrong number of arguments for pointer-to-member
  8. static_assert(_Varargs::value
  9. ^
  10. main.cpp: In function 'int main()':
  11. main.cpp:51:68: error: no matching function for call to 'CppReadline::Console::registerCommand(const char [6], std::_Bind_helper<false, unsigned int (A::*)(const std::vector<std::basic_string<char> >&), A&>::type)'
  12. context["main"]->registerCommand("pippo", std::bind(&A::pippo, a));
  13. ^
  14. In file included from main.cpp:1:0:
  15. Console.hpp:60:18: note: candidate: void CppReadline::Console::registerCommand(const string&, CppReadline::Console::CommandFunction)
  16. void registerCommand(const std::string & s, CommandFunction f);
  17. ^
  18. Console.hpp:60:18: note: no known conversion for argument 2 from 'std::_Bind_helper<false, unsigned int (A::*)(const std::vector<std::basic_string<char> >&), A&>::type {aka std::_Bind<std::_Mem_fn<unsigned int (A::*)(const std::vector<std::basic_string<char> >&)>(A)>}' to 'CppReadline::Console::CommandFunction {aka std::function<int(const std::vector<std::basic_string<char> >&)>}'
  19. main.cpp:52:68: error: no matching function for call to 'CppReadline::Console::registerCommand(const char [6], std::_Bind_helper<false, unsigned int (A::*)(const std::vector<std::basic_string<char> >&), A&>::type)'
  20. context["main"]->registerCommand("pippi", std::bind(&A::pippo, a));
  21. ^
  22. In file included from main.cpp:1:0:
  23. Console.hpp:60:18: note: candidate: void CppReadline::Console::registerCommand(const string&, CppReadline::Console::CommandFunction)
  24. void registerCommand(const std::string & s, CommandFunction f);
  25. ^
  26. Console.hpp:60:18: note: no known conversion for argument 2 from 'std::_Bind_helper<false, unsigned int (A::*)(const std::vector<std::basic_string<char> >&), A&>::type {aka std::_Bind<std::_Mem_fn<unsigned int (A::*)(const std::vector<std::basic_string<char> >&)>(A)>}' to 'CppReadline::Console::CommandFunction {aka std::function<int(const std::vector<std::basic_string<char> >&)>}'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement