projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7e86d3b
)
Tiny string-clean-whitespace simplification
author
Basil L. Contovounesios
<contovob@tcd.ie>
Mon, 21 Dec 2020 22:34:33 +0000
(22:34 +0000)
committer
Basil L. Contovounesios
<contovob@tcd.ie>
Mon, 21 Dec 2020 22:36:55 +0000
(22:36 +0000)
* lisp/emacs-lisp/subr-x.el (string-clean-whitespace): Streamline by
treating replacement string as being literal and having fixed case.
lisp/emacs-lisp/subr-x.el
patch
|
blob
|
history
diff --git
a/lisp/emacs-lisp/subr-x.el
b/lisp/emacs-lisp/subr-x.el
index 1c8e1d6293f391a3c1b82115e67419cd49978c5a..aa39fc1538fbea23a753956c332d46fc352aa8ae 100644
(file)
--- a/
lisp/emacs-lisp/subr-x.el
+++ b/
lisp/emacs-lisp/subr-x.el
@@
-270,7
+270,7
@@
All sequences of whitespaces in STRING are collapsed into a
single space character, and leading/trailing whitespace is
removed."
(let ((blank "[[:blank:]\n]+"))
- (string-trim (replace-regexp-in-string blank " " string)
+ (string-trim (replace-regexp-in-string blank " " string
t t
)
blank blank)))
(defun string-fill (string length)