summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/subr-x.el
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2020-12-25 05:16:46 +0100
committerLars Ingebrigtsen <larsi@gnus.org>2020-12-25 05:16:46 +0100
commit269cec13a2fc6ac18b675d0dadd07a3d4e074a72 (patch)
tree310349de42c6185770dcd30a5d343d01fd552237 /lisp/emacs-lisp/subr-x.el
parentd63ccde966a561756675b9c84b39c724662c82a8 (diff)
downloademacs-269cec13a2fc6ac18b675d0dadd07a3d4e074a72.tar.gz
emacs-269cec13a2fc6ac18b675d0dadd07a3d4e074a72.tar.bz2
emacs-269cec13a2fc6ac18b675d0dadd07a3d4e074a72.zip
Remove `string-slice' -- it's not very well defined
* doc/lispref/strings.texi (Creating Strings): Ditto. * lisp/emacs-lisp/subr-x.el (string-slice): Remove.
Diffstat (limited to 'lisp/emacs-lisp/subr-x.el')
-rw-r--r--lisp/emacs-lisp/subr-x.el13
1 files changed, 0 insertions, 13 deletions
diff --git a/lisp/emacs-lisp/subr-x.el b/lisp/emacs-lisp/subr-x.el
index 7e17a3464e6..dc5840a0865 100644
--- a/lisp/emacs-lisp/subr-x.el
+++ b/lisp/emacs-lisp/subr-x.el
@@ -310,19 +310,6 @@ than this function."
If OMIT-NULLS, empty lines will be removed from the results."
(split-string string "\n" omit-nulls))
-(defun string-slice (string regexp)
- "Split STRING at REGEXP boundaries and return a list of slices.
-The boundaries that match REGEXP are included in the result.
-
-Also see `split-string'."
- (if (zerop (length string))
- (list "")
- (let ((i (string-match-p regexp string 1)))
- (if i
- (cons (substring string 0 i)
- (string-slice (substring string i) regexp))
- (list string)))))
-
(defun string-pad (string length &optional padding start)
"Pad STRING to LENGTH using PADDING.
If PADDING is nil, the space character is used. If not nil, it