Boost logo

Boost Users :

Subject: [Boost-users] PropertyTree-JSON parser incompatible with Boost.ASIO?
From: Jonas Stöhr (stoehr_jonas_at_[hidden])
Date: 2014-05-24 10:48:10


Hello folks,

as this is my first post on this list, I am apologizing for mistakes I
maybe made in advance.

Anyway, to my question: For my current project I need both,
Boost.PropertyTree (and it's JSON parser), as well as Boost.ASIO. When
including both headers, it gives me an error at
boost/asio/detail/socket_types.hpp(24), saying that WinSock.h has
already been included. However, if I comment out the include for
json_parser.hpp, it does not give any compiler errors (except the
non-exisiting function read_json).

I am working under Visual Studio 2013 Professional on Windows Server
2012 R2, boost 1.55.

Minimal code to reproduce the issue:

#include <boost/property_tree/json_parser.hpp>
#include <boost/asio.hpp>

I hope that someboy can help.

Best regards,
Jonas Stoehr


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net