I do have a struct
struct xyz {
double x, y;
} *res;
Then I allocate memory with
res = malloc(100 * sizeof(struct xyz));
But I recieve an error "invalid conversion from ‘void’ to ‘main(int, const char)::xyz"***
I have also tried changing my malloc to this:
res = (double*)malloc(100 * sizeof(struct xyz));
But it also didnt work
Whats is wrong and how it should looks like?