简体   繁体   中英

How to navigate to erlang function in emacs by name?

I use emacs-mode. How can I navigate to function definition by name? Emacs has "imenu-add-to-menubar" command but it's not convenient way because I have to select function name from menu.

Thank you!

You could use Mx imenu directly—it works only within the current file, though. I bind it to Super-i in my .emacs with:

(global-set-key [(super ?i)] 'imenu)

Distel package has erl-find-source-under-point function, that is bound to M-. key You can read more about work with Erlang from Emacs in my article

Erlang is one of the many languages supported by tags . The Erlang docs show that you just build the tags file with:

find . -name "*.[he]rl" -print | etags -

Once you have a TAGS file, you just use M-. , which calls ' find-tag . This enables jumping to a function name from anywhere .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM