Skip to content

Commit ee2f258

Browse files
authored
Sort include (using the Google C++ style pattern). Also add some more includes where indirection inclusions were broken. (etr#184)
1 parent a53647e commit ee2f258

36 files changed

+140
-109
lines changed

examples/benchmark_nodelay.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
#include <httpserver.hpp>
21
#include <cstdlib>
32
#include <memory>
43

4+
#include <httpserver.hpp>
5+
56
#define PATH "/plaintext"
67
#define BODY "Hello, World!"
78

examples/benchmark_select.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
#include <httpserver.hpp>
21
#include <cstdlib>
32
#include <memory>
43

4+
#include <httpserver.hpp>
5+
56
#define PATH "/plaintext"
67
#define BODY "Hello, World!"
78

examples/benchmark_threads.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
#include <httpserver.hpp>
21
#include <cstdlib>
32
#include <memory>
43

4+
#include <httpserver.hpp>
5+
56
#define PATH "/plaintext"
67
#define BODY "Hello, World!"
78

examples/custom_access_log.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@
1818
USA
1919
*/
2020

21-
#include <httpserver.hpp>
2221
#include <iostream>
2322

23+
#include <httpserver.hpp>
24+
2425
using namespace httpserver;
2526

2627
void custom_access_log(const std::string& url) {

examples/deferred_with_accumulator.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@
1818
USA
1919
*/
2020

21+
#include <atomic>
2122
#include <chrono>
2223
#include <thread>
23-
#include <atomic>
24+
2425
#include <httpserver.hpp>
2526

2627
using namespace httpserver;

examples/hello_world.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@
1818
USA
1919
*/
2020

21-
#include <httpserver.hpp>
2221
#include <iostream>
2322

23+
#include <httpserver.hpp>
24+
2425
using namespace httpserver;
2526

2627
class hello_world_resource : public http_resource {

examples/service.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,12 @@
1818
USA
1919
*/
2020

21-
#include <httpserver.hpp>
22-
#include <iostream>
2321
#include <unistd.h>
22+
2423
#include <cstdio>
24+
#include <iostream>
25+
26+
#include <httpserver.hpp>
2527

2628
using namespace httpserver;
2729

src/details/http_endpoint.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
*/
2020

2121
#include "httpserver/details/http_endpoint.hpp"
22+
2223
#include "httpserver/http_utils.hpp"
2324
#include "httpserver/string_utilities.hpp"
2425

src/file_response.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@
1818
USA
1919
*/
2020

21-
#include <fcntl.h>
2221
#include "httpserver/file_response.hpp"
2322

23+
#include <fcntl.h>
24+
2425
using namespace std;
2526

2627
namespace httpserver

src/http_request.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,13 @@
1919
2020
*/
2121

22-
#include "httpserver/http_utils.hpp"
2322
#include "httpserver/http_request.hpp"
24-
#include "httpserver/string_utilities.hpp"
23+
2524
#include <iostream>
2625

26+
#include "httpserver/http_utils.hpp"
27+
#include "httpserver/string_utilities.hpp"
28+
2729
using namespace std;
2830

2931
namespace httpserver

0 commit comments

Comments
 (0)