2 ms·
In the chromium repository, the use of angle brackets in #include statements is banned -- they only use double quotes. They also don't use any system headers pe
by plq 2y ago
In the chromium repository, the use of angle brackets in #include statements is banned -- they only use double quotes. They also don't use any system headers per se since their flavor of clang comes with their flavor of libcpp vendored in.
So if the chromium repo is representative of the state of C++ in rest of Google, they ditched it silently like this probably because it's so natural to them :)
- RHSeeger 2y agoSo, instead of using > <> means system headers and "" means project headers (my naive understanding of the difference) they just convert everything to a project header? That seems bonkers to me. It is intentionally removing useful information.
- hoseja 2y agoHierarchy is problematic.
- rileymat2 2y agoThe main difference is how the search for the file works. “” prefers local directory before the search path, <> goes to the search path first.
- plq 2y agoFirst, here's the actual guide: https://google.github.io/styleguide/cppguide.html#Names_and_Order_of_Includes https://google.github.io/styleguide/cppguide.html#Names_and_... . Of course they still have to use stuff like #include <windows.h> but it's very very limited. They also are not removing any info -- most of it IS project headers. To me that's the actual bonkers bit :) With GCC/Clang, headers found in paths passed with -isystem are headers that are immune to compiler arguments like -Werror because they are, by definition, out of your control. In Google's case, ALL code is already checked in the project repo, including language stdlib. So none of them are system headers "per se".