From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#65631: Xref updates stack in case of error Date: Wed, 30 Aug 2023 20:16:07 +0300 Organization: LINKOV.NET Message-ID: <86leds30yw.fsf@mail.linkov.net> References: <864jkg4h0i.fsf@mail.linkov.net> <83r0nkfos1.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27705"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: 65631@debbugs.gnu.org, dmitry@gutov.dev To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Aug 30 19:18:15 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 1qbOpb-00070b-3i for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 30 Aug 2023 19:18:15 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qbOpI-0001h5-2U; Wed, 30 Aug 2023 13:17:56 -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 1qbOpG-0001gr-EJ for bug-gnu-emacs@gnu.org; Wed, 30 Aug 2023 13:17:54 -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 1qbOpG-0000ya-6J for bug-gnu-emacs@gnu.org; Wed, 30 Aug 2023 13:17:54 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qbOpN-0008Vw-QI for bug-gnu-emacs@gnu.org; Wed, 30 Aug 2023 13:18:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 30 Aug 2023 17:18:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65631 X-GNU-PR-Package: emacs Original-Received: via spool by 65631-submit@debbugs.gnu.org id=B65631.169341586632707 (code B ref 65631); Wed, 30 Aug 2023 17:18:01 +0000 Original-Received: (at 65631) by debbugs.gnu.org; 30 Aug 2023 17:17:46 +0000 Original-Received: from localhost ([127.0.0.1]:53913 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qbOp7-0008VT-Rp for submit@debbugs.gnu.org; Wed, 30 Aug 2023 13:17:46 -0400 Original-Received: from relay3-d.mail.gandi.net ([2001:4b98:dc4:8::223]:44473) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qbOp4-0008VD-S6 for 65631@debbugs.gnu.org; Wed, 30 Aug 2023 13:17:44 -0400 Original-Received: by mail.gandi.net (Postfix) with ESMTPSA id 7282D60003; Wed, 30 Aug 2023 17:17:27 +0000 (UTC) In-Reply-To: <83r0nkfos1.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 30 Aug 2023 20:01:02 +0300") X-GND-Sasl: juri@linkov.net 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:268738 Archived-At: >> 1. move point to any word >> 2. type 'M-.' (xref-find-definitions) >> 3. an error is displayed correctly "No definitions found for: This" >> >> But the problem is that an unrecognized word is added to the xref stack. >> So the context menu shows "Go Back", and 'M-,' (xref-go-back) goes back >> to that word. > > FWIW, I'm not sure this is necessarily a bug. It looks like a bug in > your case, because you deliberately tricked Xref into using a word > that is definitely not a program symbol. But that is not the case in > a more reasonable situation, where point is on a symbol, but for some > reason the symbol's definition is not found, e.g., because the TAGS > table needs to be regenerated. In case of error, point doesn't move. So there is no need to go back.