]> git.eshelyaron.com Git - emacs.git/commit
Avoid resizing mutation in subst-char-in-string
authorMattias EngdegÄrd <mattiase@acm.org>
Fri, 10 May 2024 08:35:39 +0000 (10:35 +0200)
committerEshel Yaron <me@eshelyaron.com>
Sun, 12 May 2024 15:48:25 +0000 (17:48 +0200)
commitbd7f6c78c1443c1c359e0ff256854341be1a49e4
tree76d0726676b2836b2c192a59e0a693215c63663c
parent1c68ff8078a1f8d6f5998f075c30c2ad6ca05898
Avoid resizing mutation in subst-char-in-string

* lisp/subr.el (subst-char-in-string):
Use string-replace to avoid resizing mutation and O(n^2) time.

(cherry picked from commit 184d6e8c02345583264b053bb59ae031bb1c5a00)
lisp/subr.el