Skip to content

Commit ad9263e

Browse files
committed
get actual param size when input param is zero
1 parent 5c0c467 commit ad9263e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

co_closure.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,11 @@ struct stCoClosure_t
2828
//-- 1.1 comac_argc
2929

3030
#define comac_get_args_cnt( ... ) comac_arg_n( __VA_ARGS__ )
31-
#define comac_arg_n( _1,_2,_3,_4,_5,_6,_7,N,...) N
31+
#define comac_arg_n( _0,_1,_2,_3,_4,_5,_6,_7,N,...) N
3232
#define comac_args_seqs() 7,6,5,4,3,2,1,0
3333
#define comac_join_1( x,y ) x##y
3434

35-
#define comac_argc( ... ) comac_get_args_cnt( __VA_ARGS__,comac_args_seqs() )
35+
#define comac_argc( ... ) comac_get_args_cnt( 0,##__VA_ARGS__,comac_args_seqs() )
3636
#define comac_join( x,y) comac_join_1( x,y )
3737

3838
//-- 1.2 repeat

0 commit comments

Comments
 (0)