I want to write a function prototype for a function, whose argument is a pointer to a struct.
int mult(struct Numbers *n)
However, the str
You must forward the declaration of the structure to tell the compiler that a struct with that name will be defined:
struct Numbers;
int mult(struct Numbers *n) {
}
struct Numbers {
int a;
int b;
int c;
};
Mind that the compiler is not able to determine the size in memory of the structure so you can't pass it by value.