Hi David,

Thanks for your response but unfortunately, I don't think it's a simple matter of switching to c++ mode (which I systematically do when editing .inl files). I'll perhaps have to take a look on how cedet works to build it's semantic representation of a project but since my .inl itself has no include directives, it looks like cedet might be confused as to where to look for completion symbols.(obviously, since the .inl are included by their corresponding header files they themselves cannot use an include directive since it will cause a dependency loop). As I've said this file separation scheme is recommended when using templates and I haven't tested if it's actually my templates declaration that are at the source of this problem. I'll do some further tests and post the results on this list.

I'd be really glad if anyone feels like testing a similar setup and report whether or not it's working for them.



On Wed, Oct 12, 2011 at 8:05 AM, cedet-semantic-request@lists.sourceforge.net <cedet-semantic-request@lists.sourceforge.net> wrote:
Send cedet-semantic mailing list submissions to

To subscribe or unsubscribe via the World Wide Web, visit
or, via email, send a message with subject or body 'help' to

You can reach the person managing the list at

When replying, please edit your Subject line so it is more specific
than "Re: Contents of cedet-semantic digest..."

---------- Forwarded message ----------
From: David Engster <deng@randomsample.de>
To: "cedet-semantic@lists.sourceforge.net" <cedet-semantic@lists.sourceforge.net>
Date: Tue, 11 Oct 2011 14:24:12 -0400
Subject: Re: [cedet-semantic] Code completion on .inl files (c++)
Mathieu Béliveau writes:
> I guess most of you know that when using templates in a class
> declaration in c++, it's considered "good style" to separate your
> class declaration and it's implementation in two files. Since there
> are some restriction as to where you can place your methods
> definitions (especially for the constructor) - namely: they should be
> part of your header file, a somewhat best practice is to add an
> include to the .inl file implementing your class at the very bottom of
> your header file. Now it seems that this particular scheme does work
> with cedet's standard code completion. Is there anything I can
> configure to make it work (does it even recognize .inl files as valid
> c++ files?)

Well, Emacs has to switch to C++ mode when you load those files, so
something like

(add-to-list 'auto-mode-alist '("\\.inl\\'" . c++-mode))

should do the trick?