emacs-orgmode
[Top][All Lists]
Advanced

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

Re: Docstrings and literate programming (good practices?)


From: Samuel Wales
Subject: Re: Docstrings and literate programming (good practices?)
Date: Fri, 4 Nov 2022 00:13:30 -0700

my dry sensibilities say don't write ht same thing in the manual that
is well written in the docstring.  idk the issues however, other than
that once you do it in two places murphy's law says they will get out
of sync.

but surely an extractor could look for an interactive spec and things
like htat could subset the functions and text.

On 11/3/22, Marcin Borkowski <mbork@mbork.pl> wrote:
>
> On 2022-11-04, at 06:45, tomas@tuxteam.de wrote:
>
>> On Thu, Nov 03, 2022 at 08:03:05PM -0700, Samuel Wales wrote:
>>> i wonder if emacs or org has what you might call semi-literate or
>>> etaretil docstring functions?
>>>
>>> for example, you have a body of non-literate elisp code, and you have
>>> a manual.  it could be redundant to describe commands and what they do
>>> and their options, if the docstrings are good.
>>>
>>> why not include the docstrings of all commands in some nice format in
>>> the .org manual via some mechanism?
>>
>> Ah. Javadoc and their descendants. I tend to call that "illiterate
>> programming"...
>
> I spat my tea. :-)  Thanks, that's a nice one!
>
> Though this _may_ work in some cases.  For example, imagine you divide
> your package into two files – one with user-facing commands and another
> one with internal functions.  If you order the former one carefully, the
> "extract docstrings" might actually work as a documentation.
>
> Still, a "normal" documentation seems a better (even if more
> time-consuming) options.
>
> Also, such docstring-based documentation is still better than none.
>
> Best,
>
> --
> Marcin Borkowski
> http://mbork.pl
>
>


-- 
The Kafka Pandemic

A blog about science, health, human rights, and misopathy:
https://thekafkapandemic.blogspot.com



reply via email to

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