In file included from /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/bits/move.h:57:0,
from /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/bits/stl_pair.h:61,
from /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/bits/stl_algobase.h:65,
from /usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/vector:61,
from main.cpp:1:
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/type_traits: In instantiation of 'struct std::_Result_of_memfun<std::pair<int, int> (A::*)(int, int), int&, int&>':
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/type_traits:1847:12: required from 'struct std::_Result_of_impl<false, true, std::pair<int, int> (A::*)(int, int), int&, int&>'
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/type_traits:1857:12: required from 'class std::result_of<std::pair<int, int> (A::*(int&, int&))(int, int)>'
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future:1486:5: required by substitution of 'template<class _Fn, class ... _Args> std::future<typename std::result_of<_Functor(_ArgTypes ...)>::type> std::async(std::launch, _Fn&&, _Args&& ...) [with _Fn = std::pair<int, int> (A::*)(int, int); _Args = {int&, int&}]'
main.cpp:61:50: required from here
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/type_traits:1823:9: error: cannot apply member pointer 'std::declval<std::pair<int, int> (A::*)(int, int)>()' to 'std::_Result_of_memfun<_Res _Class::*, _Arg, _Args ...>::_S_get<int&>((* & A(std::declval<int&>(), 2)))', which is of non-class type 'int'
main.cpp: In member function 'void A::run()':
main.cpp:61:50: error: no matching function for call to 'async(std::launch, <unresolved overloaded function type>, int&, int&)'
main.cpp:61:50: note: candidates are:
In file included from main.cpp:3:0:
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future:1486:5: note: template<class _Fn, class ... _Args> std::future<typename std::result_of<_Functor(_ArgTypes ...)>::type> std::async(std::launch, _Fn&&, _Args&& ...)
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future:1486:5: note: substitution of deduced template arguments resulted in errors seen above
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future:1507:5: note: template<class _Fn, class ... _Args> typename std::__async_sfinae_helper<typename std::decay<_Func>::type, _Fn, _Args ...>::type std::async(_Fn&&, _Args&& ...)
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future:1507:5: note: template argument deduction/substitution failed:
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future: In substitution of 'template<class _Fn, class ... _Args> typename std::__async_sfinae_helper<typename std::decay<_Func>::type, _Fn, _Args ...>::type std::async(_Fn&&, _Args&& ...) [with _Fn = std::launch; _Args = {std::pair<int, int> (A::*)(int, int), int&, int&}]':
main.cpp:61:50: required from here
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.1/../../../../include/c++/4.7.1/future:1507:5: error: no type named 'type' in 'struct std::__async_sfinae_helper<std::launch, std::launch, std::pair<int, int> (A::*)(int, int), int&, int&>'
main.cpp:61:50: error: unable to deduce 'auto' from '<expression error>' |