help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Supplying DOC string in a `defun' using `defvar'


From: 2QdxY4RzWzUUiLuE
Subject: Re: Supplying DOC string in a `defun' using `defvar'
Date: Mon, 31 May 2021 16:11:27 -0700

On 2021-06-01 at 01:00:05 +0200,
ludvig-faddeev@gmx.com wrote:

> Can the DOC string in a `defun' be supplied using a `defvar'?

I don't know, but you can supply a value to defvar from the doc string
of a function:

    (defun some-function ()
      "hello, world"
      t)

    (defvar *some-variable*
      (documentation (symbol-function 'some-function)))

    *some-variable*



reply via email to

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