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#61847: debug-early-backtrace only works some of the time. Date: Wed, 01 Mar 2023 18:01:24 +0200 Message-ID: <83edq8fokr.fsf@gnu.org> References: <83v8jkfz04.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22013"; mail-complaints-to="usenet@ciao.gmane.io" Cc: monnier@iro.umontreal.ca, 61847@debbugs.gnu.org To: Alan Mackenzie Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Mar 01 17:02:32 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 1pXOuV-0005TW-K8 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 01 Mar 2023 17:02:31 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pXOu4-0004Ot-7w; Wed, 01 Mar 2023 11:02:04 -0500 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 1pXOu2-0004MD-Lg for bug-gnu-emacs@gnu.org; Wed, 01 Mar 2023 11:02:02 -0500 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 1pXOu2-0002II-DC for bug-gnu-emacs@gnu.org; Wed, 01 Mar 2023 11:02:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pXOu2-0000kM-12 for bug-gnu-emacs@gnu.org; Wed, 01 Mar 2023 11:02:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 01 Mar 2023 16:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61847 X-GNU-PR-Package: emacs Original-Received: via spool by 61847-submit@debbugs.gnu.org id=B61847.16776864812820 (code B ref 61847); Wed, 01 Mar 2023 16:02:01 +0000 Original-Received: (at 61847) by debbugs.gnu.org; 1 Mar 2023 16:01:21 +0000 Original-Received: from localhost ([127.0.0.1]:54721 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pXOtM-0000jP-T7 for submit@debbugs.gnu.org; Wed, 01 Mar 2023 11:01:21 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:58038) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pXOtL-0000jB-2g for 61847@debbugs.gnu.org; Wed, 01 Mar 2023 11:01:19 -0500 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 1pXOtF-00022e-8d; Wed, 01 Mar 2023 11:01:13 -0500 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=wFOCaMS3KGQj/3FRZJ2hz1HxRLOr3LDggxvdxesW5gQ=; b=JoOkDhxtgxT2 jDWTOqATRCDkxfoCvsqZ1ebc6avlVqFl0KLKEzwIWGApfDfcTaLumlJcslgQbJ47LO2ww3c/OKGo3 6e53wE1Zoecbaj1T7i1HBVobJKXbkEFvzaIof9I8QbEVammGm3Ue8B5wdk67undAz5cIYshbePWZk sAV9oF0B6SOyM7U2grQQV1J679ii6398DYA7nNEfp2NGZpN9qzbKUM3kK9Tmsc6co7epG8gE6Eahf T+HE8i7+uCbMZXA7g6uUCnxPVBA7rbcufQK91Fk4UF7ibinzj/FAB5Do+7MWbZeyFKRRVgF5ZKdkr vmzSXXxU6B9Pe6ARRPrCTQ==; 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 1pXOtE-00071A-4R; Wed, 01 Mar 2023 11:01:12 -0500 In-Reply-To: (message from Alan Mackenzie on Wed, 1 Mar 2023 15:22:29 +0000) 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:257074 Archived-At: > Date: Wed, 1 Mar 2023 15:22:29 +0000 > Cc: monnier@iro.umontreal.ca, 61847@debbugs.gnu.org > From: Alan Mackenzie > > > And what use is the meaningless stream of raw bytes that prin1 > > produces? > > If that were indeed what was produced, none at all. Because > debug-early-backtrace binds print-escape-control-characters to t, what > actually gets produced is a mixture of ascii characters and octal > escaped representations, just like you see when an .elc file is visited > in Emacs. Escaping raw bytes doesn't make them more comprehensible. > > I think you should re-evaluate your preferences, and base them on real > > advantages and disadvantages, not on imaginary ones. > > What makes you think I'm not doing this already? I wrote debug-early > last year because I _needed_ it. I've a lot of experience using it, and > the way it prints (or rather used to print) a compiled function is/was > useful. For you, maybe. Not for me. For me it's a nuisance. A useless waste of screen estate. > You can see how many arguments it takes. That information exists elsewhere. > You can see the byte code string, hence enabling you to compare it > visually with the contents of a .elc file, should such already > exist. Let's be serious, okay? > > If we want our backtraces to be more informative, not less, we should > > move farther away of "dumb" output functions that just spill the guts > > and towards more humanly-readable formatted description of the called > > functions. > > A wholesome long term goal I fully agree with. For the here and now, > outputting "#f(compiled-function () " and nothing > else is not a step in that direction. But using cl-prin1 _is_ a step in the right direction, because it allows us to extend the feature. And that is why I said that if loading Lisp breaks something in debug-early, we should solve this _now_, not fall back on prin1, which by its very nature cannot be extended so easily. > Besides, the idea of debug-early is to generate a backtrace before all > the fancy Lisp facilities are available. Some fancy Lisp facilities are already available anyway. And I see no reason for this requirement in this case.