[cfe-dev] clang indexing server for emacs?

Eran Ifrah eran.ifrah at gmail.com
Sun Oct 31 00:00:18 PDT 2010


Actually I am working on something similar.
I started integrating clang code-completion in the IDE that I have
developed and grown quite mature (open source, cross platform
www.codelite.org)

However, currently it is used *inside* the IDE and not as an external
service. But 'extracting' it should be an easy task.

The current state of the 'completion' is that is capable of providing
a completion list by executing clang from the command line. I am at a
point right now where I am implementing the cache based on the
pre-compiled header:
When a file is opened inside the editor, I am extracting all the
include statements from the file and forming a 'pre-compiled' header
which is being compiled in the background.
This file is then used with clang with the '-include-pch' switch to
boost the completion speed.

It looks promising (talking speed wise), but still a bit slower than
the current code completion - but I think its worth the effort.

Developing a custom protocol is an easy task (I already got all the
infrastructure required for this (Windows Named pipe/Domain Sockets
etc)
The only thing I am not sure that I can get from the 'clang' atm
(*without* linking against libclang) is the location of the match

If I had the location, of the match, I could also parse any doxy
comment on top of that method and return it along with the match (this
is how the current code completion works)

Any ideas whether this is feasible? or must I link against libclang?

On Thu, Sep 2, 2010 at 12:32 PM, Bruce Stephens
<bruce.r.stephens at gmail.com> wrote:
> "Ramneekhanda-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org"
> <ramneekhanda-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org> writes:
>
>> Thanks Doug for clearing up.. So basically am on my own ;)
>
> In the sense that it's quite possible that nobody's working on something
> similar, sure.  However, once you've got something that shows promise
> I'm sure you'll get interest.  It's not a million miles away from eclim
> (vim using eclipse as a server), for example, so people who dislike
> eclipse but like the general idea might well be interested.
>
> [...]
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
>



-- 
Eran Ifrah
Cross platform, open source C++ IDE: http://www.codelite.org




More information about the cfe-dev mailing list