So I created a dynamically allocated array of structs pretend that structtype is the name of the struct, and arr is the array.
structtype * arr;
arr = new structtype[counter+15];
Then I attempted to pass that array of structs into multiple types of functions with prototypes such as:
void read_info(structtype (&arr)[15], int integer);
and
void Append(structtype arr[15]);
In turn I got these errors:
error: cannot convert ‘structtype’ to ‘structtype (&)[15]’
and
error: cannot convert ‘structtype**’ to ‘structtype (&)[15]'
Can yall help me figure out how to get rid of these errors, for example dereferencing the pointer part of the array or something.