From 9b6d4c5cdc1ad7b12b8b7ba05125dad9ba2d396e Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Wed, 20 Aug 2014 10:51:18 +0200 Subject: [PATCH] Move strprintf define to tinyformat.h This avoids a dependency on util.h if just tinyformat is needed. --- src/core.cpp | 2 +- src/tinyformat.h | 2 ++ src/util.h | 1 - 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/core.cpp b/src/core.cpp index 2a5e2a372b..71d6fea610 100644 --- a/src/core.cpp +++ b/src/core.cpp @@ -5,7 +5,7 @@ #include "core.h" -#include "util.h" +#include "tinyformat.h" std::string COutPoint::ToString() const { diff --git a/src/tinyformat.h b/src/tinyformat.h index b6113029f5..929cb66e4d 100644 --- a/src/tinyformat.h +++ b/src/tinyformat.h @@ -1007,4 +1007,6 @@ TINYFORMAT_WRAP_FORMAT_N(16, returnType, funcName, funcDeclSuffix, bodyPrefix, s } // namespace tinyformat +#define strprintf tfm::format + #endif // TINYFORMAT_H_INCLUDED diff --git a/src/util.h b/src/util.h index db2005337b..1fb42a7b7e 100644 --- a/src/util.h +++ b/src/util.h @@ -108,7 +108,6 @@ bool LogAcceptCategory(const char* category); /* Send a string to the log output */ int LogPrintStr(const std::string &str); -#define strprintf tfm::format #define LogPrintf(...) LogPrint(NULL, __VA_ARGS__) /* When we switch to C++11, this can be switched to variadic templates instead