Since functions with empty parameter lists can be passed a variable number of parameters in C, Suppose I have a function defined as :
void foo(){
// I want to access the parameters passed in here
}
And I call it with arguments, say
foo(1,2,3);
Is it possible for me to get a hold of the values of those passed arguments inside my foo() function? I'm hoping for something along the lines of $_ , the default variable in Perl.
EDIT: The kind of behavior im expecting is like the one depicted in this question : C function with no parameters behavior
undefined behavior
Maybe you need
Variadic Arguments