The following code is a textbook example of a recursive variadic function overload. In both clang and GCC, it compiles cleanly, and main returns 36 (as expected):
main