octave-maintainers
[Top][All Lists]
Advanced

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

private functions/subfunctions (was: Re: difference between path / pathd


From: John W. Eaton
Subject: private functions/subfunctions (was: Re: difference between path / pathdef)
Date: Thu, 17 Jan 2008 15:09:07 -0500

On 17-Jan-2008, Ben Abbott wrote:

| On Jan 17, 2008, at 3:46 AM, John W. Eaton wrote:
| 
| > Is __extractpath__ only expected to be used in pathdef?  If so, why
| > not make it a subfunction of pathdef instead of having it in a
| > separate file?
| 
| I was originally hoping to share the code with savepath.m.

OK.  Is that possible?  If so, then let's eliminate some common code.

If not, then I think __extractpath__ should be a subfunction in
pathdef.m.

Also, now that we have private functions, I think we should adopt the
following guidelines:

  * Use __foo__ names for private and internal functions.

  * Move shared internal functions which are not intended to ever be
    called directly into private subdirectories.

  * Make sure that all internal functions that are only used in a
    single parent function are inserted in the parent as a
    subfunction.

We will also require a little Makefile machinery to handle private
functions in the Octave sources.  I can try to take a look at that.

jwe


reply via email to

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