问题描述
以下宏有效:
#define DEBUG(msg,...) printf(msg,__VA_ARGS__)
但是当我添加自己的函数时,它显示 error: '__VA_ARGS__' was not declared in this scope
。
我的代码:
void Debug(const char* msg,...) {
printf(msg,__VA_ARGS__);
}
#define DEBUG(msg,...) Debug(msg,__VA_ARGS__)
有什么办法吗?
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)