emacsautocompleteetagcedetemacs-semantic

Is it possible to get Semantic (emacs) to visit all files automatically?


From what I can tell from the docs, semantic works by slowly building up an idea of what's in your project by analysing each file (and possibly its neighbours) as you visit them. This is too slow. I'd like to just have it visit all the files in my project. Is there an easy way to do this? Having to visit hundreds of files before I can get decent autocomplete working seems crazy.

I've also got a etags file generated. Can I leverage that somehow?

Relevant info: Emacs on Windows, version 23.2.1


Solution

  • CEDET will automatically parse all files references via #include statements, thus providing pretty good completion. If you are looking to jump around in your files, you can setup CEDET to use GNU Global, CScope, to provide the database needed to move around a project by tag name.

    In addition, CEDET will parse your headers and nearby files in idle time, so eventually you will have a complete database of all your local files in about 10 minutes after using the tools the first time. You can speed it up by opening a file, and calling

     M-x semantic-debug-idle-work-function
    

    which will go off and do that stuff without waiting.