Clang format sort includes

This commit is contained in:
gabime
2023-09-29 00:20:26 +03:00
parent a0e631802c
commit 463af69d41
81 changed files with 256 additions and 223 deletions

View File

@@ -2,12 +2,13 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/async_logger.h"
#include "spdlog/details/thread_pool.h"
#include "spdlog/sinks/sink.h"
#include <memory>
#include <string>
#include "spdlog/details/thread_pool.h"
#include "spdlog/sinks/sink.h"
spdlog::async_logger::async_logger(std::string logger_name,
sinks_init_list sinks_list,
std::weak_ptr<details::thread_pool> tp,

View File

@@ -2,14 +2,15 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/cfg/helpers.h"
#include "spdlog/details/registry.h"
#include "spdlog/spdlog.h"
#include <algorithm>
#include <sstream>
#include <string>
#include <utility>
#include "spdlog/details/registry.h"
#include "spdlog/spdlog.h"
namespace spdlog {
namespace cfg {
namespace helpers {

View File

@@ -1,15 +1,16 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/common.h"
#include "spdlog/details/file_helper.h"
#include "spdlog/details/os.h"
#include <cerrno>
#include <cstdio>
#include <string>
#include <tuple>
#include "spdlog/common.h"
#include "spdlog/details/os.h"
namespace spdlog {
namespace details {

View File

@@ -2,6 +2,7 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/details/log_msg.h"
#include "spdlog/details/os.h"
namespace spdlog {

View File

@@ -1,9 +1,10 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/common.h"
#include "spdlog/details/os.h"
#include <sys/stat.h>
#include <algorithm>
#include <array>
#include <chrono>
@@ -12,9 +13,11 @@
#include <cstring>
#include <ctime>
#include <string>
#include <sys/stat.h>
#include <thread>
#include "spdlog/common.h"
// clang-format off
#ifdef _WIN32
#include "spdlog/details/windows_include.h"
#include <fileapi.h> // for FlushFileBuffers
@@ -63,6 +66,7 @@
#define __has_feature(x) 0 // Compatibility with non-clang compilers.
#endif
// clang-format on
namespace spdlog {
namespace details {
namespace os {

View File

@@ -2,6 +2,7 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/details/registry.h"
#include "spdlog/common.h"
#include "spdlog/details/periodic_worker.h"
#include "spdlog/logger.h"

View File

@@ -1,10 +1,12 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include <cassert>
#include "spdlog/common.h"
#include "spdlog/details/thread_pool.h"
#include <cassert>
#include "spdlog/common.h"
namespace spdlog {
namespace details {

View File

@@ -2,12 +2,13 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/logger.h"
#include "spdlog/pattern_formatter.h"
#include "spdlog/sinks/sink.h"
#include <cstdio>
#include <mutex>
#include "spdlog/pattern_formatter.h"
#include "spdlog/sinks/sink.h"
namespace spdlog {
// public methods

View File

@@ -1,13 +1,7 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/details/fmt_helper.h"
#include "spdlog/details/log_msg.h"
#include "spdlog/details/os.h"
#include "spdlog/fmt/fmt.h"
#include "spdlog/formatter.h"
#include "spdlog/pattern_formatter.h"
#include "spdlog/common.h"
#include <algorithm>
#include <array>
@@ -19,6 +13,13 @@
#include <thread>
#include <utility>
#include "spdlog/common.h"
#include "spdlog/details/fmt_helper.h"
#include "spdlog/details/log_msg.h"
#include "spdlog/details/os.h"
#include "spdlog/fmt/fmt.h"
#include "spdlog/formatter.h"
namespace spdlog {
namespace details {

View File

@@ -1,13 +1,14 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/common.h"
#include "spdlog/pattern_formatter.h"
#include "spdlog/sinks/base_sink.h"
#include <memory>
#include <mutex>
#include "spdlog/common.h"
#include "spdlog/pattern_formatter.h"
template <typename Mutex>
spdlog::sinks::base_sink<Mutex>::base_sink()
: formatter_{std::make_unique<spdlog::pattern_formatter>()} {}

View File

@@ -3,16 +3,16 @@
#include "spdlog/sinks/rotating_file_sink.h"
#include "spdlog/common.h"
#include "spdlog/details/file_helper.h"
#include "spdlog/details/os.h"
#include "spdlog/fmt/fmt.h"
#include <cerrno>
#include <mutex>
#include <string>
#include <tuple>
#include "spdlog/common.h"
#include "spdlog/details/file_helper.h"
#include "spdlog/details/os.h"
#include "spdlog/fmt/fmt.h"
namespace spdlog {
namespace sinks {

View File

@@ -1,11 +1,12 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/sinks/stdout_color_sinks.h"
#include "spdlog/async.h"
#include "spdlog/common.h"
#include "spdlog/details/synchronous_factory.h"
#include "spdlog/logger.h"
#include "spdlog/sinks/stdout_color_sinks.h"
namespace spdlog {

View File

@@ -1,10 +1,13 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include <memory>
#include "spdlog/pattern_formatter.h"
#include "spdlog/sinks/stdout_sinks.h"
#include <memory>
#include "spdlog/pattern_formatter.h"
// clang-format off
#ifdef _WIN32
// under windows using fwrite to non-binary stream results in \r\r\n (see issue #1675)
// so instead we use ::FileWrite
@@ -18,6 +21,7 @@
#include <stdio.h> // _fileno(..)
#endif // _WIN32
// clang-format on
namespace spdlog {
namespace sinks {

View File

@@ -2,13 +2,14 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#ifdef _WIN32
#include "spdlog/common.h"
#include "spdlog/details/windows_include.h"
#include "spdlog/pattern_formatter.h"
#include "spdlog/sinks/wincolor_sink.h"
#include <wincon.h>
#include "spdlog/common.h"
#include "spdlog/details/windows_include.h"
#include "spdlog/pattern_formatter.h"
namespace spdlog {
namespace sinks {
template <typename ConsoleMutex>

View File

@@ -1,9 +1,10 @@
// Copyright(c) 2015-present, Gabi Melman & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#include "spdlog/spdlog.h"
#include "spdlog/common.h"
#include "spdlog/pattern_formatter.h"
#include "spdlog/spdlog.h"
namespace spdlog {