printing a function name in C++
#include <iostream> static void fooBar() { std::cout << "Calling " << __func__; }