From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: scratch/accurate-warning-pos: Solid progress: the branch now bootstraps. Date: Sun, 02 Dec 2018 21:28:21 -0500 Message-ID: References: <20181129220552.GI12576@ACM> <9dde4ed7-8401-6022-a668-258d48bb7726@cs.ucla.edu> <20181130185503.GA16256@ACM> <20181130220218.GB16256@ACM> <138d56b7-53df-1ea5-377c-8502245f1b6b@cs.ucla.edu> <5C0239DA.4030907@gmx.at> <20181201124727.GC5102@ACM> <5C02962C.5040505@gmx.at> <20181201172127.GA29324@ACM> <7faee658-7ad0-4339-00e3-fef198a84121@gmail.com> <37f5c7fb-c1ce-e5b6-d242-5d9c2f3b3576@cs.ucla.edu> <87d0qjhixo.fsf@runbox.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1543804137 6643 195.159.176.226 (3 Dec 2018 02:28:57 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 3 Dec 2018 02:28:57 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 03 03:28:53 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gTdye-0001cD-U6 for ged-emacs-devel@m.gmane.org; Mon, 03 Dec 2018 03:28:53 +0100 Original-Received: from localhost ([::1]:46494 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gTe0l-0007xx-Ib for ged-emacs-devel@m.gmane.org; Sun, 02 Dec 2018 21:31:03 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46030) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gTdyN-0006su-HO for emacs-devel@gnu.org; Sun, 02 Dec 2018 21:28:36 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gTdyK-0008I5-Dz for emacs-devel@gnu.org; Sun, 02 Dec 2018 21:28:35 -0500 Original-Received: from [195.159.176.226] (port=38103 helo=blaine.gmane.org) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gTdyK-0008Ho-7m for emacs-devel@gnu.org; Sun, 02 Dec 2018 21:28:32 -0500 Original-Received: from list by blaine.gmane.org with local (Exim 4.84_2) (envelope-from ) id 1gTdw9-00074h-2T for emacs-devel@gnu.org; Mon, 03 Dec 2018 03:26:17 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 16 Original-X-Complaints-To: usenet@blaine.gmane.org Cancel-Lock: sha1:ZTB6phKWpSymD8du/+B4BfeyYEA= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 195.159.176.226 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:231596 Archived-At: > We don't need to invent a new property or rewrite every macro to make > macros work on position-annotated ASTs, because we already have this > feature. It's (declare (debug ...)), aka Edebug specifications, and it > is how Edebug gets exact source positions when stepping through code > which contains macros. This isn't quite right: e.g. relying only on the debug spec for the `defun` macro would require to strip out the source-position annotation from the function name, args, and docstring, which would prevent precise position information for errors in those parts. It's probably not terribly important (we'd likely fallback on the position of the open-paren that starts the `defun` which isn't too bad), but it's not as good as what we could get by changing the macro to be annotation-aware. Stefan