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#65017: 29.1; Byte compiler interaction with cl-lib function objects, removes symbol-function Date: Mon, 07 Aug 2023 22:33:31 -0400 Message-ID: References: <8B08E514-B2D5-48F5-BA90-4F5A9492F8F9@gmail.com> 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="7307"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Alan Mackenzie , 65017@debbugs.gnu.org, Eric Marsden To: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Aug 08 04:34:30 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 1qTCYI-0001eh-CM for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 08 Aug 2023 04:34:30 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qTCXz-0003EQ-Dt; Mon, 07 Aug 2023 22:34:11 -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 1qTCXu-0003EA-Cw for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2023 22:34:06 -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 1qTCXq-0004i5-Iu for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2023 22:34:06 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qTCXq-0001r0-3U for bug-gnu-emacs@gnu.org; Mon, 07 Aug 2023 22:34: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: Tue, 08 Aug 2023 02:34:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65017 X-GNU-PR-Package: emacs Original-Received: via spool by 65017-submit@debbugs.gnu.org id=B65017.16914620397117 (code B ref 65017); Tue, 08 Aug 2023 02:34:02 +0000 Original-Received: (at 65017) by debbugs.gnu.org; 8 Aug 2023 02:33:59 +0000 Original-Received: from localhost ([127.0.0.1]:34624 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qTCXm-0001qi-Qn for submit@debbugs.gnu.org; Mon, 07 Aug 2023 22:33:59 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:22819) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qTCXh-0001qR-Pc for 65017@debbugs.gnu.org; Mon, 07 Aug 2023 22:33:57 -0400 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id E14C980699; Mon, 7 Aug 2023 22:33:47 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1691462026; bh=5p/flkQvkyY6YSvRPjJLLxflXtV/tGzfKNG6c0HkgZ4=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=ZX6Wuoz/l1JzvVs5MRoN9a045yDliK6vqEB2dtRGZkkn/LrCeIo6embCcicXVStRu QNxQ9Zm7+XhGsWc+PQ0vPUOJgt8cwAXWsKGHmCwVJj5s0xlA9GmHkd5x/Qjc6vZbZz nxr70UuK7syVmj7uqTbOIQl5Fx4mBFEekNm599w7Z8RtogWh1zs6kOqnN7wQAAauJk 7zdLKQ7sph8G/P1ulAW5w28797vU+633duXr8+5ShPJWRpwT0rcXYcq76L5BDJ5g8D 9tJHcx/mrSK9r6h9o9F2orkO8qFBbiY2iOeeFD24O8xO1SGt0yT+jdZDGwbK+1a8uw N86AALszoP6Cw== Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 5793C80058; Mon, 7 Aug 2023 22:33:46 -0400 (EDT) Original-Received: from alfajor (host56.201-252-107.telecom.net.ar [201.252.107.56]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 169271202EA; Mon, 7 Aug 2023 22:33:44 -0400 (EDT) In-Reply-To: ("Mattias =?UTF-8?Q?Engdeg=C3=A5rd?="'s message of "Sun, 6 Aug 2023 12:47:15 +0200") 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:266911 Archived-At: >>> Separate data structures for locations might be an option worth exploring, >>> keeping the actual s-expressions unadorned. Consider a reader mode that also >>> produces a table mapping cons cells read to their locations, for example. >> When Alan looked at it, the cost seemed prohibitive. > I'm not aware of the details but think that it may be worth revisiting. Feel free :-) > The only serious difficulty a priori appears to be keeping locations in > transformed code, but most of our diagnostics are issued on code before Lisp > optimisations so this should mostly matter to macro-expansion. We shouldn't emit errors/warnings from byte-opt, indeed, so that part doesn't need to preserve the info, but we still need to preserve it at least through macro-expansion and cconv. > Yes, Scheme doesn't have much problems with user code manipulating Lisp as data. > But what do actual Lisp compilers do? Do they perform a slow re-read when > until they get to the location they want, when they need to issue > a diagnostic? (Relint does something similar, in fact.) Scheme's macro system has a notion of "syntactic object" (i.e. an sexp combined with metainfo), and the macros make it clear when you're looking inside a syntactic object or when you're building a new syntactic object. Don't know what Common Lisp systems do with `defmacro`, sorry. I know Gambit Scheme has "defmacro" (under the name `define-macro`) but it treats it as "second class citizen" in the sense that when using a macro defined with `define-macro`, the metainfo is just lost. Stefan