From 17a02a90411446a1fa526dc98c12ecc3b8108214 Mon Sep 17 00:00:00 2001 From: Joseph Lenox Date: Sat, 5 May 2018 17:36:20 -0500 Subject: [PATCH] Added generic error message to Log; print error type to console. --- xs/src/libslic3r/Log.hpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/xs/src/libslic3r/Log.hpp b/xs/src/libslic3r/Log.hpp index 419448a88..5eddac995 100644 --- a/xs/src/libslic3r/Log.hpp +++ b/xs/src/libslic3r/Log.hpp @@ -8,17 +8,21 @@ namespace Slic3r { class Log { public: static void fatal_error(std::string topic, std::wstring message) { - std::cerr << topic << ": "; + std::cerr << topic << " FERR" << ": "; + std::wcerr << message << std::endl; + } + static void error(std::string topic, std::wstring message) { + std::cerr << topic << " ERR" << ": "; std::wcerr << message << std::endl; } static void info(std::string topic, std::wstring message) { - std::clog << topic << ": "; + std::clog << topic << " INFO" << ": "; std::wclog << message << std::endl; } static void warn(std::string topic, std::wstring message) { - std::cerr << topic << ": "; + std::cerr << topic << " WARN" << ": "; std::wcerr << message << std::endl; }