GNU bug report logs -
#40202
directory-files-recursively docstring unclear about include-directories
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 40202 in the body.
You can then email your comments to 40202 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Mon, 23 Mar 2020 21:18:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Arun Isaac <arunisaac <at> systemreboot.net>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Mon, 23 Mar 2020 21:18:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi,
The docstring of directory-file-recursively in lisp/files.el is unclear
about the include-directories optional argument. It currently reads
"Optional argument INCLUDE-DIRECTORIES non-nil means also include
in the output directories whose names match REGEXP."
Perhaps this could be rewritten as
"If optional argument INCLUDE-DIRECTORIES is non-nil, the returned list
also includes directories whose names match REGEXP."
Thanks,
Arun
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Tue, 24 Mar 2020 03:26:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 40202 <at> debbugs.gnu.org (full text, mbox):
> From: Arun Isaac <arunisaac <at> systemreboot.net>
> Date: Tue, 24 Mar 2020 02:46:55 +0530
>
> The docstring of directory-file-recursively in lisp/files.el is unclear
> about the include-directories optional argument. It currently reads
>
> "Optional argument INCLUDE-DIRECTORIES non-nil means also include
> in the output directories whose names match REGEXP."
>
> Perhaps this could be rewritten as
>
> "If optional argument INCLUDE-DIRECTORIES is non-nil, the returned list
> also includes directories whose names match REGEXP."
Could you please explain which part(s) of the proposed doc string make
the issue more clear for you? To me both variants sound equivalent.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Tue, 24 Mar 2020 08:23:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 40202 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
>> The docstring of directory-file-recursively in lisp/files.el is unclear
>> about the include-directories optional argument. It currently reads
>>
>> "Optional argument INCLUDE-DIRECTORIES non-nil means also include
>> in the output directories whose names match REGEXP."
>>
>> Perhaps this could be rewritten as
>>
>> "If optional argument INCLUDE-DIRECTORIES is non-nil, the returned list
>> also includes directories whose names match REGEXP."
>
> Could you please explain which part(s) of the proposed doc string make
> the issue more clear for you? To me both variants sound equivalent.
They seem equivalent once you already know the meaning that is supposed
to be conveyed. I had to wrack my brains for a while before I understood
what that sentence means.
1. It is not immediately clear how to parse the original docstring. Is
it parsed as "(include) (in the output directories whose name matches
REGEXP)", "(include in the output directories) (whose name matches
REGEXP)" or "(include in the output) (directories whose name matches
REGEXP)"? The phrase "in the output" in between the sentence makes it
difficult to parse. Some punctuation there could have helped, but I
don't see how to do that.
2. The grammar of my proposal is better. In the original, the usage of
"means" as the predicate, "optional argument INCLUDE-DIRECTORIES
non-nil" as the subject is unusual and awkward.
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Tue, 24 Mar 2020 21:24:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 40202 <at> debbugs.gnu.org (full text, mbox):
Arun Isaac <arunisaac <at> systemreboot.net> writes:
> They seem equivalent once you already know the meaning that is supposed
> to be conveyed. I had to wrack my brains for a while before I understood
> what that sentence means.
Yes, I agree that your version is much clearer and easier to understand.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Wed, 25 Mar 2020 17:21:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 40202 <at> debbugs.gnu.org (full text, mbox):
Arun Isaac <arunisaac <at> systemreboot.net> writes:
> Hi,
>
> The docstring of directory-file-recursively in lisp/files.el is unclear
> about the include-directories optional argument. It currently reads
>
> "Optional argument INCLUDE-DIRECTORIES non-nil means also include
> in the output directories whose names match REGEXP."
>
> Perhaps this could be rewritten as
>
> "If optional argument INCLUDE-DIRECTORIES is non-nil, the returned list
> also includes directories whose names match REGEXP."
Or a more prompting style
"If INCLUDE-DIRECTORIES is non-nil, also include directories whose names
matches REGEXP in the returned list."
I think it is not necessary to repeat that the argument is optional, but
maybe that is standard.
?
Best regards
--
Tomas
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Wed, 25 Mar 2020 19:39:02 GMT)
Full text and
rfc822 format available.
Message #20 received at 40202 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
> Or a more prompting style
>
> "If INCLUDE-DIRECTORIES is non-nil, also include directories whose names
> matches REGEXP in the returned list."
I did consider this style. But, it is slightly harder to parse. For
example, it is easy to misparse the sentence as "also include
directories (whose names match REGEXP in the returned list)" when the
correct parsing should be "also include (directories whose names match
REGEXP) in the returned list".
[signature.asc (application/pgp-signature, inline)]
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Wed, 25 Mar 2020 19:58:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Arun Isaac <arunisaac <at> systemreboot.net>
:
bug acknowledged by developer.
(Wed, 25 Mar 2020 19:58:02 GMT)
Full text and
rfc822 format available.
Message #25 received at 40202-done <at> debbugs.gnu.org (full text, mbox):
> From: Arun Isaac <arunisaac <at> systemreboot.net>
> Cc: Lars Ingebrigtsen <larsi <at> gnus.org>, Eli Zaretskii <eliz <at> gnu.org>
> Date: Thu, 26 Mar 2020 01:08:20 +0530
>
> > Or a more prompting style
> >
> > "If INCLUDE-DIRECTORIES is non-nil, also include directories whose names
> > matches REGEXP in the returned list."
>
> I did consider this style. But, it is slightly harder to parse. For
> example, it is easy to misparse the sentence as "also include
> directories (whose names match REGEXP in the returned list)" when the
> correct parsing should be "also include (directories whose names match
> REGEXP) in the returned list".
IME, if some text causes parsing difficulties, it is best dropped
altogether, especially if it is redundant. So that's what I did, see
the emacs-27 branch.
And with that, I'm closing this bug. Thanks for pointing out the
ambiguity of the original text.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#40202
; Package
emacs
.
(Wed, 25 Mar 2020 21:37:01 GMT)
Full text and
rfc822 format available.
Message #28 received at 40202-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
> IME, if some text causes parsing difficulties, it is best dropped
> altogether, especially if it is redundant. So that's what I did, see
> the emacs-27 branch.
Thank you! The new docstring is very clear.
[signature.asc (application/pgp-signature, inline)]
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 23 Apr 2020 11:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 5 years and 60 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.