Function: tramp-subst-strs-in-string
tramp-subst-strs-in-string is a byte-compiled function defined in
tramp.el.gz.
Signature
(tramp-subst-strs-in-string ALIST STRING)
Documentation
Replace all occurrences of the string FROM with TO in STRING.
ALIST is of the form ((FROM . TO) ...).
Source Code
;; Defined in /usr/src/emacs/lisp/net/tramp.el.gz
(defun tramp-subst-strs-in-string (alist string)
"Replace all occurrences of the string FROM with TO in STRING.
ALIST is of the form ((FROM . TO) ...)."
(save-match-data
(while alist
(let* ((pr (car alist))
(from (car pr))
(to (cdr pr)))
(while (string-match (rx (literal from)) string)
(setq string (replace-match to t t string)))
(setq alist (cdr alist))))
string))