I wrote the following function in C:
void dummy(int* my_array, int size)
{
//my implementation
}
Is there any way to check whether size is REALLY the size of my_array
?
For example, if I call the function and use for my_array
an array with 4 elements but pass 5 for size
, is there any way to know that 5 is not really the size of the array?
Thank you in evidence.