How to jump back from find-tag in Emacs

6.8k Views Asked by At

I'm using find-tag function M-. to jump to function definition, how can I jump back to previous location?

1

There are 1 best solutions below

2
On BEST ANSWER

M-. calls xref-find-definitions in recent versions of Emacs. I use M-,, which is bound to xref-pop-marker-stack, to return back. You can even use it to recursivelly return from a deeper search.

In older Emacs versions, M-. was bound to find-tag which worked similarly. The inverse function was pop-tag-mark by default bound to M-*.