diff options
| -rw-r--r-- | lisp/simple.el | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/lisp/simple.el b/lisp/simple.el index 7f8aa1deff0..3b7913ff753 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -2979,7 +2979,15 @@ If you want VALUE to be a string, you must surround it with doublequotes. | |||
| 2979 | If VARIABLE has a `variable-interactive' property, that is used as if | 2979 | If VARIABLE has a `variable-interactive' property, that is used as if |
| 2980 | it were the arg to `interactive' (which see) to interactively read the value." | 2980 | it were the arg to `interactive' (which see) to interactively read the value." |
| 2981 | (interactive | 2981 | (interactive |
| 2982 | (let* ((var (read-variable "Set variable: ")) | 2982 | (let* ((var (let ((v (variable-at-point)) |
| 2983 | (enable-recursive-minibuffers t) | ||
| 2984 | val) | ||
| 2985 | (setq val (completing-read (if v | ||
| 2986 | (format "Set variable (default %s): " v) | ||
| 2987 | "Set variable: ") | ||
| 2988 | obarray 'boundp t)) | ||
| 2989 | (if (equal val "") | ||
| 2990 | v (intern val)))) | ||
| 2983 | (minibuffer-help-form | 2991 | (minibuffer-help-form |
| 2984 | '(funcall myhelp)) | 2992 | '(funcall myhelp)) |
| 2985 | (myhelp | 2993 | (myhelp |