all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Dmitry Gutov <dgutov@yandex.ru>
Cc: emacs-devel@gnu.org
Subject: Re: xref-query-replace
Date: Sat, 09 Jan 2016 19:08:02 +0200	[thread overview]
Message-ID: <83y4byn0jx.fsf@gnu.org> (raw)
In-Reply-To: <569139D1.5040907@yandex.ru> (message from Dmitry Gutov on Sat, 9 Jan 2016 19:48:17 +0300)

> Cc: emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> Date: Sat, 9 Jan 2016 19:48:17 +0300
> 
> > (Should xref pick up symbols inside comments?)
> 
> etags does, apparently. Why else would xref show them?

I thought xref didn't use etags to deduce the symbol at point, but if
I was mistaken, so be it.

> In general, I'd say "yes", for "find references" or "find regexp" 
> results. But not for "find definitions".

Then maybe we should do something about this.

> > What am I doing wrong?
> 
> You're calling the "find definitions" command, not the "find references" 
> or "find regexp".
> 
> xref-find-definitions returns a set of xrefs which we don't consider to 
> be a set of "matches", currently.

The results of the two commands look very similar, and both buffers
are under XREF mode.  So I think this distinction is very confusing.
At the very least, 'r' in the buffer where the command will do nothing
but barf should not invoke the command.

> While the English language may frown on this, I think it's good that
> xref-query-replace doesn't work across the "find definitions"
> result, because if it did, you'd end up with a codebase in which the
> function's (definition is|definitions are) renamed, but all its
> usages keep referring to the old name.

It's up to the user to decide whether this makes sense, I think.  So
we could ask her for confirmation, and if given, could proceed anyway.

> Try starting with xref-find-references (bound to M-?).

When I do that from *scratch*, I get this unfriendly error message:

  Customize ‘semantic-symref-filepattern-alist’ for lisp-interaction-mode

Can we please make this work by default from *scratch*?

Thanks.



  reply	other threads:[~2016-01-09 17:08 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-09 15:28 xref-query-replace Eli Zaretskii
2016-01-09 15:50 ` xref-query-replace Dmitry Gutov
2016-01-09 16:36   ` xref-query-replace Eli Zaretskii
2016-01-09 16:48     ` xref-query-replace Dmitry Gutov
2016-01-09 17:08       ` Eli Zaretskii [this message]
2016-01-09 20:05         ` xref-query-replace Dmitry Gutov
2016-01-09 20:10           ` xref-query-replace Eli Zaretskii
2016-01-09 20:22             ` xref-query-replace Dmitry Gutov
2016-01-09 20:27               ` xref-query-replace Eli Zaretskii
2016-01-09 20:35                 ` xref-query-replace Dmitry Gutov
2016-01-09 20:40                   ` xref-query-replace Eli Zaretskii
2016-01-09 20:46                     ` xref-query-replace Dmitry Gutov
2016-01-10  3:32                       ` xref-query-replace Eli Zaretskii
2016-01-10  3:54                         ` xref-query-replace Dmitry Gutov
2016-01-10 15:52                           ` xref-query-replace Eli Zaretskii
2016-01-10 16:02                             ` xref-query-replace Dmitry Gutov
2016-01-19  0:11                             ` xref-query-replace John Wiegley
2016-01-19  0:19                               ` xref-query-replace Dmitry Gutov
2016-01-19  0:28                                 ` xref-query-replace John Wiegley
2016-01-19  0:35                                   ` xref-query-replace Dmitry Gutov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83y4byn0jx.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=dgutov@yandex.ru \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.