# HG changeset patch # User Stefan Monnier # Date 1007164768 0 # Node ID d53ece895385c54b6ec74cb049be20b907ae88e3 # Parent c2b7b74ef9735030cd862b4d040d33a7f08973b1 (Info-find-node-2): Don't call info-insert-file-contents with the `visit' argument. (Info-extract-menu-node-name): Use `replace-regexps-in-string'. diff -r c2b7b74ef973 -r d53ece895385 lisp/info.el --- a/lisp/info.el Fri Nov 30 23:58:24 2001 +0000 +++ b/lisp/info.el Fri Nov 30 23:59:28 2001 +0000 @@ -609,7 +609,7 @@ (erase-buffer) (if (eq filename t) (Info-insert-dir) - (info-insert-file-contents filename t) + (info-insert-file-contents filename nil) (setq default-directory (file-name-directory filename))) (set-buffer-modified-p nil) ;; See whether file has a tag table. Record the location if yes. @@ -1393,12 +1393,7 @@ (buffer-substring-no-properties beg (1- (point))) (skip-chars-forward " \t\n") (Info-following-node-name (if multi-line "^.,\t" "^.,\t\n")))) - (while (setq i (string-match "\n" str i)) - (aset str i ?\ )) - ;; Collapse multiple spaces. - (while (string-match " +" str) - (setq str (replace-match " " t t str))) - str)) + (replace-regexp-in-string "[ \n]+" " " str))) ;; No one calls this. ;;(defun Info-menu-item-sequence (list)