Skip to content

Commit

Permalink
FIX: warning: __VA_ARGS__ can only appear in the expansion of a C99 v…
Browse files Browse the repository at this point in the history
…ariadic macro
  • Loading branch information
Oldes committed Dec 22, 2021
1 parent cf9b34b commit ea3e47a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion make/tools/make-reb-lib.reb
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,12 @@ func-header: [
demit [tab p2 ","]
remit [tab p1 "(*" p2l ")" p3 ";"]
args: count p3 #","
argsd: either find args "__VA_ARGS__" [
;warning: __VA_ARGS__ can only appear in the expansion of a C99 variadic macro
replace copy args "__VA_ARGS__" "..."
][ args ]
m: tail mlib
memit/nol ["#define " p2u args]
memit/nol ["#define " p2u argsd]
memit [pads m 35 " RL->" p2l args]
if w: find cmt "****" [append clear w "*/"]
memit ["/*^/**^-" spec "^/**" cmt newline]
Expand Down

0 comments on commit ea3e47a

Please sign in to comment.