Commit 2cbaf886 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(Fall_completions): Allow completions that start with space

if the input starts with space.
parent 98fb23e2
......@@ -824,11 +824,14 @@ The argument given to PREDICATE is the alist element or the symbol from the obar
/* Is this element a possible completion? */
if (XTYPE (eltstring) == Lisp_String &&
XSTRING (string)->size <= XSTRING (eltstring)->size &&
XSTRING (eltstring)->data[0] != ' ' &&
0 > scmp (XSTRING (eltstring)->data, XSTRING (string)->data,
XSTRING (string)->size))
if (XTYPE (eltstring) == Lisp_String
&& XSTRING (string)->size <= XSTRING (eltstring)->size
/* Reject alternatives that start with space
unless the input starts with space. */
&& ((XSTRING (string)->size > 0 && XSTRING (string)->data[0] == ' ')
|| XSTRING (eltstring)->data[0] != ' ')
&& 0 > scmp (XSTRING (eltstring)->data, XSTRING (string)->data,
XSTRING (string)->size))
{
/* Yes. */
/* Ignore this element if there is a predicate
......
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