diff options
author | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2016-11-18 17:49:45 +0100 |
---|---|---|
committer | Willem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl> | 2016-11-18 17:58:13 +0100 |
commit | 51b2e49e08901fd649f8cc13b8ba1d33166e413f (patch) | |
tree | 7a699473cecd0f4e369e4fdcf8de4ca5c86fcf4f /matlab | |
parent | 6c9756b1d26d1e920b12cdcf8580362690427ddc (diff) | |
download | astra-51b2e49e08901fd649f8cc13b8ba1d33166e413f.tar.gz astra-51b2e49e08901fd649f8cc13b8ba1d33166e413f.tar.bz2 astra-51b2e49e08901fd649f8cc13b8ba1d33166e413f.tar.xz astra-51b2e49e08901fd649f8cc13b8ba1d33166e413f.zip |
Improve consts in matlab undocumented function declarations
Diffstat (limited to 'matlab')
-rw-r--r-- | matlab/mex/mexDataManagerHelpFunctions.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/matlab/mex/mexDataManagerHelpFunctions.cpp b/matlab/mex/mexDataManagerHelpFunctions.cpp index 1794abb..95d4640 100644 --- a/matlab/mex/mexDataManagerHelpFunctions.cpp +++ b/matlab/mex/mexDataManagerHelpFunctions.cpp @@ -42,10 +42,10 @@ $Id$ #ifdef USE_MATLAB_UNDOCUMENTED extern "C" { mxArray *mxCreateSharedDataCopy(const mxArray *pr); -bool mxUnshareArray(const mxArray *pr, const bool noDeepCopy); -mxArray *mxUnreference(const mxArray *pr); +bool mxUnshareArray(mxArray *pr, bool noDeepCopy); +mxArray *mxUnreference(mxArray *pr); #if 0 -// Unsupported in Matlab R2014b +// Unsupported in Matlab R2014b and later bool mxIsSharedArray(const mxArray *pr); #endif } @@ -66,12 +66,12 @@ public: // First unshare the input array, so that we may modify it. if (bUnshare) { #if 0 - // Unsupported in Matlab R2014b + // Unsupported in Matlab R2014b and later if (mxIsSharedArray(_pArray)) { fprintf(stderr, "Performance note: unsharing shared array in link\n"); } #endif - mxUnshareArray(_pArray, false); + mxUnshareArray(const_cast<mxArray*>(_pArray), false); //fprintf(stderr, "Unshared:\narray: %p\tdata: %p\n", (void*)_pArray, (void*)mxGetData(_pArray)); } // Then create a (persistent) copy so the data won't be deleted |