[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to define xref-find-definitions for a new mode?
From: |
Eli Zaretskii |
Subject: |
Re: How to define xref-find-definitions for a new mode? |
Date: |
Sat, 09 Jun 2018 12:48:15 +0300 |
> From: Marcin Borkowski <mbork@mbork.pl>
> Cc: help-gnu-emacs@gnu.org
> Date: Sat, 09 Jun 2018 11:10:22 +0200
>
> Thanks. Are there other places I could look into, like xref
> implementation for a concrete language?
In the sources for the respective languages, notably Lisp. Search for
"xref-".
> > (Btw, doesn't it already work? Etags is an existing back-end for
> > Xref, and 'etags' the program already supports TeX and its
> > derivatives, so it is able to create TAGS tables for LaTeX files.)
>
> Well, possibly, but I'd like it to work like for Elisp or JavaScript,
> without a TAGS table.
Is this likely to happen? Lisp and JavaScript know where to find
functions and variables because they keep that information as part of
defining them. I don't think TeX does anything similar, does it?
> Also, I want it to go to \label when on \ref, to \bib / \bibitem
> when on \cite etc.
Are you sure it doesn't work already? E.g., if \label is tagged, then
"M-." on the tag's name at \ref should go to the label's definition.
- How to define xref-find-definitions for a new mode?, Marcin Borkowski, 2018/06/09
- Re: How to define xref-find-definitions for a new mode?, Eli Zaretskii, 2018/06/09
- Re: How to define xref-find-definitions for a new mode?, Marcin Borkowski, 2018/06/09
- Re: How to define xref-find-definitions for a new mode?,
Eli Zaretskii <=
- Re: How to define xref-find-definitions for a new mode?, Marcin Borkowski, 2018/06/10
- Re: How to define xref-find-definitions for a new mode?, Eli Zaretskii, 2018/06/11
- Re: How to define xref-find-definitions for a new mode?, Marcin Borkowski, 2018/06/15
- Re: How to define xref-find-definitions for a new mode?, Eli Zaretskii, 2018/06/15
- Re: How to define xref-find-definitions for a new mode?, Marcin Borkowski, 2018/06/15
- Re: How to define xref-find-definitions for a new mode?, Dmitry Gutov, 2018/06/12