aboutsummaryrefslogtreecommitdiff
path: root/src/main/log_helper.h
diff options
context:
space:
mode:
authorthecharlesblake2017-10-16 22:56:16 +0100
committerthecharlesblake2017-10-26 14:51:33 +0100
commitdc01ab729c749fbfd2421943198a038d126aa66c (patch)
tree7be21afce1e4cf67607a098e48a861256d69c159 /src/main/log_helper.h
parentAdd demo command line parsing (diff)
downloadmetasol-dc01ab729c749fbfd2421943198a038d126aa66c.tar.gz
metasol-dc01ab729c749fbfd2421943198a038d126aa66c.zip

Add simple black hole cmdline parse & err handling

Diffstat (limited to 'src/main/log_helper.h')
-rw-r--r--src/main/log_helper.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/main/log_helper.h b/src/main/log_helper.h
new file mode 100644
index 0000000..8e634a7
--- /dev/null
+++ b/src/main/log_helper.h
@@ -0,0 +1,17 @@
+//
+// Created by thecharlesblake on 10/16/17.
+//
+
+#ifndef SOLVITAIRE_LOG_HELPER_H
+#define SOLVITAIRE_LOG_HELPER_H
+
+#if defined NDEBUG
+ #define LOG_DEBUG(msg)
+#else
+ #define LOG_DEBUG(msg) BOOST_LOG_TRIVIAL(debug) << msg
+#endif
+#define LOG_INFO(msg) BOOST_LOG_TRIVIAL(info) << msg
+#define LOG_WARNING(msg) BOOST_LOG_TRIVIAL(warning) << msg
+#define LOG_ERROR(msg) BOOST_LOG_ERROR(error) << msg
+
+#endif //SOLVITAIRE_LOG_HELPER_H