#include <stdio.h>
#include <cstdarg>
// 定义log0函数,这里简化为仅打印日志
void log0(const char* file, const char* function, int line, int level, const char* format, ...) {
va_list args;
va_start(args, format);
printf("[%s:%s:%d] Level %d: ", file, function, line, level
c/c++ | 一个手动打印日志的demo | 可变参数
于 2024-03-15 09:28:33 首次发布