[Qgis-developer] Header files order

Martin Dobias wonder.sk at gmail.com
Sun Apr 21 00:50:47 PDT 2013

On Sat, Apr 20, 2013 at 10:18 AM, Radim Blazek <radim.blazek at gmail.com> wrote:
> do you agree with that order (least specific -> most specific) extend
> for system etc (each section sorted lexically):
> * system headers
> * standard libraries headers
> * qt headers
> * other 3rd party libraries headers
> * qgis headers

Personally I do not care so much about the order of the sections. I
would say we should just:
1. #include the corresponding header file first (e.g. for abc.cpp the
first include should be #include "abc.h") to ensure that the header
file does not have some hidden include dependencies
2. keep each section sorted

Anyway the least specific -> most specific order makes more sense than
the opposite order.


More information about the Qgis-developer mailing list