From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#23675: 30.0.50: make count-lines optionally ignore invisible lines Date: Sat, 05 Aug 2023 09:32:26 +0300 Message-ID: <83v8dut2x1.fsf__32791.6189607762$1691217203$gmane$org@gnu.org> References: <87ttteuy0g.fsf@neverwas.me> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39730"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-erc@gnu.org, Stefan Monnier , 23675@debbugs.gnu.org, rsw@gnu.org To: "J.P." Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 05 08:33:17 2023 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 1qSAqj-000A9n-HH for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 05 Aug 2023 08:33:17 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qSAqW-00019c-6y; Sat, 05 Aug 2023 02:33:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qSAqU-00019Q-Sg for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2023 02:33:02 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qSAqU-0008J4-Kr for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2023 02:33:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qSAqU-00017H-Gh for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2023 02:33:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 05 Aug 2023 06:33:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23675 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch fixed Original-Received: via spool by 23675-submit@debbugs.gnu.org id=B23675.16912171424245 (code B ref 23675); Sat, 05 Aug 2023 06:33:02 +0000 Original-Received: (at 23675) by debbugs.gnu.org; 5 Aug 2023 06:32:22 +0000 Original-Received: from localhost ([127.0.0.1]:55257 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qSApq-00016P-AA for submit@debbugs.gnu.org; Sat, 05 Aug 2023 02:32:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56770) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qSApo-00016D-OQ for 23675@debbugs.gnu.org; Sat, 05 Aug 2023 02:32:21 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qSApi-0008Af-9k; Sat, 05 Aug 2023 02:32:14 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=6mSkyRW3kCWsMS6gAdsN7AXLmHgTgyFAkVS5M+7XOs4=; b=ZRuN3cb+BWWT iEHSfUMHaHX+VRnfyNWn9/BtIJ7TVSrNFW7gZA08Fqc928enJ8OayjyifSFEkxgTqetjh3+QEGcig ms9j3C4HhrWI7tusR6cwB1JKYbpf/bJSmkkc22visw0kYSxQhAZuqxrYwLUnK+APXJ5PYiIUM6uIy cXqqxzfZezUJ8sTFbGdyxUozKho+H/y1Y8LYTWvwtqIlNS3zbOCx/ZtzIoV/C3/bIG65TIxPkf4Sk +PavTWB+SLME7zeswu0M19/ZvNsQ3B7QDpQ+thTuyjpQHxlapskoG4Yf+w9d52YvG0G65YJJEGbSa MA/k+3lsg7+hgm/tUAeaSA==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qSApf-0004hD-VB; Sat, 05 Aug 2023 02:32:13 -0400 In-Reply-To: <87ttteuy0g.fsf@neverwas.me> (jp@neverwas.me) 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:266730 Archived-At: > Cc: emacs-erc@gnu.org, rsw@gnu.org > From: "J.P." > Date: Fri, 04 Aug 2023 17:35:27 -0700 > > Perhaps I'm not understanding how the `ignore-invisible-lines' parameter > for `count-lines' is supposed to work, but it doesn't seem to make the > function consider `invisible' text properties that have lists as values. > I bring this up because ERC will likely be needing a line-counting > function that's list-aware, at least in the manner shown in the attached > tests. The change to `count-lines' accompanying these tests was merely > lifted from `forward-visible-line' to make them pass, but it's quite > possibly flawed and/or incomplete. If a proper solution ever emerges to > address this, hopefully it'll come at the hands of someone better > informed than I in the ways of Emacs invisibility. In the meantime > (2023), ERC will likely be doing its own subpar rendition unless someone > takes up the challenge for 30.1 (and Compat agrees to adopt it). Thanks. This is OK for master, but please don't use cl-incf in simple.el, as there's no real need to do so there. Stefan, any comments?