mexErrMsgIdAndTxt функционируйте информация об ошибке печати, и отключает ваш бинарный файл MEX. Для примера см. следующий код в .matlabroot/extern/examples/mx/mxcreatecellmatrixf.F
C Check for proper number of input and output arguments
if (nrhs .lt. 1) then
call mexErrMsgIdAndTxt( 'MATLAB:mxcreatecellmatrixf:minrhs',
+ 'One input argument required.')
end if
mexWarnMsgIdAndTxt функционируйте информация о печати, но не отключайте файл MEX. Для примера см. следующий код в .matlabroot/extern/examples/mx/mxgetepsf.F
C Check for equality within eps
do 20 j=1,elements
if ((abs(first(j) - second(j))).gt.(abs(second(j)*eps))) then
call mexWarnMsgIdAndTxt(
+ 'MATLAB:mxgetepsf:NotEqual',
+ 'Inputs are not the same within eps.')
go to 21
end if
20 continue
mexErrMsgIdAndTxt | mexWarnMsgIdAndTxt