Variadic macros with zero arguments

前端 未结 7 1239
失恋的感觉
失恋的感觉 2020-12-14 16:06

I am working on a call macro,

#define CALL(f,...) FN(f)->call((ref(new LinkedList()), __VA_ARGS__))

which when called,

C         


        
7条回答
  •  -上瘾入骨i
    2020-12-14 16:34

    Simply make f part of the ..., and use a separate macro to extract the first argument where you need f.

提交回复
热议问题