diff options
author | Roland McGrath <roland@gnu.org> | 1991-09-26 06:39:56 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1991-09-26 06:39:56 +0000 |
commit | ef0ba3e3f0b745345d786d57854f8fda66c57a8f (patch) | |
tree | c1d3a8f96a383f0424df6b83e9c4c268f8f203e7 /lisp/map-ynp.el | |
parent | ca8dd5468e90b0dad7a1d4fd0bf9da828e9d1149 (diff) | |
download | emacs-ef0ba3e3f0b745345d786d57854f8fda66c57a8f.tar.gz |
*** empty log message ***
Diffstat (limited to 'lisp/map-ynp.el')
-rw-r--r-- | lisp/map-ynp.el | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/lisp/map-ynp.el b/lisp/map-ynp.el index 0d78ee69196..db345d66ef8 100644 --- a/lisp/map-ynp.el +++ b/lisp/map-ynp.el @@ -69,23 +69,25 @@ Returns the number of actions taken." (actions 0) prompt char + elt (next (if (or (symbolp list) (subrp list) (compiled-function-p list) (and (consp list) (eq (car list) 'lambda))) - list + (function (lambda () + (setq elt (funcall list)))) (function (lambda () (if list - (prog1 - (car list) - (setq list (cdr list))) - nil))))) - elt) + (progn + (setq elt (car list) + list (cdr list)) + t) + nil)))))) (if (stringp prompter) (setq prompter (` (lambda (object) (format (, prompter) object))))) - (while (setq elt (funcall next)) + (while (funcall next) (setq prompt (funcall prompter elt)) (if (stringp prompt) (progn |