chore.宏学!

This commit is contained in:
MistEO
2022-01-09 17:12:19 +08:00
parent d927c59225
commit 5885af6845
2 changed files with 7 additions and 5 deletions

View File

@@ -511,8 +511,6 @@ void Assistant::working_proc()
std::unique_lock<std::mutex> lock(m_mutex);
if (!m_thread_idle && !m_tasks_queue.empty()) {
auto start_time = std::chrono::steady_clock::now();
auto task_ptr = m_tasks_queue.front();
m_tasks_queue.pop();

View File

@@ -201,8 +201,12 @@ namespace asst
std::chrono::time_point<std::chrono::steady_clock> m_start_time;
};
//static auto& log = Logger::get_instance();
#define _Cat_(a, b) a ## b
#define _Cat(a, b) _Cat_(a, b)
#define _CatVarNameWithLine(Var) _Cat(Var, __LINE__)
#define Log Logger::get_instance()
#define LogTraceFunction LoggerAux _func_aux(__FUNCTION__)
#define LogTraceScope LoggerAux _func_aux
#define LogTraceScope LoggerAux _CatVarNameWithLine(_func_aux_)
#define LogTraceFunction LogTraceScope(__FUNCTION__)
#define LogTraceFunctionWithArgs // how to do this?, like LogTraceScope(__FUNCTION__, __FUNCTION_ALL_ARGS__)
}