diff options
| author | Paul Eggert | 2011-06-23 00:37:31 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-06-23 00:37:31 -0700 |
| commit | 7efb4e0e62ed3e11e20d15821342c322b4101ae7 (patch) | |
| tree | 5959727f87d23f06389a138ed5dcb555d4eefbff | |
| parent | ff5844ad0bc84ea05e1f57827a040a31f54b8a9c (diff) | |
| parent | 4e3232657c0fe231e594fb75bea2daee2388b978 (diff) | |
| download | emacs-7efb4e0e62ed3e11e20d15821342c322b4101ae7.tar.gz emacs-7efb4e0e62ed3e11e20d15821342c322b4101ae7.zip | |
Merge from trunk.
| -rw-r--r-- | lisp/ChangeLog | 13 | ||||
| -rw-r--r-- | lisp/erc/ChangeLog | 9 | ||||
| -rw-r--r-- | lisp/erc/erc.el | 39 | ||||
| -rw-r--r-- | lisp/gnus/ChangeLog | 7 | ||||
| -rw-r--r-- | lisp/gnus/nnimap.el | 6 | ||||
| -rw-r--r-- | lisp/mail/rmailmm.el | 12 | ||||
| -rw-r--r-- | lisp/mail/sendmail.el | 14 | ||||
| -rw-r--r-- | lisp/minibuffer.el | 35 | ||||
| -rw-r--r-- | src/ChangeLog | 11 | ||||
| -rw-r--r-- | src/minibuf.c | 81 |
10 files changed, 98 insertions, 129 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 66336413e27..b29a5989791 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,16 @@ | |||
| 1 | 2011-06-22 Leo Liu <sdl.web@gmail.com> | ||
| 2 | |||
| 3 | * minibuffer.el (completing-read-function) | ||
| 4 | (completing-read-default): Move from minibuf.c | ||
| 5 | |||
| 6 | 2011-06-22 Richard Stallman <rms@gnu.org> | ||
| 7 | |||
| 8 | * mail/sendmail.el (mail-bury): If Rmail is in use, return nicely | ||
| 9 | to Rmail even if not started by a special Rmail command. | ||
| 10 | |||
| 11 | * mail/rmailmm.el (rmail-insert-mime-forwarded-message): | ||
| 12 | Copy the buffer currently showing just one message. | ||
| 13 | |||
| 1 | 2011-06-22 Roland Winkler <winkler@gnu.org> | 14 | 2011-06-22 Roland Winkler <winkler@gnu.org> |
| 2 | 15 | ||
| 3 | * textmodes/bibtex.el (bibtex-entry-update): Use mapc. | 16 | * textmodes/bibtex.el (bibtex-entry-update): Use mapc. |
diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index f1c0b2d1c65..3d9b0c8646f 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog | |||
| @@ -1,3 +1,12 @@ | |||
| 1 | 2011-06-23 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 2 | |||
| 3 | * erc.el (erc-ssl): Made into a synonym for erc-tls, which | ||
| 4 | provides a superset of the same functionality. | ||
| 5 | (erc-open-ssl-stream): Removed. | ||
| 6 | (erc-open-tls-stream): Use `open-network-stream' instead of | ||
| 7 | `open-tls-stream' directly to be able to use the built-in TLS | ||
| 8 | support. | ||
| 9 | |||
| 1 | 2011-05-28 Stefan Monnier <monnier@iro.umontreal.ca> | 10 | 2011-05-28 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 11 | ||
| 3 | * erc-pcomplete.el (erc-pcompletions-at-point): Mark the completion | 12 | * erc-pcomplete.el (erc-pcompletions-at-point): Mark the completion |
diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index a8c592696ad..36097cf0c12 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el | |||
| @@ -2164,34 +2164,7 @@ be invoked for the values of the other parameters." | |||
| 2164 | 2164 | ||
| 2165 | ;;;###autoload | 2165 | ;;;###autoload |
| 2166 | (defalias 'erc-select 'erc) | 2166 | (defalias 'erc-select 'erc) |
| 2167 | 2167 | (defalias 'erc-ssl 'erc-tls) | |
| 2168 | (defun erc-ssl (&rest r) | ||
| 2169 | "Interactively select SSL connection parameters and run ERC. | ||
| 2170 | Arguments are the same as for `erc'." | ||
| 2171 | (interactive (erc-select-read-args)) | ||
| 2172 | (let ((erc-server-connect-function 'erc-open-ssl-stream)) | ||
| 2173 | (apply 'erc r))) | ||
| 2174 | |||
| 2175 | (defalias 'erc-select-ssl 'erc-ssl) | ||
| 2176 | |||
| 2177 | (declare-function open-ssl-stream "ext:ssl" (name buffer host service)) | ||
| 2178 | |||
| 2179 | (defun erc-open-ssl-stream (name buffer host port) | ||
| 2180 | "Open an SSL stream to an IRC server. | ||
| 2181 | The process will be given the name NAME, its target buffer will be | ||
| 2182 | BUFFER. HOST and PORT specify the connection target." | ||
| 2183 | (when (condition-case nil | ||
| 2184 | (require 'ssl) | ||
| 2185 | (error (message "You don't have ssl.el. %s" | ||
| 2186 | "Try using `erc-tls' instead.") | ||
| 2187 | nil)) | ||
| 2188 | (let ((proc (open-ssl-stream name buffer host port))) | ||
| 2189 | ;; Ugly hack, but it works for now. Problem is it is | ||
| 2190 | ;; very hard to detect when ssl is established, because s_client | ||
| 2191 | ;; doesn't give any CONNECTIONESTABLISHED kind of message, and | ||
| 2192 | ;; most IRC servers send nothing and wait for you to identify. | ||
| 2193 | (sit-for 5) | ||
| 2194 | proc))) | ||
| 2195 | 2168 | ||
| 2196 | (defun erc-tls (&rest r) | 2169 | (defun erc-tls (&rest r) |
| 2197 | "Interactively select TLS connection parameters and run ERC. | 2170 | "Interactively select TLS connection parameters and run ERC. |
| @@ -2200,18 +2173,12 @@ Arguments are the same as for `erc'." | |||
| 2200 | (let ((erc-server-connect-function 'erc-open-tls-stream)) | 2173 | (let ((erc-server-connect-function 'erc-open-tls-stream)) |
| 2201 | (apply 'erc r))) | 2174 | (apply 'erc r))) |
| 2202 | 2175 | ||
| 2203 | (declare-function open-tls-stream "tls" (name buffer host port)) | ||
| 2204 | |||
| 2205 | (defun erc-open-tls-stream (name buffer host port) | 2176 | (defun erc-open-tls-stream (name buffer host port) |
| 2206 | "Open an TLS stream to an IRC server. | 2177 | "Open an TLS stream to an IRC server. |
| 2207 | The process will be given the name NAME, its target buffer will be | 2178 | The process will be given the name NAME, its target buffer will be |
| 2208 | BUFFER. HOST and PORT specify the connection target." | 2179 | BUFFER. HOST and PORT specify the connection target." |
| 2209 | (when (condition-case nil | 2180 | (open-network-stream name buffer host port |
| 2210 | (require 'tls) | 2181 | :type 'tls)) |
| 2211 | (error (message "You don't have tls.el. %s" | ||
| 2212 | "Try using `erc-ssl' instead.") | ||
| 2213 | nil)) | ||
| 2214 | (open-tls-stream name buffer host port))) | ||
| 2215 | 2182 | ||
| 2216 | ;;; Displaying error messages | 2183 | ;;; Displaying error messages |
| 2217 | 2184 | ||
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 5a6ad584438..f0b8c205c9e 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2011-06-22 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 2 | |||
| 3 | * auth-source.el (auth-source-netrc-create): Don't query the bits that | ||
| 4 | we already know. | ||
| 5 | (auth-source-forget-all-cached): Clear auth-source-netrc-cache, too. | ||
| 6 | (auth-source-netrc-create): Don't prompt for the stuff we already know. | ||
| 7 | |||
| 1 | 2011-06-21 Lars Magne Ingebrigtsen <larsi@gnus.org> | 8 | 2011-06-21 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 2 | 9 | ||
| 3 | * auth-source.el (auth-source-netrc-create): Don't print all tokens in | 10 | * auth-source.el (auth-source-netrc-create): Don't print all tokens in |
diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el index 1bbd76f345e..2cfc88987f6 100644 --- a/lisp/gnus/nnimap.el +++ b/lisp/gnus/nnimap.el | |||
| @@ -420,9 +420,9 @@ textual parts.") | |||
| 420 | (nnimap-login (car credentials) (cadr credentials)))) | 420 | (nnimap-login (car credentials) (cadr credentials)))) |
| 421 | (if (car login-result) | 421 | (if (car login-result) |
| 422 | (progn | 422 | (progn |
| 423 | ;; Save the credentials if a save function exists | 423 | ;; Save the credentials if a save function exists |
| 424 | ;; (such a function will only be passed if a new | 424 | ;; (such a function will only be passed if a new |
| 425 | ;; token was created). | 425 | ;; token was created). |
| 426 | (when (functionp (nth 2 credentials)) | 426 | (when (functionp (nth 2 credentials)) |
| 427 | (funcall (nth 2 credentials))) | 427 | (funcall (nth 2 credentials))) |
| 428 | ;; See if CAPABILITY is set as part of login | 428 | ;; See if CAPABILITY is set as part of login |
diff --git a/lisp/mail/rmailmm.el b/lisp/mail/rmailmm.el index 96132739b20..a02d388a6f7 100644 --- a/lisp/mail/rmailmm.el +++ b/lisp/mail/rmailmm.el | |||
| @@ -1333,12 +1333,16 @@ attachments as specfied by `rmail-mime-attachment-dirs-alist'." | |||
| 1333 | (setq rmail-show-mime-function 'rmail-show-mime) | 1333 | (setq rmail-show-mime-function 'rmail-show-mime) |
| 1334 | 1334 | ||
| 1335 | (defun rmail-insert-mime-forwarded-message (forward-buffer) | 1335 | (defun rmail-insert-mime-forwarded-message (forward-buffer) |
| 1336 | "Function to set in `rmail-insert-mime-forwarded-message-function' (which see)." | 1336 | "Insert the message in FORWARD-BUFFER as a forwarded message. |
| 1337 | (let ((rmail-mime-mbox-buffer | 1337 | This is the usual value of `rmail-insert-mime-forwarded-message-function'." |
| 1338 | (with-current-buffer forward-buffer rmail-view-buffer))) | 1338 | (let ((message-buffer |
| 1339 | (with-current-buffer forward-buffer | ||
| 1340 | (if rmail-buffer-swapped | ||
| 1341 | forward-buffer | ||
| 1342 | rmail-view-buffer)))) | ||
| 1339 | (save-restriction | 1343 | (save-restriction |
| 1340 | (narrow-to-region (point) (point)) | 1344 | (narrow-to-region (point) (point)) |
| 1341 | (message-forward-make-body-mime rmail-mime-mbox-buffer)))) | 1345 | (message-forward-make-body-mime message-buffer)))) |
| 1342 | 1346 | ||
| 1343 | (setq rmail-insert-mime-forwarded-message-function | 1347 | (setq rmail-insert-mime-forwarded-message-function |
| 1344 | 'rmail-insert-mime-forwarded-message) | 1348 | 'rmail-insert-mime-forwarded-message) |
diff --git a/lisp/mail/sendmail.el b/lisp/mail/sendmail.el index f4ef9b91903..c1405ec5ff3 100644 --- a/lisp/mail/sendmail.el +++ b/lisp/mail/sendmail.el | |||
| @@ -806,10 +806,18 @@ Prefix arg means don't delete this window." | |||
| 806 | 806 | ||
| 807 | (defun mail-bury (&optional arg) | 807 | (defun mail-bury (&optional arg) |
| 808 | "Bury this mail buffer." | 808 | "Bury this mail buffer." |
| 809 | (let ((newbuf (other-buffer (current-buffer)))) | 809 | (let ((newbuf (other-buffer (current-buffer))) |
| 810 | (return-action mail-return-action) | ||
| 811 | some-rmail) | ||
| 810 | (bury-buffer (current-buffer)) | 812 | (bury-buffer (current-buffer)) |
| 811 | (if (and (null arg) mail-return-action) | 813 | ;; If there is an Rmail buffer, return to it nicely |
| 812 | (apply (car mail-return-action) (cdr mail-return-action)) | 814 | ;; even if this message was not started by an Rmail command. |
| 815 | (unless return-action | ||
| 816 | (dolist (buffer (buffer-list)) | ||
| 817 | (if (eq (buffer-local-value 'major-mode buffer) 'rmail-mode) | ||
| 818 | (setq return-action `(rmail-mail-return ,newbuf))))) | ||
| 819 | (if (and (null arg) return-action) | ||
| 820 | (apply (car return-action) (cdr return-action)) | ||
| 813 | (switch-to-buffer newbuf)))) | 821 | (switch-to-buffer newbuf)))) |
| 814 | 822 | ||
| 815 | (defcustom mail-send-hook nil | 823 | (defcustom mail-send-hook nil |
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index a7ffc8d061a..32ddfe99707 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el | |||
| @@ -2710,7 +2710,40 @@ filter out additional entries (because TABLE migth not obey PRED)." | |||
| 2710 | (let ((newstr (completion-initials-expand string table pred))) | 2710 | (let ((newstr (completion-initials-expand string table pred))) |
| 2711 | (when newstr | 2711 | (when newstr |
| 2712 | (completion-pcm-try-completion newstr table pred (length newstr))))) | 2712 | (completion-pcm-try-completion newstr table pred (length newstr))))) |
| 2713 | 2713 | ||
| 2714 | (defvar completing-read-function 'completing-read-default | ||
| 2715 | "The function called by `completing-read' to do its work. | ||
| 2716 | It should accept the same arguments as `completing-read'.") | ||
| 2717 | |||
| 2718 | (defun completing-read-default (prompt collection &optional predicate | ||
| 2719 | require-match initial-input | ||
| 2720 | hist def inherit-input-method) | ||
| 2721 | "Default method for reading from the minibuffer with completion. | ||
| 2722 | See `completing-read' for the meaning of the arguments." | ||
| 2723 | |||
| 2724 | (when (consp initial-input) | ||
| 2725 | (setq initial-input | ||
| 2726 | (cons (car initial-input) | ||
| 2727 | ;; `completing-read' uses 0-based index while | ||
| 2728 | ;; `read-from-minibuffer' uses 1-based index. | ||
| 2729 | (1+ (cdr initial-input))))) | ||
| 2730 | |||
| 2731 | (let* ((minibuffer-completion-table collection) | ||
| 2732 | (minibuffer-completion-predicate predicate) | ||
| 2733 | (minibuffer-completion-confirm (unless (eq require-match t) | ||
| 2734 | require-match)) | ||
| 2735 | (keymap (if require-match | ||
| 2736 | (if (memq minibuffer-completing-file-name '(nil lambda)) | ||
| 2737 | minibuffer-local-must-match-map | ||
| 2738 | minibuffer-local-filename-must-match-map) | ||
| 2739 | (if (memq minibuffer-completing-file-name '(nil lambda)) | ||
| 2740 | minibuffer-local-completion-map | ||
| 2741 | minibuffer-local-filename-completion-map))) | ||
| 2742 | (result (read-from-minibuffer prompt initial-input keymap | ||
| 2743 | nil hist def inherit-input-method))) | ||
| 2744 | (when (and (equal result "") def) | ||
| 2745 | (setq result (if (consp def) (car def) def))) | ||
| 2746 | result)) | ||
| 2714 | 2747 | ||
| 2715 | ;; Miscellaneous | 2748 | ;; Miscellaneous |
| 2716 | 2749 | ||
diff --git a/src/ChangeLog b/src/ChangeLog index 7948766690f..1a26efbd34f 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,7 @@ | |||
| 1 | 2011-06-23 Paul Eggert <eggert@cs.ucla.edu> | 1 | 2011-06-23 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 2 | ||
| 3 | Integer and buffer overflow fixes (Bug#8873). | ||
| 4 | |||
| 3 | * print.c (printchar, strout): Check for string overflow. | 5 | * print.c (printchar, strout): Check for string overflow. |
| 4 | (PRINTPREPARE, printchar, strout): | 6 | (PRINTPREPARE, printchar, strout): |
| 5 | Don't set size unless allocation succeeds. | 7 | Don't set size unless allocation succeeds. |
| @@ -33,8 +35,6 @@ | |||
| 33 | 35 | ||
| 34 | * image.c (cache_image): Check for size arithmetic overflow. | 36 | * image.c (cache_image): Check for size arithmetic overflow. |
| 35 | 37 | ||
| 36 | 2011-06-22 Paul Eggert <eggert@cs.ucla.edu> | ||
| 37 | |||
| 38 | * lread.c: Integer overflow issues. | 38 | * lread.c: Integer overflow issues. |
| 39 | (saved_doc_string_size, saved_doc_string_length) | 39 | (saved_doc_string_size, saved_doc_string_length) |
| 40 | (prev_saved_doc_string_size, prev_saved_doc_string_length): | 40 | (prev_saved_doc_string_size, prev_saved_doc_string_length): |
| @@ -44,6 +44,13 @@ | |||
| 44 | (read_list): Don't assume file position fits in int. | 44 | (read_list): Don't assume file position fits in int. |
| 45 | (read_escape): Check for hex character overflow. | 45 | (read_escape): Check for hex character overflow. |
| 46 | 46 | ||
| 47 | 2011-06-22 Leo Liu <sdl.web@gmail.com> | ||
| 48 | |||
| 49 | * minibuf.c (Fcompleting_read_default, Vcompleting_read_function): | ||
| 50 | Move to minibuffer.el. | ||
| 51 | |||
| 52 | 2011-06-22 Paul Eggert <eggert@cs.ucla.edu> | ||
| 53 | |||
| 47 | Fixes for GLYPH_DEBUG found by GCC 4.6.0 static checking. | 54 | Fixes for GLYPH_DEBUG found by GCC 4.6.0 static checking. |
| 48 | The following patches are for when GLYPH_DEBUG && !XASSERT. | 55 | The following patches are for when GLYPH_DEBUG && !XASSERT. |
| 49 | * dispextern.h (trace_redisplay_p, dump_glyph_string): | 56 | * dispextern.h (trace_redisplay_p, dump_glyph_string): |
diff --git a/src/minibuf.c b/src/minibuf.c index 2b5e94ad356..576bca43068 100644 --- a/src/minibuf.c +++ b/src/minibuf.c | |||
| @@ -72,7 +72,6 @@ Lisp_Object Qcompletion_ignore_case; | |||
| 72 | static Lisp_Object Qminibuffer_completion_table; | 72 | static Lisp_Object Qminibuffer_completion_table; |
| 73 | static Lisp_Object Qminibuffer_completion_predicate; | 73 | static Lisp_Object Qminibuffer_completion_predicate; |
| 74 | static Lisp_Object Qminibuffer_completion_confirm; | 74 | static Lisp_Object Qminibuffer_completion_confirm; |
| 75 | static Lisp_Object Qcompleting_read_default; | ||
| 76 | static Lisp_Object Quser_variable_p; | 75 | static Lisp_Object Quser_variable_p; |
| 77 | 76 | ||
| 78 | static Lisp_Object Qminibuffer_default; | 77 | static Lisp_Object Qminibuffer_default; |
| @@ -1692,7 +1691,7 @@ See also `completing-read-function'. */) | |||
| 1692 | (Lisp_Object prompt, Lisp_Object collection, Lisp_Object predicate, Lisp_Object require_match, Lisp_Object initial_input, Lisp_Object hist, Lisp_Object def, Lisp_Object inherit_input_method) | 1691 | (Lisp_Object prompt, Lisp_Object collection, Lisp_Object predicate, Lisp_Object require_match, Lisp_Object initial_input, Lisp_Object hist, Lisp_Object def, Lisp_Object inherit_input_method) |
| 1693 | { | 1692 | { |
| 1694 | Lisp_Object args[9]; | 1693 | Lisp_Object args[9]; |
| 1695 | args[0] = Vcompleting_read_function; | 1694 | args[0] = Fsymbol_value (intern ("completing-read-function")); |
| 1696 | args[1] = prompt; | 1695 | args[1] = prompt; |
| 1697 | args[2] = collection; | 1696 | args[2] = collection; |
| 1698 | args[3] = predicate; | 1697 | args[3] = predicate; |
| @@ -1703,76 +1702,6 @@ See also `completing-read-function'. */) | |||
| 1703 | args[8] = inherit_input_method; | 1702 | args[8] = inherit_input_method; |
| 1704 | return Ffuncall (9, args); | 1703 | return Ffuncall (9, args); |
| 1705 | } | 1704 | } |
| 1706 | |||
| 1707 | DEFUN ("completing-read-default", Fcompleting_read_default, Scompleting_read_default, 2, 8, 0, | ||
| 1708 | doc: /* Default method for reading from the minibuffer with completion. | ||
| 1709 | See `completing-read' for the meaning of the arguments. */) | ||
| 1710 | (Lisp_Object prompt, Lisp_Object collection, Lisp_Object predicate, Lisp_Object require_match, Lisp_Object initial_input, Lisp_Object hist, Lisp_Object def, Lisp_Object inherit_input_method) | ||
| 1711 | { | ||
| 1712 | Lisp_Object val, histvar, histpos, position; | ||
| 1713 | Lisp_Object init; | ||
| 1714 | int pos = 0; | ||
| 1715 | int count = SPECPDL_INDEX (); | ||
| 1716 | struct gcpro gcpro1; | ||
| 1717 | |||
| 1718 | init = initial_input; | ||
| 1719 | GCPRO1 (def); | ||
| 1720 | |||
| 1721 | specbind (Qminibuffer_completion_table, collection); | ||
| 1722 | specbind (Qminibuffer_completion_predicate, predicate); | ||
| 1723 | specbind (Qminibuffer_completion_confirm, | ||
| 1724 | EQ (require_match, Qt) ? Qnil : require_match); | ||
| 1725 | |||
| 1726 | position = Qnil; | ||
| 1727 | if (!NILP (init)) | ||
| 1728 | { | ||
| 1729 | if (CONSP (init)) | ||
| 1730 | { | ||
| 1731 | position = Fcdr (init); | ||
| 1732 | init = Fcar (init); | ||
| 1733 | } | ||
| 1734 | CHECK_STRING (init); | ||
| 1735 | if (!NILP (position)) | ||
| 1736 | { | ||
| 1737 | CHECK_NUMBER (position); | ||
| 1738 | /* Convert to distance from end of input. */ | ||
| 1739 | pos = XINT (position) - SCHARS (init); | ||
| 1740 | } | ||
| 1741 | } | ||
| 1742 | |||
| 1743 | if (SYMBOLP (hist)) | ||
| 1744 | { | ||
| 1745 | histvar = hist; | ||
| 1746 | histpos = Qnil; | ||
| 1747 | } | ||
| 1748 | else | ||
| 1749 | { | ||
| 1750 | histvar = Fcar_safe (hist); | ||
| 1751 | histpos = Fcdr_safe (hist); | ||
| 1752 | } | ||
| 1753 | if (NILP (histvar)) | ||
| 1754 | histvar = Qminibuffer_history; | ||
| 1755 | if (NILP (histpos)) | ||
| 1756 | XSETFASTINT (histpos, 0); | ||
| 1757 | |||
| 1758 | val = read_minibuf (NILP (require_match) | ||
| 1759 | ? (NILP (Vminibuffer_completing_file_name) | ||
| 1760 | || EQ (Vminibuffer_completing_file_name, Qlambda) | ||
| 1761 | ? Vminibuffer_local_completion_map | ||
| 1762 | : Vminibuffer_local_filename_completion_map) | ||
| 1763 | : (NILP (Vminibuffer_completing_file_name) | ||
| 1764 | || EQ (Vminibuffer_completing_file_name, Qlambda) | ||
| 1765 | ? Vminibuffer_local_must_match_map | ||
| 1766 | : Vminibuffer_local_filename_must_match_map), | ||
| 1767 | init, prompt, make_number (pos), 0, | ||
| 1768 | histvar, histpos, def, 0, | ||
| 1769 | !NILP (inherit_input_method)); | ||
| 1770 | |||
| 1771 | if (STRINGP (val) && SCHARS (val) == 0 && ! NILP (def)) | ||
| 1772 | val = CONSP (def) ? XCAR (def) : def; | ||
| 1773 | |||
| 1774 | RETURN_UNGCPRO (unbind_to (count, val)); | ||
| 1775 | } | ||
| 1776 | 1705 | ||
| 1777 | Lisp_Object Fassoc_string (register Lisp_Object key, Lisp_Object list, Lisp_Object case_fold); | 1706 | Lisp_Object Fassoc_string (register Lisp_Object key, Lisp_Object list, Lisp_Object case_fold); |
| 1778 | 1707 | ||
| @@ -2011,7 +1940,6 @@ syms_of_minibuf (void) | |||
| 2011 | minibuf_save_list = Qnil; | 1940 | minibuf_save_list = Qnil; |
| 2012 | staticpro (&minibuf_save_list); | 1941 | staticpro (&minibuf_save_list); |
| 2013 | 1942 | ||
| 2014 | DEFSYM (Qcompleting_read_default, "completing-read-default"); | ||
| 2015 | DEFSYM (Qcompletion_ignore_case, "completion-ignore-case"); | 1943 | DEFSYM (Qcompletion_ignore_case, "completion-ignore-case"); |
| 2016 | DEFSYM (Qread_file_name_internal, "read-file-name-internal"); | 1944 | DEFSYM (Qread_file_name_internal, "read-file-name-internal"); |
| 2017 | DEFSYM (Qminibuffer_default, "minibuffer-default"); | 1945 | DEFSYM (Qminibuffer_default, "minibuffer-default"); |
| @@ -2130,12 +2058,6 @@ If the value is `confirm-after-completion', the user may exit with an | |||
| 2130 | doc: /* Non-nil means completing file names. */); | 2058 | doc: /* Non-nil means completing file names. */); |
| 2131 | Vminibuffer_completing_file_name = Qnil; | 2059 | Vminibuffer_completing_file_name = Qnil; |
| 2132 | 2060 | ||
| 2133 | DEFVAR_LISP ("completing-read-function", | ||
| 2134 | Vcompleting_read_function, | ||
| 2135 | doc: /* The function called by `completing-read' to do the work. | ||
| 2136 | It should accept the same arguments as `completing-read'. */); | ||
| 2137 | Vcompleting_read_function = Qcompleting_read_default; | ||
| 2138 | |||
| 2139 | DEFVAR_LISP ("minibuffer-help-form", Vminibuffer_help_form, | 2061 | DEFVAR_LISP ("minibuffer-help-form", Vminibuffer_help_form, |
| 2140 | doc: /* Value that `help-form' takes on inside the minibuffer. */); | 2062 | doc: /* Value that `help-form' takes on inside the minibuffer. */); |
| 2141 | Vminibuffer_help_form = Qnil; | 2063 | Vminibuffer_help_form = Qnil; |
| @@ -2212,5 +2134,4 @@ properties. */); | |||
| 2212 | defsubr (&Stest_completion); | 2134 | defsubr (&Stest_completion); |
| 2213 | defsubr (&Sassoc_string); | 2135 | defsubr (&Sassoc_string); |
| 2214 | defsubr (&Scompleting_read); | 2136 | defsubr (&Scompleting_read); |
| 2215 | defsubr (&Scompleting_read_default); | ||
| 2216 | } | 2137 | } |