Hello.
I ran into a couple of issues trying to build examples with MSVS2015 update3 on Windows:
Error in the tcpechotest.cpp:
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\include\random(2387): error C2338: invalid template argument for uniform_int_distribution
F:\dump\sockpp\examples\tcp\tcpechotest.cpp(92): note: see reference to class template instantiation 'std::uniform_int_distribution<char>' being compiled
This is because the template parameter of std::uniform_int_distribution must be either: int, short, long, long long or their unsigned counterpart. Please see Template parameters section here: std::uniform_int_distribution
Error in the udpechosvr.cpp:
F:\dump\sockpp\examples\udp\udpechosvr.cpp(75): error C2666: 'sockpp::datagram_socket_tmpl<sockpp::inet_address>::send_to': 2 overloads have similar conversions
F:\dump\sockpp\include\sockpp/datagram_socket.h(355): note: could be 'ssize_t sockpp::datagram_socket_tmpl<sockpp::inet_address>::send_to(const void *,std::size_t,const ADDR &)'
<...>
F:\dump\sockpp\include\sockpp/datagram_socket.h(345): note: or 'ssize_t sockpp::datagram_socket_tmpl<sockpp::inet_address>::send_to(const std::string &,int,const ADDR &)'
Hello. I ran into a couple of issues trying to build examples with MSVS2015 update3 on Windows:
This is because the template parameter of std::uniform_int_distribution must be either:
int
,short
,long
,long long
or their unsigned counterpart. Please seeTemplate parameters
section here: std::uniform_int_distributionYou can see the full error text for the 2nd issue here: https://gist.github.com/tsilia/6c9959ad0393a211970160c598a7cd41