From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Arthur Miller Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] Lazy wdired preprocessing Date: Fri, 26 Mar 2021 02:00:48 +0100 Message-ID: References: <87wntuzv7m.fsf@web.de> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3548"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Michael Heerdegen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Mar 26 02:16:58 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lPb5u-0000oQ-1V for ged-emacs-devel@m.gmane-mx.org; Fri, 26 Mar 2021 02:16:58 +0100 Original-Received: from localhost ([::1]:43406 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lPb5t-0000XQ-57 for ged-emacs-devel@m.gmane-mx.org; Thu, 25 Mar 2021 21:16:57 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41058) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lPb4v-0008MB-E3 for emacs-devel@gnu.org; Thu, 25 Mar 2021 21:15:57 -0400 Original-Received: from mail-oln040092075055.outbound.protection.outlook.com ([40.92.75.55]:44746 helo=EUR04-VI1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lPb4s-0001zz-Nn for emacs-devel@gnu.org; Thu, 25 Mar 2021 21:15:56 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mlig0qQkQ5uF7HJ6znJ2WPKiecU4Jt5E3dTEKFjhImnmidJjCoHqd6I2nUSwgN6mVpCljOX1nLJIYNWsC1o4NNwd8VPFAlx1OMugCCnW7J6xf0t5iSc6iYAgqvddgRsEyAAGRCZoHmMw6kDt4KvIXDsuKfZpq1idomGifcLNDcfKIRRKkazth2jZUg2aBh2WaDDjxg85viriY5YP6anEUt2/gfvN3U1rKORaoMIurOiuuJJBraZ8i4lDYJjL4l3+t8nTW+jnO2VpSlApkFoynx1aOgeAAfV3AvelebMCLMUtY+kXIuW3ixe3f/iGoTRVYb5AdxTyvWd75//ZiEDe3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=K9XoFa113dvDZw2HCNYwSKc76lq0YXWib6nMf/gwvtY=; b=SAmE3b2WNQMMnGmRDIZmLKQRPrW7UvFS+ySPVQPcrC5IDzp1cfVC7Z9qkTX+8IYAKXfPwnm5z0aXtQfXbhREj+n90gYpk90hLXWyQatLPZ9EIfDOhoozmU8S8WJbkX+xUGRKkeVEK+LJn7jG9lbJgNBZHaapT/9Rx5sQBxIMyddubRLmKOaCZlIOxdOnHBaXenkfF3ehoz/rocq839ndFcis2mtMV5S8Qxs26d+GtlA81GC87w44ZVcvmAPzCsp07NPh6JVNFsmqMRa5pk3wH0JbhYnSAScnpC5zbXDd8oEtSxpQ0bYTwQx7yB+HlHOL0DjWeUqxv3J44IxB6d35vA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=live.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=K9XoFa113dvDZw2HCNYwSKc76lq0YXWib6nMf/gwvtY=; b=cl6O+BxEpdy85+x26FVDOLWRpQqN7gdUmEdd9gyunO02o4MGeviqyFYbsyPNcfVDVZasx24CfeCXJy8QYPxtKN8DeFyQ9xVN5E2vuFO5amfuAGx4CV3drpYVpTMFbMZoPHd5/j6oK2nNwpAcYsaFEYLC6Tc4JUAlZHJ5Pl2e5GFjdPiwCCI5vCAWkVfHJ9x+Xje3JRjl/fiixi4/gbmfQmENML43sm5sy2J2Ggbq8bkLbYJ1jLjc7r09AsgDH+fJPnT/iX3vR/DR7eK0kwElqJBuRuqslYnkXi3spR4jIg8QBlzZh6xFWAlvomQAuUYQGs0e/ur84TxE5wJYzaTSIA== Original-Received: from VI1EUR04FT020.eop-eur04.prod.protection.outlook.com (2a01:111:e400:7e0e::44) by VI1EUR04HT129.eop-eur04.prod.protection.outlook.com (2a01:111:e400:7e0e::183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3977.29; Fri, 26 Mar 2021 01:00:50 +0000 Original-Received: from AM9PR09MB4977.eurprd09.prod.outlook.com (2a01:111:e400:7e0e::52) by VI1EUR04FT020.mail.protection.outlook.com (2a01:111:e400:7e0e::422) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3977.25 via Frontend Transport; Fri, 26 Mar 2021 01:00:50 +0000 X-IncomingTopHeaderMarker: OriginalChecksum:3648F3A28A6765500C46FD5F2B17FDD46630451D3270FFF829FCE1619E697822; UpperCasedChecksum:1E5C5D1FAF107B3921974DF7AF65CD2AB1A3C518000D26C96AA932808BD485D1; SizeAsReceived:7465; Count:46 Original-Received: from AM9PR09MB4977.eurprd09.prod.outlook.com ([fe80::2103:e705:bc0c:5a8b]) by AM9PR09MB4977.eurprd09.prod.outlook.com ([fe80::2103:e705:bc0c:5a8b%6]) with mapi id 15.20.3977.025; Fri, 26 Mar 2021 01:00:49 +0000 In-Reply-To: <87wntuzv7m.fsf@web.de> (Michael Heerdegen's message of "Fri, 26 Mar 2021 00:09:49 +0100") X-TMN: [MFXjjoq/tMl3oSVrDtVqMEjf5YpqL02g] X-ClientProxiedBy: AS8PR04CA0070.eurprd04.prod.outlook.com (2603:10a6:20b:313::15) To AM9PR09MB4977.eurprd09.prod.outlook.com (2603:10a6:20b:304::20) X-Microsoft-Original-Message-ID: <87zgyqpw3j.fsf@live.com> X-MS-Exchange-MessageSentRepresentingType: 1 Original-Received: from pascal.homepc (90.230.29.56) by AS8PR04CA0070.eurprd04.prod.outlook.com (2603:10a6:20b:313::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3977.24 via Frontend Transport; Fri, 26 Mar 2021 01:00:49 +0000 X-MS-PublicTrafficType: Email X-IncomingHeaderCount: 46 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-Correlation-Id: 6649cdf8-0976-47a5-97ab-08d8eff2987d X-MS-TrafficTypeDiagnostic: VI1EUR04HT129: X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: RZcrcL/spdaKLRoyUYAC7xud6Rnv280gCWTbDl4UcIEJTA0V7LvXvh+b4uuhS51Z1bmWdpgtKujGpoaZXQCW06+NSZ5zE9pYi0M3Zzn2qr/v1djgrUtiG+Zma7yNHrazLnWHRkDUuYg6krro/i2maLgPVZlXcmUQbx5T2d7ADGxD3QvZaJzqAcQwwGV/8YY0/xbYl4nmfZ2TxJIIwHScppyYIlNlpecodGgY7TfHqnzH5ek4/XP+hkpCZzD9CFMpqQaV0XvQdtoZdvCGOpZly4Ac18JWJhCPEVfHgtOBr+bqyWnnS/M/j7Lyko8vdqVj3+v6A9I5ySXqnRQYNInsaw/3uOOXB0tGn8teednqpIRSVSffNZ5QD0y2lixyl3zKuADFi9cSgdw4jx4jiRnuSA== X-MS-Exchange-AntiSpam-MessageData: UQXbNqrXJWEDJdAiHa7ioQaGBFAFtZexnWkV4JYtpBndilV/o5OJfou0RqaHnJsBnhxK6zXWhiRUy967OPwxrr8620RFcv6xanm+Ocw2FxWQlyAEudZMKSUS2Mu0K1kAapjroE+dv5l63ZrZ+hbS7w== X-OriginatorOrg: live.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6649cdf8-0976-47a5-97ab-08d8eff2987d X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Mar 2021 01:00:49.6588 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-AuthSource: VI1EUR04FT020.eop-eur04.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: Internet X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1EUR04HT129 Received-SPF: pass client-ip=40.92.75.55; envelope-from=arthur.miller@live.com; helo=EUR04-VI1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:267054 Archived-At: Michael Heerdegen writes: > Arthur Miller writes: > >> Haven't got any repsonses, but for me it seems to work fine. Maybe I >> haven't tested some use-case though. > > I have understood what you want to achieve. Could you please say one or > two sentences about what the purpose of the changes in wdired.el is - > are they necessary to make lazy-wdired.el work, or are there user > visible changes (improvements) already for wdired.el alone? Lazy-wdired.el was just my working file, I sent it for the convenience: if anyone wishes to easily test without need to apply patch to wdired.el, but patch is what it is about; i.e. you can throw away lazy-wdired.el :). This was re-implementation of parts of wdired to make it more efficient and faster to enter the wdired mode. This patch makes wdired process only those lines in a region where changes are requested, in interactive cases usually just one line at a time. That makes it always same cost to enter wdired and possibly also saves some battery life when user does not mean to edit all file names. Price is somewhat slower editing per line, but I can't notice any slowdowns or delays on my computer. If you check original code, it will pre-process entire dired buffer to make some part of dired non-editable. On directories with large number of files (~500+) that results in a noticable delay when entering wdired mode. There are no user-visible changes, other then a refusing to enter wdired when there are no files in a directory. I could remove that error, but I don't think there is purpose to enter writable dired for empty directory. I hope it is correct assumption. So it is just a little optimization.