Extracting the completion engine into a standalone library?

Kevin Funk kfunk at kde.org
Thu Nov 17 09:20:21 UTC 2016


On Saturday, 5 November 2016 00:42:34 CET Samuel DA MOTA wrote:
> Hi Guys,
> 
> First let me thank you for your awesome work on kdevelop.
> 
> I have a kind of feature request about Kdevelop.
> 
> When it comes to C++, I consider that kdevelop has the best
> auto-complete and cross-reference navigation of the IDEs out there. I
> tried rtags [1], irony-mode [2], YouCompleteMe [3] and QtCreator, and
> they all seem to fall short compared to your new clang-based C++
> parser/indexer.

Thanks!

> I was wondering if it would be possible to consider moving the
> kdevelop/languages/clang folder "out" of kdevelop into a kind of
> standalone library. I believe there are lots of duplicated effort in
> the community maintaining four different indexers, all clang-based.
> And if the people behind the others could instead pick up yours and
> contribute to it, I believe everyone would then profit from it. Do you
> guys think it would be possible to do so? I admit the main reason for
> my request if that I would like to keep using my favourite $EDITOR and
> enjoy the Kdevelop C++ user experience.

I'm afraid it's not an easy task. Certainly possible, though.

All of our work on the Clang language support plugin is based on 
KDevPlatform's Definition-Use Chain infrastructure, which is basically a 
container format for storing contexts, definitions and uses of entities. If 
you were willing to, you could of course base your favorite $EDITOR on DUChain 
and pull out information from there.

The DUChain is language agnostic, all language plugins in KDevelop use it. The 
shell itself only uses the DUChain API, it doesn't know about the underlying 
individual languages. So, in a sense, it's very similar to the design 
Philosopy of ycmd code-completion & code-comprehension server.

Here's more information:
  https://api.kde.org/extragear-api/kdevelop-apidocs/kdevplatform/language/
duchain/html/duchain-design.html
  https://api.kde.org/extragear-api/kdevelop-apidocs/kdevplatform/language/
duchain/html/Using.html

HTH,
Kevin

> [1] https://github.com/Andersbakken/rtags
> [2] https://github.com/Sarcasm/irony-mode
> [3] https://github.com/Valloric/ycmd
> 
> Kindest regards


-- 
Kevin Funk | kfunk at kde.org | http://kfunk.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 163 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20161117/876fe31f/attachment.sig>


More information about the KDevelop-devel mailing list