1

I have an emacs function with a long docstring. Could I make the docstring separate from the function, adding it before or after the function declaration?

And is it possible to append to a docstring after the function has been defined and a short docstring had been inserted?

Have been introspecting the possibility of help-split-fundoc. How does this work?

1 Answer 1

1
(defun hello-world ()
  (message "Hello World!"))

(put 'hello-world 'function-documentation
     "Aliqua eu excepteur incididunt quis.
Ut laborum aliqua ex amet, minim.")

(put 'hello-world 'function-documentation
     (concat
      (get 'hello-world 'function-documentation)
      "

Sed in consequat do ullamco laborum pariatur consectetur
voluptate occaecat sunt consequat aute sit in ipsum velit nisi
anim consequat.  Consequat aliqua ea cupidatat commodo magna
nulla nostrud.  Nostrud sed ea non esse duis aute irure.  Est
laboris mollit ex sit adipiscing amet, sed pariatur sunt
reprehenderit non.  In commodo est veniam, non aliqua sunt
pariatur in est consectetur cillum dolore magna aliqua commodo
ullamco."))

1
  • I am having a problem with (get 'hello-world 'function-documentation), which does not seem to get me the documentation form the function definition.
    – Ephram
    Jun 29 at 13:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.