From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#57266: Maintaining the base_line_number cache Date: Mon, 22 Aug 2022 14:02:44 -0400 Message-ID: References: <831qteccli.fsf@gnu.org> <834jy4bhqp.fsf@gnu.org> <83y1vga0l5.fsf@gnu.org> <83edx89rl4.fsf@gnu.org> Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24315"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: 57266@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Aug 22 21:24:38 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1oQD2M-00067Q-OL for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 22 Aug 2022 21:24:38 +0200 Original-Received: from localhost ([::1]:53552 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oQD2L-0003iU-BO for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 22 Aug 2022 15:24:37 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57032) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oQBlO-00007M-OH for bug-gnu-emacs@gnu.org; Mon, 22 Aug 2022 14:03:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51955) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oQBlO-0006zP-B2 for bug-gnu-emacs@gnu.org; Mon, 22 Aug 2022 14:03:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oQBlN-0001nP-U3 for bug-gnu-emacs@gnu.org; Mon, 22 Aug 2022 14:03:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 22 Aug 2022 18:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57266 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 57266-submit@debbugs.gnu.org id=B57266.16611913756890 (code B ref 57266); Mon, 22 Aug 2022 18:03:01 +0000 Original-Received: (at 57266) by debbugs.gnu.org; 22 Aug 2022 18:02:55 +0000 Original-Received: from localhost ([127.0.0.1]:41704 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oQBlH-0001n3-Dk for submit@debbugs.gnu.org; Mon, 22 Aug 2022 14:02:55 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:57303) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oQBlG-0001mo-0Z for 57266@debbugs.gnu.org; Mon, 22 Aug 2022 14:02:54 -0400 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 5B6614412F6; Mon, 22 Aug 2022 14:02:47 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id CA401441264; Mon, 22 Aug 2022 14:02:45 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1661191365; bh=+DB+/FTD9hIU+Bu+M66J2xe46lZZx6amqg7gk3j2Lrc=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=JKvt0wjkLwGmNEYpqJ7BetfI9agGX697k2wQz/2rQfkMJ99V0BevxMDrxAxD7KnZe /Y//vRMZX3HAyflNEr/VoBjikfA++2c6Mf+EIr5gUc2VLZzmKSjbMYlsXVqm7bt97j jthjk1rZ5IjtnT5jDmRgZO7mj6pOf1RAMhwE9qVbE4Afy44uC+nG+XMYBvDwIQn0t1 FIJgVEDZo6Br1IIXAjqHuFDl0N+2gPkjzwJhhUlGQ3EyKaRr2I/Ue9dQViUy+R0w79 PIZ0mCSZvRDqpQTDMp24lwdws42qDwnfZzWUmN+7S0pzTO87Pxxgem0BorrmBiO8Iu k9GqNhYBJ0/hg== Original-Received: from lechazo (lechon.iro.umontreal.ca [132.204.27.242]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id A941112017B; Mon, 22 Aug 2022 14:02:45 -0400 (EDT) In-Reply-To: <83edx89rl4.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 22 Aug 2022 19:21:43 +0300") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:240463 Archived-At: >> >> > I didn't just mean just_this_one_p thingy, I meant all the changes >> >> > that attempt to somehow "clean up" the use of the line-number cache. >> >> > Why do we have to do that at all? This stuff is not too complex, and >> >> > it works for ages! Isn't the fact that we find more and more small >> >> > issues with the changes telling you something? >> >> >> >> Yes, it's telling me that the code is a mess and I'm trying to fix it by >> >> documenting what is actually needed. >> > >> > It's fine to fix and enhance the documentation, but please don't fix >> > the code that works. >> >> If the code doesn't match the doc, then we'll never know if the doc >> is wrong. > > Which is why I'm perfectly OK with documenting what the code does. But I'm not. Because I don't really know what the code does. The doc I wrote documents the design I came up with based on my understanding of what the code does. I went through the trouble of figuring out a design of how things *should* work, document it, and adjust the code to match the design. So I'm not interested in pushing some half-assed version of it that documents a design that doesn't match the reality, nor pushing partial fixes/workarounds (for borderline cases that noone ever bumped into anyway) while keeping the mess of unexplained hacks. > Please! I hope my requests mean something, given that I'm the only > one who works on bugs in these areas, and probably will keep doing > that for the observable future. Indeed, my proposed patch is not a bug fix. It's a code-maintenance patch. It's meant to improve the code, not the behavior. [ I do think it will improve the behavior in some cases (by fixing a few corner case bugs, and more importantly by improving performance when displaying a buffer is several windows), but that is not the motivation, and there is undoubtedly the risk that it will introduce regressions (which will help us better understand the code). ] Stefan