Rename slice-string to string-slice
* lisp/emacs-lisp/subr-x.el (string-slice): Rename from slice-string. * doc/lispref/strings.texi (Creating Strings): Ditto.
This commit is contained in:
parent
b3dec31766
commit
cf2e832185
5 changed files with 12 additions and 12 deletions
|
@ -151,9 +151,9 @@ There can be any number of :example/:result elements."
|
|||
:eval (split-string "foo bar")
|
||||
:eval (split-string "|foo|bar|" "|")
|
||||
:eval (split-string "|foo|bar|" "|" t))
|
||||
(slice-string
|
||||
:eval (slice-string "foo-bar" "-")
|
||||
:eval (slice-string "foo-bar--zot-" "-+"))
|
||||
(string-slice
|
||||
:eval (string-slice "foo-bar" "-")
|
||||
:eval (string-slice "foo-bar--zot-" "-+"))
|
||||
(string-lines
|
||||
:eval (string-lines "foo\n\nbar")
|
||||
:eval (string-lines "foo\n\nbar" t))
|
||||
|
|
|
@ -301,7 +301,7 @@ a substring consisitng of thelast LENGTH characters of STRING."
|
|||
If OMIT-NULLS, empty lines will be removed from the results."
|
||||
(split-string string "\n" omit-nulls))
|
||||
|
||||
(defun slice-string (string regexp)
|
||||
(defun string-slice (string regexp)
|
||||
"Split STRING at REGEXP boundaries and return a list of slices.
|
||||
The boundaries that match REGEXP are not omitted from the results."
|
||||
(let ((start-substring 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue