octave-maintainers
[Top][All Lists]
Advanced

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

Re: deftypefn vs. defun


From: Rik
Subject: Re: deftypefn vs. defun
Date: Thu, 21 Apr 2016 07:58:07 -0700

On 04/21/2016 07:25 AM, address@hidden wrote:
Subject:
deftypefn or defun (deffn)
From:
JuanPi <address@hidden>
Date:
04/21/2016 07:25 AM
To:
Maintainers GNU Octave <address@hidden>
List-Post:
<mailto:address@hidden>
Precedence:
list
MIME-Version:
1.0
Message-ID:
<address@hidden>
Content-Type:
text/plain; charset=UTF-8
Message:
6

Hi all,

Working with a documentation for  anew package I found that we use
deftypefn for m-files although functions in Octave are not typed
functions. Shouldn't we use defun (a.k.a. deffn) instead? That seem to
be the case for the Interval package, but maybe there is a reason tu
use the typed function command instead.

Juan,

The documentation only recently changed to drop the type field; The stable branch is still using the type field set to "Command", "Function File", etc.

On the development branch the choice was made to move incrementally so we have removed the type, but not changed the Texinfo command.  The first line of ls.m is

@deftypefn  {} {} ls

where the initial '{}' pair used to hold the type.  I think you should continue using this style since all of the core is based on it.  Eventually we may decide to switch to defun, but it would be easy at that point to just do a search and replace if all files are using the same syntax.

Cheers,
Rik

reply via email to

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