Closed Alzathar closed 7 years ago
I don't think we can be compatible with a MATLAB version as old as 2008b. The oldest version we support right now is 2013a IIRC. I did some work to ensure Octave compatibility this summer, and it's possible that it also helped making the code compatible with older MATLAB versions. Does your code run for 2008b? Regardless, we need to clearly specify a minimum MATLAB version to support in the bindings.
Yes, I use SWIG with Matlab R2008b (32-bit/64-bit) under Windows 7 without problem. Matlab R2008b was the second version of Matlab that supports the new Object-Oriented Programming capabilities. In fact, it was introduced with Matlab R2008a.
Except the problem with the nargincheck
and nargoutcheck
functions, everything works fine.
I would suggest to have the version Matlab r2008b as the minimum version supported for the bindings as this is the oldest version tested.
OK, great. And unexpected. SwigMem used to rely on "mxGetProperty", which was added in 2011b. But since it's not available in Octave, I had to work around it.
… function ‘nargoutchk’ requires 3 arguments.
Mathworks updated the behaviour of nargcheck (nargincheck ancestor) and nargoutcheck since Matlab R2008b. Thus, the function SwigMem is not compatible with Matlab R2008b. The proposed workaround fixes that problem and simplify the number of test to realize (no need to test the minimum number of arguments as it is 0).