What are the plans with CamelCase includes?

Christoph Cullmann cullmann at absint.com
Thu Jan 2 10:42:57 UTC 2014


> > This wasn't intended I guess. When the discussion about include files
> > occured the consensus was to have everything in a single directory (the
> > camel cased one).
> 
> OK I initially thought it was so the implementation of ecm_generate_headers
> is
> simpler (lowercase everything), but in fact that's not it, it lowercases
> individual parts explicitely.
> 
> In fact if we only use a camelcase header, the CMakeLists.txt code is even
> simpler because the INSTALL(DIRECTORY) line will install both kinds of
> headers. Which removes the need for the KCoreAddons_HEADERS variable
> altogether.
> See attached patch.
> 
> Aleix, any objections?
> 
> I'll script this over all modules, if not.
> 
> I think the reasoning might have been: so that people can include
> <kcoreaddons/krandom.h>. But I'm not sure we even want to allow that.
> It breaks the whole idea that "the install dir is transparent to the apps",
> the idea of compile-time errors (header not found) when not linking to the
> appropriate lib, and of course it will break when we move stuff around for
> kf6.
> Well, we can't physically prevent people from writing #include
> <KCoreAddons/krandom.h> or <KCoreAddons/KRandom>, but the fact that the first
> one looks weird will at least reduce the chances of people doing that :)
Hmm,

just a question for the case, that we have a namespace, like KTextEditor.

At the moment we install (e.g. for KTextEditor::View):

KTextEditor/View

and

ktexteditor/view.h

Will that change still make that possible?

Greetings
Christoph

-- 
----------------------------- Dr.-Ing. Christoph Cullmann ---------
AbsInt Angewandte Informatik GmbH      Email: cullmann at AbsInt.com
Science Park 1                         Tel:   +49-681-38360-22
66123 Saarbrücken                      Fax:   +49-681-38360-20
GERMANY                                WWW:   http://www.AbsInt.com
--------------------------------------------------------------------
Geschäftsführung: Dr.-Ing. Christian Ferdinand
Eingetragen im Handelsregister des Amtsgerichts Saarbrücken, HRB 11234


More information about the Kde-frameworks-devel mailing list