This avoids accidentally using transitively included headers.
+#include "client.h"
#include <msp/core/except.h>
#include <msp/net/resolve.h>
#include <msp/time/timedelta.h>
-#include "client.h"
#include "request.h"
#include "response.h"
+#include "formdata.h"
#include <msp/core/maputils.h>
#include "header.h"
#include "request.h"
#include "submessage.h"
#include "utils.h"
-#include "formdata.h"
using namespace std;
+#include "header.h"
#include <stdexcept>
#include <msp/strings/utils.h>
-#include "header.h"
#include "message.h"
using namespace std;
+#include "message.h"
#include <cstdlib>
#include <msp/core/maputils.h>
#include <msp/strings/format.h>
#include <msp/strings/utils.h>
-#include "message.h"
using namespace std;
+#include "request.h"
#include <msp/strings/format.h>
#include <msp/strings/regex.h>
#include <msp/strings/utils.h>
-#include "request.h"
#include "utils.h"
using namespace std;
+#include "response.h"
#include <msp/strings/format.h>
#include <msp/strings/utils.h>
-#include "response.h"
using namespace std;
+#include "server.h"
#include <exception>
#include <typeinfo>
#include <msp/core/maputils.h>
#include <msp/strings/utils.h>
#include "request.h"
#include "response.h"
-#include "server.h"
using namespace std;
+#include "utils.h"
#include <algorithm>
#include <msp/strings/format.h>
#include <msp/strings/regex.h>
#include <msp/strings/utils.h>
-#include "utils.h"
using namespace std;
+#include "version.h"
#include <msp/strings/format.h>
#include <msp/strings/lexicalcast.h>
#include <msp/strings/regex.h>
-#include "version.h"
using namespace std;
#include "platform_api.h"
-#include <msp/core/systemerror.h>
#include "clientsocket.h"
+#include <msp/core/systemerror.h>
#include "socket_private.h"
namespace Msp {
-#include <cstring>
#include "communicator.h"
+#include <cstring>
#include "streamsocket.h"
using namespace std;
-#include <stdexcept>
#include "platform_api.h"
#include "constants.h"
+#include <stdexcept>
using namespace std;
#include "platform_api.h"
+#include "datagramsocket.h"
#include <msp/core/systemerror.h>
#include <msp/io/handle_private.h>
#include <msp/strings/format.h>
-#include "datagramsocket.h"
#include "sockaddr_private.h"
#include "socket_private.h"
#include "platform_api.h"
-#include <msp/strings/format.h>
#include "inet.h"
+#include <msp/strings/format.h>
#include "sockaddr_private.h"
using namespace std;
+#include "inet6.h"
#include "platform_api.h"
#include <msp/strings/format.h>
-#include "inet6.h"
#include "sockaddr_private.h"
using namespace std;
+#include "protocol.h"
#include <cstring>
#include <string>
#include <msp/core/maputils.h>
#include <msp/strings/format.h>
#include <msp/strings/lexicalcast.h>
-#include "protocol.h"
using namespace std;
-#include "platform_api.h"
+#include "resolve.h"
#include <msp/core/systemerror.h>
#include <msp/strings/format.h>
+#include "platform_api.h"
#include "sockaddr_private.h"
#include "socket.h"
-#include "resolve.h"
using namespace std;
-#include <msp/core/except.h>
#include "serversocket.h"
+#include <msp/core/except.h>
using namespace std;
+#include "sockaddr.h"
#include <stdexcept>
#include "platform_api.h"
#include "inet.h"
#include "platform_api.h"
+#include "socket.h"
#include <msp/core/systemerror.h>
#include <msp/io/handle_private.h>
#include "sockaddr_private.h"
-#include "socket.h"
#include "socket_private.h"
using namespace std;
#include "platform_api.h"
+#include "streamserversocket.h"
#include <msp/core/refptr.h>
#include <msp/core/systemerror.h>
#include <msp/io/handle_private.h>
#include <msp/strings/format.h>
#include "sockaddr_private.h"
#include "socket_private.h"
-#include "streamserversocket.h"
#include "streamsocket.h"
using namespace std;
#include "platform_api.h"
+#include "streamsocket.h"
#include <msp/core/systemerror.h>
#include <msp/io/handle_private.h>
#include <msp/io/poll.h>
#include <msp/strings/format.h>
#include "sockaddr_private.h"
#include "socket_private.h"
-#include "streamsocket.h"
namespace Msp {
namespace Net {
+#include "platform_api.h"
+#include "socket.h"
#include <cerrno>
#include <unistd.h>
#include <fcntl.h>
-#include "platform_api.h"
#include <msp/core/systemerror.h>
#include <msp/io/handle_private.h>
#include <msp/time/rawtime_private.h>
#include "sockaddr_private.h"
-#include "socket.h"
#include "socket_private.h"
using namespace std;
+#include "platform_api.h"
+#include "unix.h"
#include <stdexcept>
#include <sys/un.h>
-#include "platform_api.h"
#include "sockaddr_private.h"
-#include "unix.h"
using namespace std;
-#include <iostream>
#include "platform_api.h"
+#include "socket.h"
+#include <iostream>
#include <msp/core/systemerror.h>
#include <msp/io/handle_private.h>
#include "sockaddr_private.h"
-#include "socket.h"
#include "socket_private.h"
using namespace std;
-#include <msp/core/except.h>
#include "platform_api.h"
-#include "sockaddr_private.h"
#include "unix.h"
+#include <msp/core/except.h>
+#include "sockaddr_private.h"
using namespace std;