view examples/myhello.c @ 14500:f6b4236da9f8 gui

backout changeset 75cb16d1292b. If a change like this needs to be made on the gui branch, please start a discussion on the maintainers list about why it is needed. 75cb16d1292b
author John W. Eaton <jwe@octave.org>
date Tue, 27 Mar 2012 16:35:25 -0400
parents 4295d634797d
children be41c30bcb44
line wrap: on
line source

#include "mex.h"

void
mexFunction (int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
{
  mxArray *v = mxCreateDoubleMatrix (1, 1, mxREAL);

  double *data = mxGetPr (v);

  *data = 1.23456789;

  plhs[0] = v;
}