[PATCH] Re: Moving stuff for include-completion to kdevplatform

Milian Wolff mail at milianw.de
Mon Aug 3 21:39:55 UTC 2009


Milian Wolff, 03.08.2009:
> Milian Wolff wrote:
> > Hi again :)
> >
> > Cpp contains a lot of stuff which other language plugins could take
> > advantage of. Right now I want to implement autocompletion for includes
> > in PHP.
> >
> > What I think would be useful:
> > - moving cpp/includeitem.h to kdevplatform:
> >   * would language/codecompletion be a sane place for that? Esp.
> > considering that this header is used e.g. in some Cpp specific quickopen
> > stuff. Maybe utils is a better place?
> >
> > - moving IncludeFileCompletionItem from cpp/codecompletion/items.h:
> >   * this should really go to language/codecompletion.
> >   * except for the execute() method it looks language independent. It
> > should just be pure abstract or virtual.
> >
> > - moving IncludeNavigationContext to kdevplatform:
> >   * again - where to put this? language/util ?
> >   * we also should take a look at what can be reused and what not. Esp.
> > the environment file info (number of declarations etc.) should be
> > language dependent. Macros e.g. are Cpp specific. Just having the html()
> > method virtual should be enough imo so it can be subclassed for language
> > where required.
> >   * pickContextWithData() contains the lines:
> >
> >     if(!ctx->parsingEnvironmentFile() ||
> > ctx->parsingEnvironmentFile()->type() != KDevelop::CppParsingEnvironment)
> >       continue;
> >
> >     so that generic IncludeNavigationContext has to be a template?
> >
> >
> > Everything else should imo stay as it is and be reimplemented on a
> > per-lang basis. Esp. getting reasonable list of include files is imo
> > highly lang dependent. For PHP it has to work for remote projects, maybe
> > honor a per-project setting for custom include paths etc. etc.
> >
> > I can work on the stuff above, but want some input first so I don't mess
> > things up...
>
> Here's a patch. Please review. I'll continue hacking on the PHP support
> and will see whether the stuff works well.

Aaaaaand the patch...... narf :-/
-- 
Milian Wolff
mail at milianw.de
http://milianw.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: includecompletion_to_kdevplatform.patch
Type: text/x-patch
Size: 34454 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20090803/d3ae1357/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20090803/d3ae1357/attachment.sig>


More information about the KDevelop-devel mailing list