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#63861: [PATCH] pp.el: New "pretty printing" code Date: Wed, 07 Jun 2023 11:21:23 -0400 Message-ID: References: <83fs799jmi.fsf@gnu.org> <86r0qqnjce.fsf@mail.linkov.net> 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="12138"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 63861@debbugs.gnu.org, eliz@gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jun 07 17:22:23 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 1q6uzP-0002xM-C6 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 07 Jun 2023 17:22:23 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q6uz5-0007Vp-Nw; Wed, 07 Jun 2023 11:22:03 -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 1q6uz4-0007VM-Oz for bug-gnu-emacs@gnu.org; Wed, 07 Jun 2023 11:22:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1q6uz4-0006mQ-Gt for bug-gnu-emacs@gnu.org; Wed, 07 Jun 2023 11:22:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1q6uz4-0004k9-3C for bug-gnu-emacs@gnu.org; Wed, 07 Jun 2023 11:22:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 07 Jun 2023 15:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63861 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-Cc: "Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors" , 63861@debbugs.gnu.org, Eli Zaretskii Original-Received: via spool by 63861-submit@debbugs.gnu.org id=B63861.168615129718191 (code B ref 63861); Wed, 07 Jun 2023 15:22:02 +0000 Original-Received: (at 63861) by debbugs.gnu.org; 7 Jun 2023 15:21:37 +0000 Original-Received: from localhost ([127.0.0.1]:54518 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q6uye-0004jF-Um for submit@debbugs.gnu.org; Wed, 07 Jun 2023 11:21:37 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:25630) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q6uyd-0004it-PN for 63861@debbugs.gnu.org; Wed, 07 Jun 2023 11:21:36 -0400 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 69DA3441553; Wed, 7 Jun 2023 11:21:30 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id AB40344155D; Wed, 7 Jun 2023 11:21:24 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1686151284; bh=FVNZ6oFSDc2WFENjozGXe/vlamLI/zmVGhX91/SCCEk=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=S56QMUZHjAx6J05KONi+/6kOmCEFu8zeYLpBcX2nIZVl0xMj16+Uk/w6dj/9wahWP EM8pbGV6fzcjkBstIGdJtuxTS86W2KK6pDZU4PMG0YoUzg1ARJYf6MMpaN4s8MeJlJ Nw2QKq1wq+MPEGTF22hbsvBRng1eQLutYV3txtAleEf4D7WRVb89PNcQhdurju8Au+ S7uFtebugsNAykZuwHBRRWRQBBbtQeoY+V122V5e7042dUO8Mo/hv8TPei3w7BOANl rD6Hh2sEBQkZOPyPOmWWMEHIUoO2Bp0nrCP/uYY5ZYys3vghyti1veion3vLyZ3u1I yW8SkHqW630iA== Original-Received: from lechazo (lechon.iro.umontreal.ca [132.204.27.242]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 939C512077F; Wed, 7 Jun 2023 11:21:24 -0400 (EDT) In-Reply-To: <86r0qqnjce.fsf@mail.linkov.net> (Juri Linkov's message of "Mon, 05 Jun 2023 19:12:49 +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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:263075 Archived-At: >> FWIW, the change affects other functionality that uses `pp`, such as >> `C-h v`. While working on (previous versions of) this code, I've had >> performance problems show up during the generation of `emoji-labels.el`. > > When tried on emoji-labels.el, at the end it failed with > > (scan-error "Containing expression ends prematurely" 255866 255867) Hmm... when I do rm lisp/international/emoji-labels.el make the file is rebuilt correctly. Could you give more details about how you got the above? >>> Also, I think this warrants a NEWS entry and should be documented in >>> the ELisp manual. >> Definitely for NEWS, yes. For the ELisp manual, currently we don't >> document `pp-buffer`, the closest I see is `indent-pp-sexp` (in >> `programs.texi`). > For indent-pp-sexp with a prefix arg used on defuns, the new version > is much better - it makes code more readable. It has only one snag: > it inserts an empty line between the defun line and the docstring. Oh, indeed, I'm not careful to check before I insert the `\n` in this case (I always use it on code that starts as a single line). I'll fix it in the next round, thanks. Stefan