Is the following code legal in C++?
void f(void* = 0) {} int main() { f(); }
Which page of the C++ standard states that this usage is lega
Yes, it's perfectly legal. An obvious example is found in N3485 8.3.6 Default Arguments/4:
[Example: the declaration void point(int = 3, int = 4); declares a function that can be called with zero, one, or two arguments of type int.
[Example: the declaration
void point(int = 3, int = 4);
declares a function that can be called with zero, one, or two arguments of type int.