[libvirt] RFC: Coding style: require alphabetical header file sorting
John Eckersberg
jeckersb at redhat.com
Mon Dec 3 17:01:31 UTC 2012
"Daniel P. Berrange" <berrange at redhat.com> writes:
> Thus far we only have one rule about header files, #include <config.h>
> must be first in all .c files. I'm wondering if it is time to introduce
> some new rules
>
> - All system headers must be grouped to preceed all local headers
> - All system headers must be sorted within their group
> - All local headers must be sorted within their group
>
> This will require updating pretty much every single source and header
> file in the tree. Of course it will need a new syntax check rule to
> validate this too. Since fixing them is a serious amount of work,
> I was wondering about people's opinions on this ?
>
> The goal is just standardization to make code a little more readable.
>
> Daniel
I've recently been trying to find my way around the codebase for the
first time, +1 to this. In fact just this morning I was reading the
hacking guidelines trying to find this, because I expected it to be
there.
John
More information about the libvir-list
mailing list