Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
common: Remove redundant includes - 3 #15204
But now I have to fix this again back for some, because under FreeBSD/Clang these includes need to be the way they are...
First: On of the rules in the code-guides Ceph suggests to use is that the order of includes is:
As a result of this reversal pid_t is not available in CLANG because it comes from
And error nummers in FreeBSD specifically live in errno.h
So I'm having a rather hard time figuring out if compiles are now breaking due to these "fixes"of due to other things where Clang is just genearly unhappy.
Sorry for the rant, but I'm rather sad at the moment.
Frustration is/was rather limited, and already gone...
Changes are not that major, but it is more figuring out what are the essentials.
@wjwithagen : Sorry to hear that it breaks in FreeBSD. I think the best way to optimize the includes is to proceed fixing them in FreeBSD too.
@liewegas @tchaikov : While doing these series of PRs, which was initiated by @badone, I was careful not to remove the includes under
The order of the includes was not strictly followed in many files. I have found instances where it starts with Standard Includes, then comes local includes and then Standard Includes again. Sometimes it is mixed too. So it was confusing. However I have put an effort to group them together.
@wjwithagen By the way, please note that the order was not changed in ipaddr.cc