Is the Java – VIM editor smart?
I program in C or Java So I want to use the VIM editor because it is very flexible I heard I can configure the VIM editor to go
>From object to definition > from function to definition > from class name to definition
We have any professional VIM er. Can you tell me how to configure VIM? Thank you in advance
PS: if the reader will consider that this problem has nothing to do with programming, I will say that it is to improve the programming speed So this is a help for programmers So please don't close this issue
Edit: I also want to know how VIM works with code completion, and can VIM prompt a list of methods available for some objects? If so, I wonder how to configure these options?
Solution
You are looking for ctags and tag / tags files Ctags (I recommend exuberant ctags) is a program that scans the identifiers of source files and creates a file that indexes them You can then use ^] to jump to the definition of the tag under the cursor
Additional details may be needed to tell VIM how to find the tag file; I don't know what they are But that's the general idea - run the source code of ctags and use ^]
Or, you might want to see GNU global It's more complicated, but ctags will do what you describe