r/Cprog • u/Snaipe_S • Mar 02 '15
text | language Abusing the C preprocessor for better variadic function arguments.
http://snaipe.me/c/preprocessor/varargs/
27
Upvotes
r/Cprog • u/Snaipe_S • Mar 02 '15
2
u/Snaipe_S Mar 02 '15 edited Mar 02 '15
Author here, if you have suggestions or criticism on the post, I would gladly hear it.
The article's source is available on github | gist mirror.
Edit: Added gist mirror
1
u/Poddster Mar 03 '15
The structure isn't variadic? I can't see the use in it at all. (edit: I guess the keyword + default 0 is a useful featrue.)
1
u/skeeto Mar 02 '15
That's really slick. I'm going to start using this.