From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#57009: Obscure doc string of new variable syntax-wholeline-max Date: Sat, 6 Aug 2022 14:32:11 +0000 Message-ID: References: <877d3l5y4n.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1511"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Stefan Monnier , 57009@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 06 16:33:10 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 1oKKrV-00008p-VX for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 06 Aug 2022 16:33:09 +0200 Original-Received: from localhost ([::1]:40382 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oKKrU-0003du-Rl for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 06 Aug 2022 10:33:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41746) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oKKrO-0003dm-CI for bug-gnu-emacs@gnu.org; Sat, 06 Aug 2022 10:33:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:45453) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oKKrO-00018E-37 for bug-gnu-emacs@gnu.org; Sat, 06 Aug 2022 10:33:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oKKrN-0004Dp-Sy for bug-gnu-emacs@gnu.org; Sat, 06 Aug 2022 10:33:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 06 Aug 2022 14:33:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57009 X-GNU-PR-Package: emacs Original-Received: via spool by 57009-submit@debbugs.gnu.org id=B57009.165979634516184 (code B ref 57009); Sat, 06 Aug 2022 14:33:01 +0000 Original-Received: (at 57009) by debbugs.gnu.org; 6 Aug 2022 14:32:25 +0000 Original-Received: from localhost ([127.0.0.1]:35202 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oKKqn-0004Cy-Ag for submit@debbugs.gnu.org; Sat, 06 Aug 2022 10:32:25 -0400 Original-Received: from colin.muc.de ([193.149.48.1]:47599 helo=mail.muc.de) by debbugs.gnu.org with smtp (Exim 4.84_2) (envelope-from ) id 1oKKqh-0004Cf-Rl for 57009@debbugs.gnu.org; Sat, 06 Aug 2022 10:32:23 -0400 Original-Received: (qmail 14919 invoked by uid 3782); 6 Aug 2022 14:32:12 -0000 Original-Received: from acm.muc.de (p2e5d57a4.dip0.t-ipconnect.de [46.93.87.164]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Sat, 06 Aug 2022 16:32:11 +0200 Original-Received: (qmail 6862 invoked by uid 1000); 6 Aug 2022 14:32:11 -0000 Content-Disposition: inline In-Reply-To: <877d3l5y4n.fsf@gnus.org> X-Submission-Agent: TMDA/1.3.x (Ph3nix) X-Primary-Address: acm@muc.de 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:238990 Archived-At: Hello, Lars. On Sat, Aug 06, 2022 at 14:56:24 +0200, Lars Ingebrigtsen wrote: > Alan Mackenzie writes: > > Maximum line length for syntax operations. > > If lines are longer than that, syntax operations will treat them as chunks > > of this size. Misfontification may then occur. > > This is a tradeoff between correctly applying the syntax rules, > > and avoiding major slowdown on pathologically long lines. > > Probably introduced at or before Emacs version 29.1. > > .. There are several bugs here: > > (i) It is not clear what is meant by "syntax operations". These should > > be listed and if necessary, explained. > You mean mention syntax-ppss? Yes, if that is one of the operations involved. Also, if pertinent, parse-partial-sexp, forward-list and friends, syntax-propertize, .... > > (ii) It is not clear what it means for a "syntax operation" to treat a > > line "as a chunk". This should be explained. > It's saying that it's processing the line chunk-wise. I think that's > pretty clear? If it's clear to you, please explain in a way that's clear to me. :-) Say the chunk is 64 characters long. Doesn't parse-partial-sexp process that "as a chunk" anyway? How does one determine where a "chunk" starts and where it ends? What does "treating a line as a chunk" do that is new that we didn't do before? > > (iii) "Misfontification" may well occur, but what about other bad effects > > of ignoring correct syntax? Don't they deserve a mention? > Do they? They might, it depends how clear the rest of an amended text makes things. For example, will C-M-n still work? > > (iv) There is no mention of a mechanism to disable this "chunking" > > effect, whatever it might be. If there is one, it should be > > documented, if there's not, this should be stated. > That seems self-evident -- you increase the size? It is anything but self-evident. It might be by setting the variable to 0, it might be by setting it to nil, it might be, as you suggest by setting it to a larger size than you think will occur in practice (i.e. there's no way to disable it). All these ways are in use in Emacs. > There doesn't really seem to be much to alter here to me, but perhaps > others have other opinions; adding Stefan to the CCs. As matters stand, I'd have to read the source code to work out what this variable is for. I don't think I should have to. -- Alan Mackenzie (Nuremberg, Germany).