浏览代码

Fix compatibility macros

Marcio T 4 年前
父节点
当前提交
9bbe9455cf
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4
    0
      Marlin/src/lcd/extui/lib/ftdi_eve_touch_ui/ftdi_eve_lib/compat.h

+ 4
- 0
Marlin/src/lcd/extui/lib/ftdi_eve_touch_ui/ftdi_eve_lib/compat.h 查看文件

@@ -206,6 +206,10 @@
206 206
 
207 207
   // Define macros for compatibility
208 208
 
209
+  // Use NUM_ARGS(__VA_ARGS__) to get the number of variadic arguments
210
+  #define _NUM_ARGS(_,Z,Y,X,W,V,U,T,S,R,Q,P,O,N,M,L,K,J,I,H,G,F,E,D,C,B,A,OUT,...) OUT
211
+  #define NUM_ARGS(V...) _NUM_ARGS(0,V,26,25,24,23,22,21,20,19,18,17,16,15,14,13,12,11,10,9,8,7,6,5,4,3,2,1,0)
212
+
209 213
   #define _CAT(a,V...) a##V
210 214
   #define CAT(a,V...) _CAT(a,V)
211 215
 

正在加载...
取消
保存