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: Jean Louis
Subject: Re: Supplying DOC string in a `defun' using `defvar'
Date: Tue, 1 Jun 2021 19:34:50 +0300
User-agent: Mutt/2.0.7+183 (3d24855) (2021-05-28)

* Michael Heerdegen <michael_heerdegen@web.de> [2021-06-01 17:32]:
> Christopher Dimech <dimech@gmx.com> writes:
> 
> > > Try:
> > >
> > >     (defvar my-doc "foobar")
> > >     (defun (x)
> > >       (:documentation my-doc)
> > >       (+ x 42))
> >
> > Have tried this but emacs is still saying "Not documented."
> 
> Stefan typed too quickly, he forgot the function name in the defun - so
> it probably should be
> 

(defun my-fun (x)
  (:documentation my-doc)
  (+ x 42))

That does not work.


-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

Sign an open letter in support of Richard M. Stallman
https://stallmansupport.org/



reply via email to

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