Commit a1f03e89 authored by Leo Liu's avatar Leo Liu
Browse files

* lisp/loadhist.el (read-feature): Get rid of fake feature nil.

* src/minibuf.c (Ftry_completion, Fall_completions)
(Ftest_completion): Use FUNCTIONP.  (Bug#15889)
parent 1a191e5c
2013-11-15 Leo Liu <sdl.web@gmail.com>
* loadhist.el (read-feature): Get rid of fake feature nil. (Bug#15889)
2013-11-14 Stefan Monnier <monnier@iro.umontreal.ca> 2013-11-14 Stefan Monnier <monnier@iro.umontreal.ca>
* progmodes/gud.el (ctl-x-map): * progmodes/gud.el (ctl-x-map):
......
...@@ -101,14 +101,10 @@ A library name is equivalent to the file name that `load-library' would load." ...@@ -101,14 +101,10 @@ A library name is equivalent to the file name that `load-library' would load."
"Read feature name from the minibuffer, prompting with string PROMPT. "Read feature name from the minibuffer, prompting with string PROMPT.
If optional second arg LOADED-P is non-nil, the feature must be loaded If optional second arg LOADED-P is non-nil, the feature must be loaded
from a file." from a file."
(intern (intern (completing-read prompt
(completing-read prompt features
(cons nil features) (and loaded-p #'feature-file)
(and loaded-p loaded-p)))
#'(lambda (f)
(and f ; ignore nil
(feature-file f))))
loaded-p)))
(defvaralias 'loadhist-hook-functions 'unload-feature-special-hooks) (defvaralias 'loadhist-hook-functions 'unload-feature-special-hooks)
(defvar unload-feature-special-hooks (defvar unload-feature-special-hooks
......
2013-11-15 Leo Liu <sdl.web@gmail.com>
* minibuf.c (Ftry_completion, Fall_completions)
(Ftest_completion): Use FUNCTIONP. (Bug#15889)
2013-11-15 Paul Eggert <eggert@cs.ucla.edu> 2013-11-15 Paul Eggert <eggert@cs.ucla.edu>
* lisp.h (DEFINE_GDB_SYMBOL_BEGIN, DEFINE_GDB_SYMBOL_END): * lisp.h (DEFINE_GDB_SYMBOL_BEGIN, DEFINE_GDB_SYMBOL_END):
......
...@@ -1199,9 +1199,7 @@ is used to further constrain the set of candidates. */) ...@@ -1199,9 +1199,7 @@ is used to further constrain the set of candidates. */)
type = (HASH_TABLE_P (collection) ? hash_table type = (HASH_TABLE_P (collection) ? hash_table
: VECTORP (collection) ? obarray_table : VECTORP (collection) ? obarray_table
: ((NILP (collection) : ((NILP (collection)
|| (CONSP (collection) || (CONSP (collection) && !FUNCTIONP (collection)))
&& (!SYMBOLP (XCAR (collection))
|| NILP (XCAR (collection)))))
? list_table : function_table)); ? list_table : function_table));
ptrdiff_t idx = 0, obsize = 0; ptrdiff_t idx = 0, obsize = 0;
int matchcount = 0; int matchcount = 0;
...@@ -1460,9 +1458,7 @@ with a space are ignored unless STRING itself starts with a space. */) ...@@ -1460,9 +1458,7 @@ with a space are ignored unless STRING itself starts with a space. */)
Lisp_Object allmatches; Lisp_Object allmatches;
int type = HASH_TABLE_P (collection) ? 3 int type = HASH_TABLE_P (collection) ? 3
: VECTORP (collection) ? 2 : VECTORP (collection) ? 2
: NILP (collection) || (CONSP (collection) : NILP (collection) || (CONSP (collection) && !FUNCTIONP (collection));
&& (!SYMBOLP (XCAR (collection))
|| NILP (XCAR (collection))));
ptrdiff_t idx = 0, obsize = 0; ptrdiff_t idx = 0, obsize = 0;
ptrdiff_t bindcount = -1; ptrdiff_t bindcount = -1;
Lisp_Object bucket, tem, zero; Lisp_Object bucket, tem, zero;
...@@ -1691,9 +1687,7 @@ the values STRING, PREDICATE and `lambda'. */) ...@@ -1691,9 +1687,7 @@ the values STRING, PREDICATE and `lambda'. */)
CHECK_STRING (string); CHECK_STRING (string);
if ((CONSP (collection) if (NILP (collection) || (CONSP (collection) && !FUNCTIONP (collection)))
&& (!SYMBOLP (XCAR (collection)) || NILP (XCAR (collection))))
|| NILP (collection))
{ {
tem = Fassoc_string (string, collection, completion_ignore_case ? Qt : Qnil); tem = Fassoc_string (string, collection, completion_ignore_case ? Qt : Qnil);
if (NILP (tem)) if (NILP (tem))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment