From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Josh Newsgroups: gmane.emacs.bugs Subject: bug#15641: 24.3; [PATCH] Add find-definition for M-. Date: Fri, 18 Oct 2013 12:01:21 -0700 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1382122934 14671 80.91.229.3 (18 Oct 2013 19:02:14 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 18 Oct 2013 19:02:14 +0000 (UTC) Cc: Leo Liu , 15641@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 18 21:02:18 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VXFJO-0007eK-6X for geb-bug-gnu-emacs@m.gmane.org; Fri, 18 Oct 2013 21:02:14 +0200 Original-Received: from localhost ([::1]:59085 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXFJN-00079d-LD for geb-bug-gnu-emacs@m.gmane.org; Fri, 18 Oct 2013 15:02:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53403) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXFJH-00079V-D2 for bug-gnu-emacs@gnu.org; Fri, 18 Oct 2013 15:02:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VXFJD-0007Zd-9c for bug-gnu-emacs@gnu.org; Fri, 18 Oct 2013 15:02:07 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:43188) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXFJD-0007ZT-5w for bug-gnu-emacs@gnu.org; Fri, 18 Oct 2013 15:02:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VXFJC-00076V-CK for bug-gnu-emacs@gnu.org; Fri, 18 Oct 2013 15:02:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Josh Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 18 Oct 2013 19:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15641 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 15641-submit@debbugs.gnu.org id=B15641.138212292027298 (code B ref 15641); Fri, 18 Oct 2013 19:02:02 +0000 Original-Received: (at 15641) by debbugs.gnu.org; 18 Oct 2013 19:02:00 +0000 Original-Received: from localhost ([127.0.0.1]:57207 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VXFJ9-00076D-DO for submit@debbugs.gnu.org; Fri, 18 Oct 2013 15:01:59 -0400 Original-Received: from mail-qe0-f48.google.com ([209.85.128.48]:59887) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VXFJ6-00075y-Os for 15641@debbugs.gnu.org; Fri, 18 Oct 2013 15:01:57 -0400 Original-Received: by mail-qe0-f48.google.com with SMTP id d4so2192576qej.35 for <15641@debbugs.gnu.org>; Fri, 18 Oct 2013 12:01:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc:content-type; bh=QLIFpZWrATRefxAgK7j1BANCaj5lOP29X7nNhfYm62Y=; b=Pm0km0xZwyn9maiQKPy90tD8CZ36dJKTAEP0r8UvBvKxuRBSeZx4Evoh/y8+t4Yfuk 22EJBWkNp6bQOQLxCFCyInlVJtshLfILGe1x0oVB+NbiqlARBB17HsuM0P2qxtxsW0Lg RLFDutZBi40xz34REf1/WCeo8KpjYrsWQaqZRaYl2dr5v/OpR5qZQWSkuEySbqf4Vedr gtgRzuls21WW4SQEOoE3hD1aUt1X2K5L5hGv7xM1kHabx6HGeA7U9cH5Z8SDCpVq3Wfd PF13LOUQBV16zTYWipuqaS2dA5riB2g22BCnv/bBxipDbTNAUSkC4NMkT+WXGx3Yumdy X/hA== X-Gm-Message-State: ALoCoQkrM+xXsmsKx6MR7r3PRLxx8F9ew1DaunHKl0HBGvupyI9dsgqLwImNG57XQ/nTR3hYFKfM X-Received: by 10.224.67.3 with SMTP id p3mr6626894qai.98.1382122911174; Fri, 18 Oct 2013 12:01:51 -0700 (PDT) Original-Received: by 10.49.38.162 with HTTP; Fri, 18 Oct 2013 12:01:21 -0700 (PDT) In-Reply-To: X-Google-Sender-Auth: y17Ce9d8rUShjIf29aMzUxQbA24 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 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.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:79370 Archived-At: On Fri, Oct 18, 2013 at 5:58 AM, Stefan Monnier wrote: >> I think we should just make M-. work on elisp-related places such as >> lisp-interaction-mode, emacs-lisp-mode, eval-expression and even >> help-mode. > > Right: M-. should not be bound to an command specific to etags but to > a command which delegates the work to a find-tag-function (whose > default can then be to use etags). > > Of course, find-tag-function should do "as little as possible": find the > corresponding place and return it. The generic part of the code will > take care of displaying the buffer, selecting it, remembering the > previous position, etc... so we don't need a pop-tag-mark-function. If you haven't already done so, it might be worth taking a look at elisp-slime-nav-mode[0], which implements something similar to your patch in a minor mode. Its author appears to have signed copyright papers as well. I'm in agreement with Stefan's inclination to make the entry points to this functionality sufficiently generic that they can be tagging system agnostic. If we start down that path for M-. it seems wise to consider and specify user interfaces to all of the related functionality (e.g. as described here[1]) at the same time in order to provide a single coherent set of commands and key bindings for navigating source trees, regardless of whether the navigation in any particular context is facilitated by etags, GNU Global, nrepl, or other means. [0] https://github.com/purcell/elisp-slime-nav [1] http://www.emacswiki.org/emacs/EmacsTags#toc1 Josh