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#22457: 24.5; [PATCH] `dired-mark-if' should not count non-changes Date: Tue, 25 Jun 2019 16:26:58 -0700 (PDT) Message-ID: <727b63b3-3571-4bcb-821a-6f9f9f4346a4@default> References: <2a6ff247-2b75-4f85-9a4c-889576ed7b34@default> <87o92lmgez.fsf@web.de> <87ftnxmfoo.fsf@web.de> 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="169754"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 22457@debbugs.gnu.org To: Michael Heerdegen , Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Jun 26 01:28:19 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.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hfurK-000i3l-LW for geb-bug-gnu-emacs@m.gmane.org; Wed, 26 Jun 2019 01:28:18 +0200 Original-Received: from localhost ([::1]:35760 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfurI-00038g-W9 for geb-bug-gnu-emacs@m.gmane.org; Tue, 25 Jun 2019 19:28:17 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47365) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hfur6-00038A-3k for bug-gnu-emacs@gnu.org; Tue, 25 Jun 2019 19:28:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hfur4-0005Zc-JW for bug-gnu-emacs@gnu.org; Tue, 25 Jun 2019 19:28:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48557) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hfur4-0005ZK-5k for bug-gnu-emacs@gnu.org; Tue, 25 Jun 2019 19:28:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hfur4-0003Iv-10 for bug-gnu-emacs@gnu.org; Tue, 25 Jun 2019 19:28:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 25 Jun 2019 23:28:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22457 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: fixed Original-Received: via spool by 22457-submit@debbugs.gnu.org id=B22457.156150522912617 (code B ref 22457); Tue, 25 Jun 2019 23:28:01 +0000 Original-Received: (at 22457) by debbugs.gnu.org; 25 Jun 2019 23:27:09 +0000 Original-Received: from localhost ([127.0.0.1]:33868 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfuqD-0003HR-99 for submit@debbugs.gnu.org; Tue, 25 Jun 2019 19:27:09 -0400 Original-Received: from userp2130.oracle.com ([156.151.31.86]:40914) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hfuqB-0003HE-QJ for 22457@debbugs.gnu.org; Tue, 25 Jun 2019 19:27:08 -0400 Original-Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x5PNPja2195065; Tue, 25 Jun 2019 23:27:02 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=07o6smSQjpRt0rSFiBgTQQMm+JOT3Omb8JhrcC1M47M=; b=LSKEoSW8msU1ChsIILJISDaZTB711QAB0gGUsnzr2AOxjDXiHXCZ/FiZXi/1gIX1aKVk LZ3PQYXOFuo7mdHzqs8FDGjUStgO2pGgFMBjp0ND8/gmAfTGaq2as48WmKmI2JdQEuXJ 9mq6yi28rim/JlfRRFWXKkpnCIIporVB6P1BvUI/KrfiPH6F/CrBn9g7eo/2fz5wn+Bc LbTOcf63Wr6+xpTLJF48/NXPej+0DU1jdk4QfjJWFeOwVfCa9itmwXuF2AeYN+zTl8Jn chHpzJmt8j6EeCYJeRfXG1DJaBVorzniwSrgdciU+0lbqLu+aPXXzikYsd0L5nCy/oC9 wQ== Original-Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by userp2130.oracle.com with ESMTP id 2t9brt77e8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 25 Jun 2019 23:27:01 +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 x5PNQkGp065013; Tue, 25 Jun 2019 23:27:01 GMT Original-Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by aserp3020.oracle.com with ESMTP id 2t9p6uf8f0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 25 Jun 2019 23:27:01 +0000 Original-Received: from abhmp0001.oracle.com (abhmp0001.oracle.com [141.146.116.7]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x5PNQxk7021252; Tue, 25 Jun 2019 23:27:00 GMT In-Reply-To: <87ftnxmfoo.fsf@web.de> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4861.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9299 signatures=668687 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-1906250190 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9299 signatures=668687 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-1906250191 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:161445 Archived-At: > Oh, btw, this patch line >=20 > (looking-at-p (char-to-string dired-marker-char)) >=20 > is not good if dired-marker-char is a regexp special like . or ?, I > guess (regexp-quote missing)? It's a good point; it would be clearer to wrap the arg to `looking-at-p' with `regexp-quote'. It works as coded, however, because Emacs regexp matching treats a special char such as `*' as non-special in such a context. I'm not saying it's good to rely on that (documented) behavior - it's better to use `regexp-quote'. See (elisp)`Syntax of Regexps': *Please note:* For historical compatibility, special characters are treated as ordinary ones if they are in contexts where their special meanings make no sense. For example, '*foo' treats '*' as ordinary since there is no preceding expression on which the '*' can act. It is poor practice to depend on this behavior; quote the special character anyway, regardless of where it appears.