Mercurial > hg > octave-avbm
changeset 6581:1a414f670635
[project @ 2007-04-25 22:34:52 by jwe]
author | jwe |
---|---|
date | Wed, 25 Apr 2007 22:35:22 +0000 |
parents | d2bb3b8a8d20 |
children | cb3f6d51b7b3 |
files | examples/myfunc.c examples/mystruct.c |
diffstat | 2 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/examples/myfunc.c +++ b/examples/myfunc.c @@ -5,8 +5,8 @@ { const char *nm; nm = mexFunctionName (); - mexPrintf("You called function: %s\n", nm); + mexPrintf ("You called function: %s\n", nm); if (strcmp (nm, "myfunc") == 0) - mexPrintf("This is the principal function\n", nm); + mexPrintf ("This is the principal function\n", nm); return; }
--- a/examples/mystruct.c +++ b/examples/mystruct.c @@ -11,12 +11,12 @@ mexErrMsgTxt ("expects struct"); for (i = 0; i < mxGetNumberOfFields (prhs[0]); i++) - for (j=0; j < mxGetNumberOfElements(prhs[0]); j++) + for (j = 0; j < mxGetNumberOfElements (prhs[0]); j++) { mexPrintf ("field %s(%d) = ", mxGetFieldNameByNumber (prhs[0], i), j); v = mxGetFieldByNumber (prhs[0], j, i); - mexCallMATLAB(0, 0, 1, &v, "disp"); + mexCallMATLAB (0, 0, 1, &v, "disp"); } v = mxCreateStructMatrix (2, 2, 2, keys);