summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/shortdoc.el
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2020-12-21 22:05:37 +0100
committerLars Ingebrigtsen <larsi@gnus.org>2020-12-21 22:05:37 +0100
commitf329a3180ead740bb85e1edfc48ae360a56f7ffd (patch)
treee5710512f8c9dbed77cbda51753c479865b77f8d /lisp/emacs-lisp/shortdoc.el
parente967ba301857edd15778a018ae716e4e98fa2fa9 (diff)
downloademacs-f329a3180ead740bb85e1edfc48ae360a56f7ffd.tar.gz
emacs-f329a3180ead740bb85e1edfc48ae360a56f7ffd.tar.bz2
emacs-f329a3180ead740bb85e1edfc48ae360a56f7ffd.zip
Add string-chop-newline
* doc/lispref/strings.texi (Creating Strings): Document it. * lisp/emacs-lisp/subr-x.el (string-chop-newline): Add new function.
Diffstat (limited to 'lisp/emacs-lisp/shortdoc.el')
-rw-r--r--lisp/emacs-lisp/shortdoc.el2
1 files changed, 2 insertions, 0 deletions
diff --git a/lisp/emacs-lisp/shortdoc.el b/lisp/emacs-lisp/shortdoc.el
index df31b0aaf1f..9bd06636f4d 100644
--- a/lisp/emacs-lisp/shortdoc.el
+++ b/lisp/emacs-lisp/shortdoc.el
@@ -181,6 +181,8 @@ There can be any number of :example/:result elements."
(string-remove-prefix
:no-manual t
:eval (string-remove-prefix "foo" "foobar"))
+ (string-chop-newline
+ :eval (string-chop-newline "foo\n"))
(string-clean-whitespace
:eval (string-clean-whitespace " foo bar "))
(string-fill