The macro mwSize evaluates to a specific type at compile time depending on the current settings. For your case and from the error message, this appears to be size_t. So the effective signature for your particular case is:
And, from the error message, it appears you have maps_dim as an array of int. I.e., you have something like this in your code:
int maps_dim[2];
An int is a signed integer, probably 4 bytes on your system. A size_t is an unsigned integer, possibly 8 bytes on your system. You can't convert a pointer_to_int into a pointer_to_size_t because the underlying types are different. You need to make sure all of the pointer arguments in these function calls are exactly the same. So change your definition of maps_dim:
Looks like you have a mismatch with variable types, probably an older piece of code that you are trying to compile on a newer MATLAB version. E.g., the code probably has this definition:
const int *DimsBness;
when it should be this:
const mwSize *DimsBness;
And you probably have something like this:
const int *dims;
or this
int dims[] = {2,3}; /* or whatever */
when it should be this:
const mwSize *dims;
or this
mwSize dims[] = {2,3}; /* or whatever */
Simply update the code with the required types to fix these errors.
Best Answer