Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

websocket example on your website does not compile with g++ #48

Closed
stkrwork opened this issue Mar 8, 2017 · 5 comments
Closed

websocket example on your website does not compile with g++ #48

stkrwork opened this issue Mar 8, 2017 · 5 comments
Assignees

Comments

@stkrwork
Copy link

stkrwork commented Mar 8, 2017

Here is the console output:
09:55:21 **** Incremental Build of configuration Debug for project SiliconTest ****
make pre-build main-build
iod_generate_symbols ../main.cpp ../symbols.h

Building file: ../main.cpp
Invoking: Cross G++ Compiler
g++ -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"main.d" -MT"main.o" -o "main.o" "../main.cpp"
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh: In instantiation of ‘auto sl::make_ws_route(const E&) [with E = iod::function_call_exp<s::_message_t, s::_text_t>]’:
/usr/include/silicon/remote_api.hh:40:41: required from ‘auto sl::make_ws_remote_api(P ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]’
/usr/include/silicon/backends/websocketpp_remote_client.hh:106:34: required from ‘auto sl::make_wspp_remote_client(const P& ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]’
../main.cpp:100:59: required from here
/usr/include/silicon/backends/ws_api.hh:144:21: error: no matching function for call to ‘route_cat(sl::ws_route<>, const iod::function_call_exp<s::_message_t, s::_text_t>&)’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:12:0,
from ../main.cpp:39:
/usr/include/silicon/http_route.hh:284:8: note: candidate: template<class ... R1, class ... R2> auto sl::route_cat(const sl::http_route<R1 ...>&, const sl::http_route<R2 ...>&)
auto route_cat(const http_route<R1...>& r1,
^~~~~~~~~
/usr/include/silicon/http_route.hh:284:8: note: template argument deduction/substitution failed:
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘sl::ws_route<>’ is not derived from ‘const sl::http_route<R1 ...>’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:12:0,
from ../main.cpp:39:
/usr/include/silicon/http_route.hh:291:8: note: candidate: template<class ... R1, class R2> auto sl::route_cat(const sl::http_route<R1 ...>&, const R2&)
auto route_cat(const http_route<R1...>& r1,
^~~~~~~~~
/usr/include/silicon/http_route.hh:291:8: note: template argument deduction/substitution failed:
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘sl::ws_route<>’ is not derived from ‘const sl::http_route<R1 ...>’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:13:0,
from ../main.cpp:39:
/usr/include/silicon/rmq_route.hh:164:7: note: candidate: template<class ... R1, class ... R2> auto sl::route_cat(const sl::rmq::route<R1 ...>&, const sl::rmq::route<R2 ...>&)
auto route_cat(rmq::route<R1...> const & r1,
^~~~~~~~~
/usr/include/silicon/rmq_route.hh:164:7: note: template argument deduction/substitution failed:
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘sl::ws_route<>’ is not derived from ‘const sl::rmq::route<R1 ...>’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:13:0,
from ../main.cpp:39:
/usr/include/silicon/rmq_route.hh:171:7: note: candidate: template<class ... R1, class R2> auto sl::route_cat(const sl::rmq::route<R1 ...>&, const R2&)
auto route_cat(rmq::route<R1...> const & r1,
^~~~~~~~~
/usr/include/silicon/rmq_route.hh:171:7: note: template argument deduction/substitution failed:
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘sl::ws_route<>’ is not derived from ‘const sl::rmq::route<R1 ...>’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:118:8: note: candidate: template<class S, class P, class SS> auto sl::route_cat(sl::ws_route<S, P>, const iod::symbol&)
auto route_cat(ws_route<S, P> r, const iod::symbol& s)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:118:8: note: template argument deduction/substitution failed:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘const iod::function_call_exp<s::_message_t, s::_text_t>’ is not derived from ‘const iod::symbol’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:124:8: note: candidate: template<class S, class P, class T> auto sl::route_cat(sl::ws_route<S, P>, const sl::params_t&)
auto route_cat(ws_route<S, P> r, const params_t& s)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:124:8: note: template argument deduction/substitution failed:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘const iod::function_call_exp<s::_message_t, s::_text_t>’ is not derived from ‘const sl::params_t’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:130:8: note: candidate: template<class S, class P, class L, class R> auto sl::route_cat(sl::ws_route<S, P>, const iod::div_exp<L, R>&)
auto route_cat(ws_route<S, P> r, const iod::div_exp<L, R>& e)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:130:8: note: template argument deduction/substitution failed:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘const iod::function_call_exp<s::_message_t, s::_text_t>’ is not derived from ‘const iod::div_exp<L, R>’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:136:8: note: candidate: template<class S, class P, class L, class R> auto sl::route_cat(sl::ws_route<S, P>, const iod::mult_exp<L, R>&)
auto route_cat(ws_route<S, P> r, const iod::mult_exp<L, R>& e)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:136:8: note: template argument deduction/substitution failed:
/usr/include/silicon/backends/ws_api.hh:144:21: note: ‘const iod::function_call_exp<s::_message_t, s::_text_t>’ is not derived from ‘const iod::mult_exp<L, R>’
return route_cat(ws_route<>(), e);
~~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from ../main.cpp:40:0:
/usr/include/silicon/remote_api.hh: In instantiation of ‘auto sl::make_ws_remote_api(P ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]’:
/usr/include/silicon/backends/websocketpp_remote_client.hh:106:34: required from ‘auto sl::make_wspp_remote_client(const P& ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]’
../main.cpp:100:59: required from here
/usr/include/silicon/remote_api.hh:40:27: error: invalid use of void expression
return std::make_tuple(make_ws_route(procs)...);
~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/silicon/backends/websocketpp.hh:13:0,
from ../main.cpp:41:
/usr/include/silicon/backends/websocketpp_remote_client.hh: In instantiation of ‘auto sl::make_wspp_remote_client(const P& ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]’:
../main.cpp:100:59: required from here
/usr/include/silicon/backends/websocketpp_remote_client.hh:106:48: error: ‘void api’ has incomplete type
auto api = make_ws_remote_api(procedures...);
^
/usr/include/silicon/backends/websocketpp_remote_client.hh:108:36: error: use of ‘auto iod::assignable::operator=(L&&) const [with L = std::shared_ptrsl::wspp_remote_client_ctx&; E = s::_silicon_ctx_t]’ before deduction of ‘auto’
auto accessor = D(_silicon_ctx = c);
~~~~~~~~~~~~~^~~
/usr/include/silicon/backends/websocketpp_remote_client.hh: In instantiation of ‘struct sl::make_wspp_remote_client(const P& ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]::<lambda(struct sl::wspp_connection)>’:
/usr/include/silicon/backends/websocketpp_remote_client.hh:116:5: required from ‘auto sl::make_wspp_remote_client(const P& ...) [with P = {iod::function_call_exp<s::_message_t, s::_text_t>}]’
../main.cpp:100:59: required from here
/usr/include/silicon/backends/websocketpp_remote_client.hh:111:13: error: using invalid field ‘sl::make_wspp_remote_client(const P& ...)::<lambda(sl::wspp_connection)>::’
return [rc] (wspp_connection c) {
^~
../main.cpp: In function ‘int main(int, char**)’:
../main.cpp:100:59: error: ‘void rclient’ has incomplete type
auto rclient = make_wspp_remote_client( _message(_text) );
^
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh: In instantiation of ‘sl::parse_api(std::tuple<_Args2 ...>, R)::<lambda(auto:65)>::<lambda(auto:67)> [with auto:67 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; auto:65 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::message_t>, main(int, char**)::<lambda(auto:136)> >}]’:
/usr/include/iod/utils.hh:24:19: required from ‘decltype(auto) iod::static_if
::operator()(F, G, A&& ...) [with F = sl::parse_api(std::tuple<_Args2 ...>, R)::<lambda(auto:65)> [with auto:65 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:66)>; G = sl::parse_api(std::tuple<_Args2 ...>, R)::<lambda(auto:65)> [with auto:65 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:67)>; A = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >&}]’
/usr/include/iod/utils.hh:31:27: required from ‘decltype(auto) iod::static_if(F, G, A&& ...) [with bool C = false; F = sl::parse_api(std::tuple<_Args2 ...>, R)::<lambda(auto:65)> [with auto:65 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:66)>; G = sl::parse_api(std::tuple<_Args2 ...>, R)::<lambda(auto:65)> [with auto:65 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:67)>; A = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >&}]’
/usr/include/silicon/api.hh:210:59: required from ‘sl::parse_api(std::tuple<_Args2 ...>, R)::<lambda(auto:65)> [with auto:65 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >; R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]’
/usr/include/iod/foreach.hh:116:29: required from ‘decltype(auto) iod::internal::tuple_foreach(F, T1&&, T&& ...) [with F = sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:65)>; T1 = std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> > >&; T = {}]’
/usr/include/iod/foreach.hh:146:44: required from ‘decltype(auto) iod::internal::foreach_tuple_caller::run(F, std::index_sequence<I ...>) [with F = sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:65)>; long unsigned int ...I = {0ul}; T = std::tuple<std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> > >&>; std::index_sequence<I ...> = std::integer_sequence<long unsigned int, 0ul>]’
/usr/include/iod/foreach.hh:152:76: required from ‘decltype(auto) iod::internal::foreach_tuple_caller::operator|(F) [with F = sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:65)>; T = std::tuple<std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> > >&>]’
/usr/include/silicon/api.hh:208:25: required from ‘auto sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]’
/usr/include/silicon/backends/ws_api.hh:150:21: required from ‘auto sl::ws_api(P ...) [with P = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]’
../main.cpp:110:5: required from here
/usr/include/silicon/api.hh:216:29: error: no matching function for call to ‘route_cat(sl::ws_route<>&, iod::function_call_exp<s::_broadcast_t, s::_message_t>&)’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:12:0,
from ../main.cpp:39:
/usr/include/silicon/http_route.hh:284:8: note: candidate: template<class ... R1, class ... R2> auto sl::route_cat(const sl::http_route<R1 ...>&, const sl::http_route<R2 ...>&)
auto route_cat(const http_route<R1...>& r1,
^~~~~~~~~
/usr/include/silicon/http_route.hh:284:8: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘sl::ws_route<>’ is not derived from ‘const sl::http_route<R1 ...>’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:12:0,
from ../main.cpp:39:
/usr/include/silicon/http_route.hh:291:8: note: candidate: template<class ... R1, class R2> auto sl::route_cat(const sl::http_route<R1 ...>&, const R2&)
auto route_cat(const http_route<R1...>& r1,
^~~~~~~~~
/usr/include/silicon/http_route.hh:291:8: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘sl::ws_route<>’ is not derived from ‘const sl::http_route<R1 ...>’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:13:0,
from ../main.cpp:39:
/usr/include/silicon/rmq_route.hh:164:7: note: candidate: template<class ... R1, class ... R2> auto sl::route_cat(const sl::rmq::route<R1 ...>&, const sl::rmq::route<R2 ...>&)
auto route_cat(rmq::route<R1...> const & r1,
^~~~~~~~~
/usr/include/silicon/rmq_route.hh:164:7: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘sl::ws_route<>’ is not derived from ‘const sl::rmq::route<R1 ...>’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/api.hh:13:0,
from ../main.cpp:39:
/usr/include/silicon/rmq_route.hh:171:7: note: candidate: template<class ... R1, class R2> auto sl::route_cat(const sl::rmq::route<R1 ...>&, const R2&)
auto route_cat(rmq::route<R1...> const & r1,
^~~~~~~~~
/usr/include/silicon/rmq_route.hh:171:7: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘sl::ws_route<>’ is not derived from ‘const sl::rmq::route<R1 ...>’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:136:8: note: candidate: template<class S, class P, class L, class R> auto sl::route_cat(sl::ws_route<S, P>, const iod::mult_exp<L, R>&)
auto route_cat(ws_route<S, P> r, const iod::mult_exp<L, R>& e)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:136:8: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘iod::function_call_exp<s::_broadcast_t, s::_message_t>’ is not derived from ‘const iod::mult_exp<L, R>’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:130:8: note: candidate: template<class S, class P, class L, class R> auto sl::route_cat(sl::ws_route<S, P>, const iod::div_exp<L, R>&)
auto route_cat(ws_route<S, P> r, const iod::div_exp<L, R>& e)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:130:8: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘iod::function_call_exp<s::_broadcast_t, s::_message_t>’ is not derived from ‘const iod::div_exp<L, R>’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:124:8: note: candidate: template<class S, class P, class T> auto sl::route_cat(sl::ws_route<S, P>, const sl::params_t&)
auto route_cat(ws_route<S, P> r, const params_t& s)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:124:8: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘iod::function_call_exp<s::_broadcast_t, s::_message_t>’ is not derived from ‘const sl::params_t’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
In file included from /usr/include/silicon/remote_api.hh:4:0,
from ../main.cpp:40:
/usr/include/silicon/backends/ws_api.hh:118:8: note: candidate: template<class S, class P, class SS> auto sl::route_cat(sl::ws_route<S, P>, const iod::symbol&)
auto route_cat(ws_route<S, P> r, const iod::symbol& s)
^~~~~~~~~
/usr/include/silicon/backends/ws_api.hh:118:8: note: template argument deduction/substitution failed:
In file included from ../main.cpp:39:0:
/usr/include/silicon/api.hh:216:29: note: ‘iod::function_call_exp<s::_broadcast_t, s::_message_t>’ is not derived from ‘const iod::symbol’
auto r = route_cat(route, m.left);
~~~~~~~~~^~~~~~~~~~~~~~~
../main.cpp:110:5: error: ‘void server_api’ has incomplete type
);
^
In file included from /usr/include/iod/grammar.hh:6:0,
from /usr/include/iod/sio.hh:9,
from /usr/include/silicon/api.hh:4,
from ../main.cpp:39:
/usr/include/iod/foreach.hh: At global scope:
/usr/include/iod/foreach.hh:27:5: error: ‘void iod::internal::tuple_foreach_impl(std::enable_if_t<std::is_same<void, Ret>::value>, std::index_sequence<TSize ...>, F, T&& ...) [with Ret = void; F = sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:65)>; long unsigned int ...TSize = {0ul}; long unsigned int ...Nargs = {}; T = {std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> > >&}; std::enable_if_t<std::is_same<void, Ret>::value> = void; std::index_sequence<TSize ...> = std::integer_sequence<long unsigned int, 0ul>]’, declared using local type ‘sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:65)>’, is used but never defined [-fpermissive]
tuple_foreach_impl(std::enable_if_t<std::is_same<void, Ret>::value>
,
^~~~~~~~~~~~~~~~~~
/usr/include/iod/foreach.hh:27:5: warning: ‘void iod::internal::tuple_foreach_impl(std::enable_if_t<std::is_same<void, Ret>::value>*, std::index_sequence<TSize ...>, F, T&& ...) [with Ret = void; F = sl::parse_api(std::tuple<_Args2 ...>, R) [with R = sl::ws_route<>; T = {iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> >}]::<lambda(auto:65)>; long unsigned int ...TSize = {0ul}; long unsigned int ...Nargs = {}; T = {std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, main(int, char**)::<lambda(auto:136)> > >&}]’ used but never defined
make: *** [main.o] Error 1
subdir.mk:18: recipe for target 'main.o' failed

09:55:28 Build Finished (took 6s.682ms)

I did fix the bug that a set was not regonized by adding the required include.

@stkrwork
Copy link
Author

stkrwork commented Mar 8, 2017

It does also not compile with clang++. Here is the log:

10:16:43 **** Incremental Build of configuration Debug for project SiliconTest ****
make pre-build main-build
iod_generate_symbols ../main.cpp ../symbols.h

Building file: ../main.cpp
Invoking: Cross G++ Compiler
clang++ -std=c++14 -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"main.d" -MT"main.o" -o "main.o" "../main.cpp"
In file included from ../main.cpp:40:
In file included from /include/silicon/remote_api.hh:4:
/include/silicon/backends/ws_api.hh:144:12: error: no matching function for call to 'route_cat'
return route_cat(ws_route<>(), e);
^~~~~~~~~
/include/silicon/remote_api.hh:40:28: note: in instantiation of function template specialization 'sl::make_ws_route<iod::function_call_exp<s::_message_t, s::_text_t> >' requested here
return std::make_tuple(make_ws_route(procs)...);
^
/include/silicon/backends/websocketpp_remote_client.hh:106:16: note: in instantiation of function template specialization 'sl::make_ws_remote_api<iod::function_call_exp<s::_message_t, s::_text_t> >' requested here
auto api = make_ws_remote_api(procedures...);
^
../main.cpp:100:18: note: in instantiation of function template specialization 'sl::make_wspp_remote_client<iod::function_call_exp<s::_message_t, s::_text_t> >' requested here
auto rclient = make_wspp_remote_client( _message(_text) );
^
/include/silicon/http_route.hh:284:8: note: candidate template ignored: could not match 'http_route' against 'ws_route'
auto route_cat(const http_route<R1...>& r1,
^
/include/silicon/http_route.hh:291:8: note: candidate template ignored: could not match 'http_route' against 'ws_route'
auto route_cat(const http_route<R1...>& r1,
^
/include/silicon/rmq_route.hh:164:7: note: candidate template ignored: could not match 'route' against 'ws_route'
auto route_cat(rmq::route<R1...> const & r1,
^
/include/silicon/rmq_route.hh:171:7: note: candidate template ignored: could not match 'route' against 'ws_route'
auto route_cat(rmq::route<R1...> const & r1,
^
/include/silicon/backends/ws_api.hh:118:8: note: candidate template ignored: could not match 'symbol' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const iod::symbol& s)
^
/include/silicon/backends/ws_api.hh:124:8: note: candidate template ignored: could not match 'params_t' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const params_t& s)
^
/include/silicon/backends/ws_api.hh:130:8: note: candidate template ignored: could not match 'div_exp' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const iod::div_exp<L, R>& e)
^
/include/silicon/backends/ws_api.hh:136:8: note: candidate template ignored: could not match 'mult_exp' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const iod::mult_exp<L, R>& e)
^
In file included from ../main.cpp:39:
/include/silicon/api.hh:216:20: error: no matching function for call to 'route_cat'
auto r = route_cat(route, m.left);
^~~~~~~~~
/include/iod/utils.hh:24:14: note: in instantiation of function template specialization 'sl::parse_api(std::tuple<assign_exp<function_call_exp<_broadcast_t, _message_t>, (lambda at ../main.cpp:106:28)> >, sl::ws_route<std::tuple<>, iod::sio<> >)::(anonymous class)::operator()(iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)>)::(anonymous class)::operator()<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> >' requested here
return else(std::forward(args)...);
^
/include/iod/utils.hh:31:12: note: in instantiation of function template specialization 'iod::static_if
::operator()<(lambda at /include/silicon/api.hh:211:9), (lambda at /include/silicon/api.hh:215:9), iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::message_t>, (lambda at ../main.cpp:106:28)> &>' requested here
return static_if
()(_if, _else, std::forward(args)...);
^
/include/silicon/api.hh:210:14: note: in instantiation of function template specialization 'iod::static_if<false, (lambda at /include/silicon/api.hh:211:9), (lambda at /include/silicon/api.hh:215:9), iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> &>' requested here
return static_if<is_tuple<decltype(m.right)>::value>(
^
/include/iod/foreach.hh:116:28: note: in instantiation of function template specialization 'sl::parse_api(std::tuple<assign_exp<function_call_exp<_broadcast_t, _message_t>, (lambda at ../main.cpp:106:28)> >, sl::ws_route<std::tuple<>, iod::sio<> >)::(anonymous class)::operator()<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> >' requested here
using Ret = decltype(f(std::get<0>(t1), std::get<0>(ts)...));
^
/include/iod/foreach.hh:146:31: note: in instantiation of function template specialization 'iod::internal::tuple_foreach<(lambda at /include/silicon/api.hh:208:27), std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::message_t>, (lambda at ../main.cpp:106:28)> > &>' requested here
return iod::internal::tuple_foreach(f, std::get(t
)...);
^
/include/iod/foreach.hh:152:16: note: in instantiation of function template specialization 'iod::internal::foreach_tuple_caller<std::tuple<std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> > &> >::run<(lambda at /include/silicon/api.hh:208:27), 0>' requested here
return run(f, std::make_index_sequence<std::tuple_size::value>{});
^
/include/silicon/api.hh:208:25: note: in instantiation of function template specialization 'iod::internal::foreach_tuple_caller<std::tuple<std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> > &> >::operator|<(lambda at /include/silicon/api.hh:208:27)>' requested here
return foreach(api) | [&] (auto m) // m should be iod::assign_exp
^
/include/silicon/backends/ws_api.hh:150:12: note: in instantiation of function template specialization 'sl::parse_api<sl::ws_route<std::tuple<>, iod::sio<> >, iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> >' requested here
return parse_api(std::make_tuple(procs...), ws_route<>());
^
../main.cpp:103:21: note: in instantiation of function template specialization 'sl::ws_api<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> >' requested here
auto server_api = ws_api(
^
/include/silicon/http_route.hh:284:8: note: candidate template ignored: could not match 'http_route' against 'ws_route'
auto route_cat(const http_route<R1...>& r1,
^
/include/silicon/http_route.hh:291:8: note: candidate template ignored: could not match 'http_route' against 'ws_route'
auto route_cat(const http_route<R1...>& r1,
^
/include/silicon/rmq_route.hh:164:7: note: candidate template ignored: could not match 'route' against 'ws_route'
auto route_cat(rmq::route<R1...> const & r1,
^
/include/silicon/rmq_route.hh:171:7: note: candidate template ignored: could not match 'route' against 'ws_route'
auto route_cat(rmq::route<R1...> const & r1,
^
/include/silicon/backends/ws_api.hh:118:8: note: candidate template ignored: could not match 'symbol' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const iod::symbol& s)
^
/include/silicon/backends/ws_api.hh:124:8: note: candidate template ignored: could not match 'params_t' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const params_t& s)
^
/include/silicon/backends/ws_api.hh:130:8: note: candidate template ignored: could not match 'div_exp' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const iod::div_exp<L, R>& e)
^
/include/silicon/backends/ws_api.hh:136:8: note: candidate template ignored: could not match 'mult_exp' against 'function_call_exp'
auto route_cat(ws_route<S, P> r, const iod::mult_exp<L, R>& e)
^
In file included from ../main.cpp:39:
In file included from /include/silicon/api.hh:4:
In file included from /include/iod/sio.hh:9:
In file included from /include/iod/grammar.hh:6:
/include/iod/foreach.hh:22:14: error: no matching function for call to object of type '(lambda at /include/silicon/api.hh:208:27)'
return f(std::get(ts)...);
^
/include/iod/foreach.hh:41:45: note: in instantiation of function template specialization 'iod::internal::tuple_foreach_i<0, (lambda at /include/silicon/api.hh:208:27), std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> > &>' requested here
return std::make_tuple(iod::internal::tuple_foreach_i(f, std::forward(ts)...)...);
^
/include/iod/foreach.hh:117:29: note: in instantiation of function template specialization 'iod::internal::tuple_foreach_impl<int, (lambda at /include/silicon/api.hh:208:27), 0, std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> > &>' requested here
return iod::internal::tuple_foreach_impl(0, seq{},
^
/include/iod/foreach.hh:146:31: note: in instantiation of function template specialization 'iod::internal::tuple_foreach<(lambda at /include/silicon/api.hh:208:27), std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::message_t>, (lambda at ../main.cpp:106:28)> > &>' requested here
return iod::internal::tuple_foreach(f, std::get(t
)...);
^
/include/iod/foreach.hh:152:16: note: in instantiation of function template specialization 'iod::internal::foreach_tuple_caller<std::tuple<std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> > &> >::run<(lambda at /include/silicon/api.hh:208:27), 0>' requested here
return run(f, std::make_index_sequence<std::tuple_size::value>{});
^
/include/silicon/api.hh:208:25: note: in instantiation of function template specialization 'iod::internal::foreach_tuple_caller<std::tuple<std::tuple<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> > &> >::operator|<(lambda at /include/silicon/api.hh:208:27)>' requested here
return foreach(api) | [&] (auto m) // m should be iod::assign_exp
^
/include/silicon/backends/ws_api.hh:150:12: note: in instantiation of function template specialization 'sl::parse_api<sl::ws_route<std::tuple<>, iod::sio<> >, iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> >' requested here
return parse_api(std::make_tuple(procs...), ws_route<>());
^
../main.cpp:103:21: note: in instantiation of function template specialization 'sl::ws_api<iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)> >' requested here
auto server_api = ws_api(
^
/include/silicon/api.hh:208:27: note: candidate template ignored: substitution failure [with $0 = iod::assign_exp<iod::function_call_exp<s::_broadcast_t, s::_message_t>, (lambda at ../main.cpp:106:28)>]
return foreach(api) | [&] (auto m) // m should be iod::assign_exp
^
3 errors generated.
make: *** [main.o] Error 1
subdir.mk:18: recipe for target 'main.o' failed

10:16:52 Build Finished (took 8s.181ms)

@matt-42 matt-42 self-assigned this Mar 9, 2017
@matt-42
Copy link
Owner

matt-42 commented Mar 10, 2017

Thanks for this report, I'll have a look this week end. I'll also add the compilation of this example too travis-ci.

@matt-42
Copy link
Owner

matt-42 commented Mar 11, 2017

Which version of g++ and clang do you have ? I have no problem compiling the websocket broadcast example (examples/ws_broadcast_server.cc) with g++6.3.1 and clang-3.9.1.

@stkrwork
Copy link
Author

stkrwork commented Mar 13, 2017

i used the example on your documentation website. I already found the error, there is a difference at rcclient. the parameters passed on to it in the code on the docu site is different than in the code in the examples/ folder.

This is the example I used that time:
http://siliconframework.org/docs/websocketpp.html

@matt-42
Copy link
Owner

matt-42 commented Mar 13, 2017

I'll replace the code of this page by a link to the real example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants