From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#19466: 25.0.50; xref-find-def doesn't find C functions Date: Wed, 21 Jan 2015 16:24:33 +0200 Message-ID: <54BFB6A1.8050802@yandex.ru> References: <8361cucl3u.fsf@gnu.org> <54A230CD.3040309@yandex.ru> <83vbktb1ct.fsf@gnu.org> <54A2EE15.3020406@yandex.ru> <831tnhasx0.fsf@gnu.org> <54A6DAF6.5070605@yandex.ru> <831tna9tmr.fsf@gnu.org> <54A9C94F.8040701@yandex.ru> <83vbkl99vm.fsf@gnu.org> <54B8878A.4050506@yandex.ru> <54B8C22B.3080200@gmx.at> <54BC7A77.5020307@yandex.ru> <54BCC033.2010104@gmx.at> <54BD076E.6090707@yandex.ru> <54BE0B5A.6060706@gmx.at> <54BE4693.5050804@yandex.ru> <54BE6B59.5090404@gmx.at> <54BF5345.9090303@yandex.ru> <54BF843E.10907@gmx.at> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1421850320 12478 80.91.229.3 (21 Jan 2015 14:25:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 21 Jan 2015 14:25:20 +0000 (UTC) Cc: 19466@debbugs.gnu.org, Helmut Eller To: martin rudalics , Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Jan 21 15:25:15 2015 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 1YDwDa-0006h7-LU for geb-bug-gnu-emacs@m.gmane.org; Wed, 21 Jan 2015 15:25:14 +0100 Original-Received: from localhost ([::1]:48586 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDwDa-0003TQ-2W for geb-bug-gnu-emacs@m.gmane.org; Wed, 21 Jan 2015 09:25:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59360) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDwDS-0003Qg-Nm for bug-gnu-emacs@gnu.org; Wed, 21 Jan 2015 09:25:11 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YDwDP-000343-FC for bug-gnu-emacs@gnu.org; Wed, 21 Jan 2015 09:25:06 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:32854) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDwDP-00033k-Bi for bug-gnu-emacs@gnu.org; Wed, 21 Jan 2015 09:25:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1YDwDO-0001ri-UE for bug-gnu-emacs@gnu.org; Wed, 21 Jan 2015 09:25:03 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 21 Jan 2015 14:25:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19466 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 19466-submit@debbugs.gnu.org id=B19466.14218502847136 (code B ref 19466); Wed, 21 Jan 2015 14:25:02 +0000 Original-Received: (at 19466) by debbugs.gnu.org; 21 Jan 2015 14:24:44 +0000 Original-Received: from localhost ([127.0.0.1]:51546 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YDwD6-0001r1-5U for submit@debbugs.gnu.org; Wed, 21 Jan 2015 09:24:44 -0500 Original-Received: from mail-wg0-f44.google.com ([74.125.82.44]:41430) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YDwD3-0001qn-Aq for 19466@debbugs.gnu.org; Wed, 21 Jan 2015 09:24:42 -0500 Original-Received: by mail-wg0-f44.google.com with SMTP id z12so6421299wgg.3 for <19466@debbugs.gnu.org>; Wed, 21 Jan 2015 06:24:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=p7luDdvEQ81UIaTLmZTJwJGO15lC9Csi3exp9d6akaI=; b=i9pjDPuRGxdc/IsHSrLoynKJOX217ajRI/t8pkXarCc67VSOWKmIoQc77EsImIb8m6 5kP/ceVwPuHNN72L3Cun9mceRshBR39fDlCidQ2qHklssP99pKNKCwNAf0DcYGJ1vf47 aPP76cbyXv3xC6TkPaLmom1a9Qbo7xxrJXimtfj6VRlCKeb6xygnAeCVRsYoIljCOWdB VSe/3Je4RlU+OsSRyB0Bf0yLM2QwA1Gb9voKhVW8oy5FtbNE4Z3UiVJG3z4QpC5rT69l ao0nYqaveM65U/FIorw0iifbDkje/SbFgkQrZ3G21JNoJHQ7T6UJMXPKNY0tskqnLGMA 6VMw== X-Received: by 10.180.91.109 with SMTP id cd13mr56804989wib.46.1421850275679; Wed, 21 Jan 2015 06:24:35 -0800 (PST) Original-Received: from [192.168.1.3] ([82.102.93.54]) by mx.google.com with ESMTPSA id gl1sm7491929wib.13.2015.01.21.06.24.34 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 21 Jan 2015 06:24:35 -0800 (PST) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:33.0) Gecko/20100101 Thunderbird/33.0 In-Reply-To: <54BF843E.10907@gmx.at> 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:98541 Archived-At: On 01/21/2015 12:49 PM, martin rudalics wrote: > The idea to do it via the KILL argument is good. I think some > doc-strings are bad. For example, instead of > > (defvar-local xref--selected nil > "t if the current buffer has ever been selected. > Used for temporary buffers.") > > I'd say something like > > (defvar-local xref--current nil > "Non-nil if this buffer was current once while finding xrefs.") "current" would be good, but "while finding xrefs" is iffy: we actually try to ignore instances of buffers being current while we display them (see xref--inhibit-mark-selected). > And for `xref-quit' I'd describe the standard behavior first and the > KILL behavior afterwards. Would you like to suggest a specific wording? > Also I'm not sure it it's just cosmetics but > shouldn't the > > (pcase-dolist (`(,buf . ,win) history) > (when (and (window-live-p win) > (eq buf (window-buffer win))) > (quit-window nil win))) > > precede the > > (when kill > (let ((xref--inhibit-mark-selected t) > kill-buffer-query-functions) > (dolist (buf xref--temporary-buffers) > (unless (buffer-local-value 'xref--selected buf) > (kill-buffer buf))) > (setq xref--temporary-buffers nil))) > > part? Probably, but there's likely not much difference at the moment. xref doesn't pop any new windows, so we shouldn't miss on deleting those when quitting temporary buffers. > I can't test it currently because I always get > > Debugger entered--Lisp error: (args-out-of-range "" 0) > help-function-arglist(#[257 "\300\207" ["(No location)"] 2 "(No > location)\n\n(fn ##)"] preserve-names) > eieio--defmethod(xref-location-group nil xref-bogus-location #[257 > "\300\207" ["(No location)"] 2 "(No location)\n\n(fn ##)"]) I'm sure Someone(tm) will fix that right away. :) > > xref-goto-xref calls xref-quit without the KILL argument, so the > temporary buffers are not cleared if you make a choice and press RET. > > You can redisplay the *xref* buffer and provide the KILL there. You mean, for the user to switch to the buried xref buffer, then press C-u q? That's quite a few keypresses. > >> previous-/next-history-element > > > > Not sure what these are. > > Something like typing M-. doing something else and typing M-. again. At > this time up/down should get you the next/previous history elements of > your xref searches. You mean in the current interface? I'm confused. > > debugger-mode should probably set both relevant vars to the same > values as emacs-lisp-mode. help-mode and Custom-mode - maybe too, > although they might use some custom logic. > > > > In Info-mode, xref-find-function could use the index and the search > functionality. > > Will there be a canonical way to add these? I meant that xref-identifier-completion-table-function would return identifiers from the index, and xref-find-function would delegate to the search functionality. With xref, we already sorta have both as features (C-u M-x xref-find-definitions and M-x xref-find-apropos).