help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lasterror (stack.name)


From: gOS
Subject: Re: lasterror (stack.name)
Date: Wed, 4 Jun 2008 09:25:01 -0700 (PDT)


John W. Eaton wrote:
> 
> How about making that easy, by posting a *complete* example that
> someone could easily run?
> 
> jwe
> 

Whoever does this will have to compile the mex file themselves.

As per request, here is an example:

moo.m

function moo
  try
    foo
  catch
    lasterror
  end
end
  
==============================================================================
  
foo.c

void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
{
  mexErrMsgIdAndTxt("component:mnemonic","This is an error message.");
}

I have no idea what Matlab does in this case so I have no idea whether its a
bug or not. I'm just trying to find out if this is the expected behavour or
if its likely that in the future my approach to solve this problem won't
work because the strings are created differently, etc.

I'm more worried about relying on a string supplied by octave that could
change with the next release than I am about the actual behavior I see now.
Though it would be nice to know what matlab does, if anyone does know please
reply.


-- 
View this message in context: 
http://www.nabble.com/lasterror-%28stack.name%29-tp17647642p17650760.html
Sent from the Octave - General mailing list archive at Nabble.com.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]