help-octave
[Top][All Lists]
Advanced

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

Re: class() and MATLAB compatibility


From: Christian Merkwirth
Subject: Re: class() and MATLAB compatibility
Date: Thu, 11 May 2006 23:02:27 +0200

Dear all,

I would really like to see the user defined data types implemented in
Octave, but I don't know almost anything about the implementation of
Octave, so I would not dare to develop any patch on my own. However,
it would be nice to help the maintainers in implementing this:

- Remembering how the transitions to classes worked from C to C++, a
first step could be to have structures available in Octave. Couldn't
structures be implemented by twisting the code for the cell arrays,
e.g. a structure is a masked cell array of size F by 1, F being the
number of data members (fields) of the structure ? Then the field
names are converted to an index to access the field content from the
cell array.
- Later the structures get a 'label' storing the name of their class
to make out of them class objects. The most important point is now to
call m-files that are in the class directory before all other m-files
of the same name somewhere else on the path.



Regards,
Christian Merkwirth



2006/5/11, John W. Eaton <address@hidden>:
On 11-May-2006, Paul Koufalas wrote:

| G'day Paul,
|
| The upstream author, Christian Merkwirth, of the MATLAB package I'm
| interested in, kindly wrote to me and is re-thinking porting his package
| to Octave.
|
| He might be interested in adding the missing class() capability / Matlab
| compatibility to Octave to do it; and he's a far better C++ programmer
| than I am, ;-)

Adding these features involves changes to core parts of Octave.  It
won't be trivial, and it will probably require someone with a good
knowledge of the internals (or someone willing to learn a lot about
the way Octave works).  If you or anyone else wants to work on this
project, it would be best to discuss the implementation on the
maintainers mailing list and work with us to make the changes
incrementally rather than by trying to implement it all independently
and then dump a large invasive patch on us (that would likely be
rejected).

Thanks,

jwe



--
Christian Merkwirth
Department for Information Technology ZTI
Faculty of Physics, Astronomy and Applied Computer Science
Jagiellonian University
Reymonta 4
PL 30-059 Krakow
Poland

tel: +48 12 663 5827
email: address@hidden
http://zti.if.uj.edu.pl/~merkwirth/index.html
skype: chrismerk



reply via email to

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