mirror of
https://github.com/gabime/spdlog.git
synced 2025-01-14 17:52:05 +08:00
Minor cleanup
This commit is contained in:
parent
bb3d25b626
commit
0ef49d7df6
@ -29,6 +29,7 @@ void replace_default_logger_example();
|
|||||||
|
|
||||||
#include "spdlog/cfg/env.h" // support for loading levels from the environment variable
|
#include "spdlog/cfg/env.h" // support for loading levels from the environment variable
|
||||||
#include "spdlog/spdlog.h"
|
#include "spdlog/spdlog.h"
|
||||||
|
#include "spdlog/version.h"
|
||||||
|
|
||||||
int main(int, char *[]) {
|
int main(int, char *[]) {
|
||||||
// Log levels can be loaded from argv/env using "SPDLOG_LEVEL"
|
// Log levels can be loaded from argv/env using "SPDLOG_LEVEL"
|
||||||
|
@ -19,7 +19,6 @@
|
|||||||
#include "./details/registry.h"
|
#include "./details/registry.h"
|
||||||
#include "./details/synchronous_factory.h"
|
#include "./details/synchronous_factory.h"
|
||||||
#include "./logger.h"
|
#include "./logger.h"
|
||||||
#include "./version.h"
|
|
||||||
|
|
||||||
namespace spdlog {
|
namespace spdlog {
|
||||||
|
|
||||||
|
@ -53,6 +53,5 @@ void spdlog::sinks::base_sink<Mutex>::set_formatter_(std::unique_ptr<spdlog::for
|
|||||||
}
|
}
|
||||||
|
|
||||||
// template instantiations
|
// template instantiations
|
||||||
|
|
||||||
template class SPDLOG_API spdlog::sinks::base_sink<std::mutex>;
|
template class SPDLOG_API spdlog::sinks::base_sink<std::mutex>;
|
||||||
template class SPDLOG_API spdlog::sinks::base_sink<spdlog::details::null_mutex>;
|
template class SPDLOG_API spdlog::sinks::base_sink<spdlog::details::null_mutex>;
|
@ -12,5 +12,5 @@ bool spdlog::sinks::sink::should_log(spdlog::level msg_level) const {
|
|||||||
void spdlog::sinks::sink::set_level(level level) { level_.store(level, std::memory_order_relaxed); }
|
void spdlog::sinks::sink::set_level(level level) { level_.store(level, std::memory_order_relaxed); }
|
||||||
|
|
||||||
spdlog::level spdlog::sinks::sink::log_level() const {
|
spdlog::level spdlog::sinks::sink::log_level() const {
|
||||||
return static_cast<spdlog::level>(level_.load(std::memory_order_relaxed));
|
return level_.load(std::memory_order_relaxed);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user