Namespace support
Brought to you by:
dhiebert
Hi. I'm new to ctags. Is there any way to define namespaces, so I can jump to correct definition in my editor? I did try to generate tags for a few languages (php, java, clojure) but it seems that namespaces are not supported?
I have also found that it's possible to add language using regexps (https://gist.github.com/xzj/1518834) but it doesn't seems to be possible to specify namespaces using them?
Is there any way to define that class/function... inside namespace or work in progress?
Feature adding namespace to regex parser is quite interesting idea.
How do you think adding push-namespavce and pop-namespace long flags?
--regex-clojure=/([ \t]ns[ \t]+([-[:alnum:]+!_:\/.?]+)/\1/n,namespace/{push-namespace}
For --extra=+q we may need something like
--qualified-format-clojure=%s/%s
cork API I proposed at https://github.com/fishman/ctags/pull/296 can be used as a building block for implementing the future. However, to handle nested namespaces, one more building block is needed: https://github.com/geany/geany/blob/master/tagmanager/ctags/nestlevel.c
If you want a parser for clojure, see https://github.com/fishman/ctags/blob/master/parsers/clojure.c . You can add good things in https://gist.github.com/xzj/1518834 to it.