Having the function definition:
void f(int) { }
I want to define:
int a;
but if the function definition c
It depends on what you want to do, where that variable shall be used. If it is in the function a template might be a good choice:
template
void foo(T ) {
T a;
}
Alternatively if you are outside the function and have the requirement to really know this you can use Boost.TypeTraits, i.e. function_traits will give int