* Documentation of `file-name-completion' is somewhat confusing
@ 2013-06-12 2:07 Xue Fuqiao
2013-06-12 2:58 ` Eli Zaretskii
0 siblings, 1 reply; 3+ messages in thread
From: Xue Fuqiao @ 2013-06-12 2:07 UTC (permalink / raw)
To: emacs-devel
Hi list,
In (info "(elisp) File Name Completion"):
-- Function: file-name-completion filename directory &optional
predicate
[...]
If PREDICATE is non-`nil' then it ignores possible completions that
don't satisfy PREDICATE, after calling that function with one
argument, the expanded absolute file name.
And in the doc string of this function:
If PREDICATE is non-nil, call PREDICATE with each possible
completion (in absolute form) and ignore it if PREDICATE returns
nil.
It seems to me that the arguments of PREDICATE described by these two
paragraphs don't agree with each other: the first one is "the expanded
absolute file name", but the second one is "each possible completion".
IMHO the latter is more appropriate. Or maybe I got something wrong.
Any ideas?
--
Best regards, Xue Fuqiao.
http://www.gnu.org/software/emacs/
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Documentation of `file-name-completion' is somewhat confusing
2013-06-12 2:07 Documentation of `file-name-completion' is somewhat confusing Xue Fuqiao
@ 2013-06-12 2:58 ` Eli Zaretskii
2013-06-12 13:39 ` Xue Fuqiao
0 siblings, 1 reply; 3+ messages in thread
From: Eli Zaretskii @ 2013-06-12 2:58 UTC (permalink / raw)
To: Xue Fuqiao; +Cc: emacs-devel
> Date: Wed, 12 Jun 2013 10:07:37 +0800
> From: Xue Fuqiao <xfq.free@gmail.com>
>
> In (info "(elisp) File Name Completion"):
> -- Function: file-name-completion filename directory &optional
> predicate
> [...]
> If PREDICATE is non-`nil' then it ignores possible completions that
> don't satisfy PREDICATE, after calling that function with one
> argument, the expanded absolute file name.
>
> And in the doc string of this function:
> If PREDICATE is non-nil, call PREDICATE with each possible
> completion (in absolute form) and ignore it if PREDICATE returns
> nil.
>
> It seems to me that the arguments of PREDICATE described by these two
> paragraphs don't agree with each other: the first one is "the expanded
> absolute file name", but the second one is "each possible completion".
> IMHO the latter is more appropriate. Or maybe I got something wrong.
> Any ideas?
Why do you think that "expanded absolute file name" of a "possible
completion" and "each possible completion (in absolute form)" are
anything but the same thing? Where exactly do you see the difference
between these two?
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Documentation of `file-name-completion' is somewhat confusing
2013-06-12 2:58 ` Eli Zaretskii
@ 2013-06-12 13:39 ` Xue Fuqiao
0 siblings, 0 replies; 3+ messages in thread
From: Xue Fuqiao @ 2013-06-12 13:39 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: emacs-devel
On Wed, Jun 12, 2013 at 10:58 AM, Eli Zaretskii <eliz@gnu.org> wrote:
>> Date: Wed, 12 Jun 2013 10:07:37 +0800
>> From: Xue Fuqiao <xfq.free@gmail.com>
>>
>> In (info "(elisp) File Name Completion"):
>> -- Function: file-name-completion filename directory &optional
>> predicate
>> [...]
>> If PREDICATE is non-`nil' then it ignores possible completions that
>> don't satisfy PREDICATE, after calling that function with one
>> argument, the expanded absolute file name.
>>
>> And in the doc string of this function:
>> If PREDICATE is non-nil, call PREDICATE with each possible
>> completion (in absolute form) and ignore it if PREDICATE returns
>> nil.
>>
>> It seems to me that the arguments of PREDICATE described by these two
>> paragraphs don't agree with each other: the first one is "the expanded
>> absolute file name", but the second one is "each possible completion".
>> IMHO the latter is more appropriate. Or maybe I got something wrong.
>> Any ideas?
>
> Why do you think that "expanded absolute file name" of a "possible
> completion" and "each possible completion (in absolute form)" are
> anything but the same thing? Where exactly do you see the difference
> between these two?
Well, I misunderstood it. I thought the "expanded absolute file name"
is for FILENAME, so the first version has only one argument: FILENAME
(in absolute form).
--
Best regards, Xue Fuqiao.
http://www.gnu.org/software/emacs/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-06-12 13:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-12 2:07 Documentation of `file-name-completion' is somewhat confusing Xue Fuqiao
2013-06-12 2:58 ` Eli Zaretskii
2013-06-12 13:39 ` Xue Fuqiao
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.