Improved Logging, prefixed with thread_id now. (DEBUG build only)
added pEpErr() (DEBUG and RELEASE build) non-local vars names with len == 1 are not handy at allsync
parent
5d626151d3
commit
15a20035eb
@ -1,9 +1,12 @@
|
||||
#pragma once
|
||||
|
||||
#include <iostream>
|
||||
#include <thread>
|
||||
|
||||
#ifdef NDEBUG
|
||||
#define pEpLog(msg) do{}while(0)
|
||||
#else
|
||||
#include <iostream>
|
||||
#define pEpLog(msg) do{std::cerr << __FILE__ << "::" << __FUNCTION__ << " - " << msg << '\n';} while(0)
|
||||
#define pEpLog(msg) do{std::cout << "Thread:" << std::this_thread::get_id() << ' ' <<__FILE__ << "::" << __FUNCTION__ << " - " << msg << '\n';} while(0)
|
||||
#endif
|
||||
|
||||
#define pEpErr(msg) do{std::cerr << "Thread:" << std::this_thread::get_id() << ' ' <<__FILE__ << "::" << __FUNCTION__ << " - " << msg << '\n';} while(0)
|
Loading…
Reference in New Issue