From 0bead6efde1827b54ee1f02f2b083ea28c6959b4 Mon Sep 17 00:00:00 2001 From: Steven Peters Date: Wed, 9 Dec 2015 11:53:22 -0800 Subject: [PATCH] Add namespace prefix to macros Prepend CONSOLE_BRIDGE_ to macros in console.h Fixes #18. --- include/console_bridge/console.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/include/console_bridge/console.h b/include/console_bridge/console.h index 83776e5..8f17346 100644 --- a/include/console_bridge/console.h +++ b/include/console_bridge/console.h @@ -63,6 +63,18 @@ \} */ +#define CONSOLE_BRIDGE_logError(fmt, ...) \ + console_bridge::log(__FILE__, __LINE__, console_bridge::CONSOLE_BRIDGE_LOG_ERROR, fmt, ##__VA_ARGS__) + +#define CONSOLE_BRIDGE_logWarn(fmt, ...) \ + console_bridge::log(__FILE__, __LINE__, console_bridge::CONSOLE_BRIDGE_LOG_WARN, fmt, ##__VA_ARGS__) + +#define CONSOLE_BRIDGE_logInform(fmt, ...) \ + console_bridge::log(__FILE__, __LINE__, console_bridge::CONSOLE_BRIDGE_LOG_INFO, fmt, ##__VA_ARGS__) + +#define CONSOLE_BRIDGE_logDebug(fmt, ...) \ + console_bridge::log(__FILE__, __LINE__, console_bridge::CONSOLE_BRIDGE_LOG_DEBUG, fmt, ##__VA_ARGS__) + #define logError(fmt, ...) console_bridge::log(__FILE__, __LINE__, console_bridge::CONSOLE_BRIDGE_LOG_ERROR, fmt, ##__VA_ARGS__) #define logWarn(fmt, ...) console_bridge::log(__FILE__, __LINE__, console_bridge::CONSOLE_BRIDGE_LOG_WARN, fmt, ##__VA_ARGS__)