From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#35367: 26.2; `dired-copy-how-to-fn' and HOW-TO arg of `dired-create-files' Date: Sun, 21 Apr 2019 12:30:14 -0700 (PDT) Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="235831"; mail-complaints-to="usenet@blaine.gmane.org" To: 35367@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Apr 21 21:37:15 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hIIH1-000zBf-NB for geb-bug-gnu-emacs@m.gmane.org; Sun, 21 Apr 2019 21:37:11 +0200 Original-Received: from localhost ([127.0.0.1]:56386 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hIIH0-000314-N4 for geb-bug-gnu-emacs@m.gmane.org; Sun, 21 Apr 2019 15:37:10 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:54886) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hIIGu-00030f-SN for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:37:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hIIGt-0002zP-NS for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:37:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:35555) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hIIGt-0002zI-J1 for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:37:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hIIGt-00057R-Bd for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:37:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 21 Apr 2019 19:37:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 35367 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.155587537819620 (code B ref -1); Sun, 21 Apr 2019 19:37:03 +0000 Original-Received: (at submit) by debbugs.gnu.org; 21 Apr 2019 19:36:18 +0000 Original-Received: from localhost ([127.0.0.1]:49099 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hIIG9-00056O-JF for submit@debbugs.gnu.org; Sun, 21 Apr 2019 15:36:17 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:40162) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hIIG7-00056A-6n for submit@debbugs.gnu.org; Sun, 21 Apr 2019 15:36:16 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:45843) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hIIG2-0002Xm-2B for submit@debbugs.gnu.org; Sun, 21 Apr 2019 15:36:10 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:54522) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hIIG0-0002ZA-Pi for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:36:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hIICM-0000N1-8N for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:32:24 -0400 Original-Received: from userp2120.oracle.com ([156.151.31.85]:33346) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hIICL-0000LK-Vz for bug-gnu-emacs@gnu.org; Sun, 21 Apr 2019 15:32:22 -0400 Original-Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x3LJUC5H009438 for ; Sun, 21 Apr 2019 19:32:16 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : subject : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=98PNRY6rmtC6UGXoKj48A3Jodi347J2xdL3q+ze4m8o=; b=5Zast8qpnbKWwkzD8iLdP9GU5G5LTvyiVUUz7MkWCtaNxz4b1SF0VRlljywDULu4p+yN gr5pSYHLpvgl56IwSKCqXK7bQMWdXidX0HPWlMm3Bu0D73FnabU5EDfVGAeFitAp+pgM 3pM2lRIwxGRJps78Y8kzUAeeDBGXxF3h116RyG9eP6t+Hu7D+3JKlASbmn2z+TBCBKGI 0bBBMvKSppO/gBV1CPyQfnZ5knUiJnS8BrLekjeydGM6yIl3kNt8TKDhz2utfSiN5bpV zI38pidt3yDVMv9CkcOz7g/AyUQbTYHpYrDyhTth29aiKN/vuJTRviLqg5WeZO071W6C Iw== Original-Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by userp2120.oracle.com with ESMTP id 2ryv2pudf1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Sun, 21 Apr 2019 19:32:16 +0000 Original-Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x3LJSQxe033532 for ; Sun, 21 Apr 2019 19:30:15 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserp3020.oracle.com with ESMTP id 2s0fv252v3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Sun, 21 Apr 2019 19:30:15 +0000 Original-Received: from abhmp0017.oracle.com (abhmp0017.oracle.com [141.146.116.23]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x3LJUFXf018662 for ; Sun, 21 Apr 2019 19:30:15 GMT X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4834.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9234 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904210153 X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9234 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904210153 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:157961 Archived-At: 1. I believe `dired-copy-how-to-fn' was added to Emacs quite a while ago (1991[1]). But it's not clear to me what it's really for, and there seem to be no uses of it in the distributed Emacs code, apart from `dired-do-copy', which just passes it on to `dired-create-files'. The variable's doc just says to "See HOW-TO argument for `dired-create-files'." So why was this variable created? 2. Apart from the variable, why was the HOW-TO arg of `dired-do-create-files' added? I find no uses of it, apart from `dired-do-copy' (which just passes it along). Presumably someone thought that someone might want to pass such a thing to `dired-do-copy', but why? Half the doc of `dired-do-create-files' is for this parameter. And its description, although probably correct and complete, reads like gobbledygook, to me. For one thing, the nil case should not be described under this parameter; it should be described as the function's default behavior, up above the parameter list. (That's already 4 lines of its description.) Beyond that: * A value of `t' is unclear to me. What does it mean to target a plain file - is this the same as using a `nil' value? What happens with `t' if the target is a directory or if there are multiple marked files? Is that where the difference lies somehow (how)? * A unary function value is the most confusing. I can't follow it, I'm afraid. If HOW-TO is to stay (and I assume it is) then we really need some kind of motivating explanation - perhaps an example of why/when/how you would use a function here. With no existing examples in the code this seems a bit maybe-someone-someday-might-need-this-thing-that-somebody-dreamed. It was apparently RMS who added this [1]. I'm surprised that it's not more clear what good it is. [1] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D25075#20 In GNU Emacs 26.2 (build 1, x86_64-w64-mingw32) of 2019-04-13 Repository revision: fd1b34bfba8f3f6298df47c8e10b61530426f749 Windowing system distributor `Microsoft Corp.', version 10.0.17134 Configured using: `configure --without-dbus --host=3Dx86_64-w64-mingw32 --without-compress-install 'CFLAGS=3D-O2 -static -g3''