mirror of
https://github.com/gabime/spdlog.git
synced 2025-01-24 14:42:13 +08:00
Removed extra whitespace from SDPLOG_TRACE message
This commit is contained in:
parent
10e809cf64
commit
53ac379bc5
@ -5,6 +5,8 @@
|
|||||||
// spdlog main header file.
|
// spdlog main header file.
|
||||||
// see example.cpp for usage example
|
// see example.cpp for usage example
|
||||||
|
|
||||||
|
#ifndef SPDLOG_H
|
||||||
|
#define SPDLOG_H
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "spdlog/common.h"
|
#include "spdlog/common.h"
|
||||||
@ -12,6 +14,8 @@
|
|||||||
#include "spdlog/logger.h"
|
#include "spdlog/logger.h"
|
||||||
#include "spdlog/version.h"
|
#include "spdlog/version.h"
|
||||||
|
|
||||||
|
#include "spdlog/default_logger.h"
|
||||||
|
|
||||||
#include <chrono>
|
#include <chrono>
|
||||||
#include <functional>
|
#include <functional>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
@ -142,10 +146,12 @@ inline void shutdown()
|
|||||||
#define SPDLOG_STR_H(x) #x
|
#define SPDLOG_STR_H(x) #x
|
||||||
#define SPDLOG_STR_HELPER(x) SPDLOG_STR_H(x)
|
#define SPDLOG_STR_HELPER(x) SPDLOG_STR_H(x)
|
||||||
#ifdef _MSC_VER
|
#ifdef _MSC_VER
|
||||||
#define SPDLOG_TRACE(logger, ...) logger->trace("[ " __FILE__ "(" SPDLOG_STR_HELPER(__LINE__) ") ] " __VA_ARGS__)
|
#define SPDLOG_TRACE(logger, ...) \
|
||||||
|
logger->trace("[ "__FILE__ \
|
||||||
|
"(" SPDLOG_STR_HELPER(__LINE__) ")] " __VA_ARGS__)
|
||||||
#else
|
#else
|
||||||
#define SPDLOG_TRACE(logger, ...) \
|
#define SPDLOG_TRACE(logger, ...) \
|
||||||
logger->trace("[ " __FILE__ ":" SPDLOG_STR_HELPER(__LINE__) " ]" \
|
logger->trace("[" __FILE__ ":" SPDLOG_STR_HELPER(__LINE__) "]" \
|
||||||
" " __VA_ARGS__)
|
" " __VA_ARGS__)
|
||||||
#endif
|
#endif
|
||||||
#else
|
#else
|
||||||
@ -159,3 +165,5 @@ inline void shutdown()
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
} // namespace spdlog
|
} // namespace spdlog
|
||||||
|
|
||||||
|
#endif // #define SPDLOG_H
|
||||||
|
Loading…
Reference in New Issue
Block a user