Commit 847c6d98 authored by Ben Noordhuis's avatar Ben Noordhuis
Browse files

tools: cpplint: fix up build/include_order rule

Change the build/include_order rule to match our preference:
project headers before system headers.

The rationale is that system headers before project headers makes it
easy to slip in bugs where a project header that requires a definition
from a system header, forgets to include the system header but still
compiles because the source files that include the project header
coincidentally include the system header too.

A good example is the size_t type. A project header file that needs the
definition of size_t should include stddef.h but forgetting to do so
will probably go unnoticed for a long time because almost every other
system header includes stddef.h (either directly or indirectly) and
almost every source file includes one or more system headers.

Ergo, project headers before system headers. It's a good thing.
parent 58159e30
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment