Clean up includes
This commit is contained in:
parent
9aee820625
commit
47a2135093
@ -1,7 +1,10 @@
|
||||
#include "tcp.hpp"
|
||||
#include <cstddef>
|
||||
// Library includes
|
||||
#include <spdlog/spdlog.h>
|
||||
|
||||
// Project includes
|
||||
#include "tcp.hpp"
|
||||
|
||||
|
||||
int main() {
|
||||
spdlog::set_level(spdlog::level::debug);
|
||||
|
||||
|
||||
12
src/tcp.cpp
12
src/tcp.cpp
@ -1,18 +1,12 @@
|
||||
#include "tcp.hpp"
|
||||
|
||||
// C stdlib includes
|
||||
#include <arpa/inet.h>
|
||||
#include <cerrno>
|
||||
#include <cstdint>
|
||||
#include <expected>
|
||||
#include <fcntl.h>
|
||||
#include <netdb.h>
|
||||
#include <netinet/in.h>
|
||||
#include <netinet/tcp.h>
|
||||
#include <poll.h>
|
||||
#include <span>
|
||||
|
||||
// Library includes
|
||||
#include <spdlog/spdlog.h>
|
||||
#include <sys/socket.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
|
||||
namespace {
|
||||
|
||||
12
src/tcp.hpp
12
src/tcp.hpp
@ -1,24 +1,16 @@
|
||||
#pragma once
|
||||
|
||||
|
||||
// STL includes
|
||||
#include <array>
|
||||
#include <cerrno>
|
||||
#include <cstdint>
|
||||
#include <expected>
|
||||
#include <poll.h>
|
||||
#include <span>
|
||||
#include <spdlog/spdlog.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
// C stdlib includes
|
||||
#include <arpa/inet.h>
|
||||
#include <expected>
|
||||
#include <fcntl.h>
|
||||
#include <netdb.h>
|
||||
#include <netinet/in.h>
|
||||
#include <netinet/tcp.h>
|
||||
#include <sys/socket.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/poll.h>
|
||||
|
||||
|
||||
namespace tcp {
|
||||
|
||||
@ -1,7 +1,11 @@
|
||||
#include "tcp.hpp"
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
// STL includes
|
||||
#include <cstring>
|
||||
|
||||
// Project includes
|
||||
#include "tcp.hpp"
|
||||
|
||||
|
||||
TEST(TcpServer, Accept) {
|
||||
tcp::NonBlockingServer server{{.port = 1234}};
|
||||
|
||||
Loading…
Reference in New Issue
Block a user