octave-maintainers
[Top][All Lists]
Advanced

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

Re: Perl for DOCSTRINGs


From: Daniel J Sebald
Subject: Re: Perl for DOCSTRINGs
Date: Thu, 28 Apr 2016 21:06:19 -0500
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111108 Fedora/3.1.16-1.fc14 Thunderbird/3.1.16

On 04/28/2016 06:16 PM, Rik wrote:
On 04/28/2016 03:53 PM, address@hidden wrote:
Subject:
Re: how to not break cross-building
From:
"John W. Eaton" <address@hidden>

[snip]

Either way, I think we could eliminate the need for the preprocessor
just having a perl script search for DEFUN and extract the docstrings.
But it would be simpler to not have to deal with escape sequences.

This was discussed way back at OctConf 2012 in Montreal.  jwe
implemented his half, adding support for a separate file to hold
docstrings that could be read when Octave started.  I got about halfway
through the Perl script and then became busy with other projects.  I'm
still busy, but will take a look at this again.  It would be really nice
not to have to have to mess with escape sequences.

Another alternative is to write an Octave script to do the same thing as the Perl script. Once Octave is built, run a script that descends into the directory tree and extracts the C strings. I'm recalling some Octave commands that process escape sequences, so maybe the C-string escape-sequence work intended to avoid is already built into some simply Octave command. Commands like "dir", etc. give a list of directories, file names. The advantage is that the Octave script is by default portable across systems. The drawback is that Octave has to build and run properly to get the documentation, if that is a problem.

Dan



reply via email to

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