Aldee Aldee - 1 month ago 4
C Question

What is the function of an asterisk before a function name?

I've been confused with what I see on most C programs that has unfamiliar function declaration for me.

void *func_name(void *param){

What does
imply for the function? My understanding about (
) in a variable type is that it creates a pointer to another variable thus it can be able to track what address at which the latter variable is stored in the memory. But in this case of a function, I don't know what this
asterisk implies.


The asterisk belongs to the return type, and not to the function name, i.e.:

void* func_name(void *param) { . . . . . }

It means that the function returns a void pointer.