~ubuntu-branches/ubuntu/hoary/scilab/hoary

« back to all changes in this revision

Viewing changes to examples/mex-examples/fmex/mexfunction3.F

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-09 22:58:21 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050109225821-473xr8vhgugxxx5j
Tags: 3.0-12
changed configure.in to build scilab's own malloc.o, closes: #255869

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
      subroutine mexfunction(nlhs,plhs,nrhs,prhs)
 
2
c     simple example of fortran mex.
 
3
c     usage a=mexf3(2)   see builder.sce
 
4
 
 
5
      integer*4 plhs(*), prhs(*)
 
6
c     FOR 64 bits MACHINES SHOULD BE integer*8
 
7
      integer nlhs, nrhs
 
8
c
 
9
      if (nrhs.ne.1) then
 
10
         call mexerrmsgtxt('Requires ONE input')
 
11
      endif
 
12
      if (nlhs.ne.1) then
 
13
         call mexerrmsgtxt('Requires ONE output!')
 
14
      endif
 
15
      plhs(1)=prhs(1)
 
16
      return
 
17
      end