;; `M-x doctor' makes history a local variable, and thus
;; our binding above is buffer-local and doesn't apply
;; once we switch buffers!!!! We demand better scope!
- (_history_ history))
+ (_history_ history)
+ (minibuffer-default default))
(unwind-protect
(progn
(set-buffer (reset-buffer buffer))
(while (progn
(setq result (completing-read prompt alist nil require-match
nil 'buffer-history
- (if default (buffer-name default))))
+ (if (bufferp default)
+ (buffer-name default)
+ default)))
(cond ((not (equal result ""))
nil)
((not require-match)
read-file-name-map
read-file-name-must-match-map)
nil
- history))
- ))
+ history
+ nil
+ default))))
;;; ;; Kludge! Put "/foo/bar" on history rather than "/default//foo/bar"
;;; (let ((hist (cond ((not history) 'minibuffer-history)
;;; ((consp history) (car history))