After skimming through a number of header files, I notices that although code used in a specific header seems to abide by the same formatting and style, there's no consistency across different files. It's definitely a consequence of many users contributing to the repository (which is a good thing), but at the same time, it may lead to some issues down the path the project will go.
Examples include:
size_t
instead of std::size_t
,int
instead of AK::u32
(or some other width that's required in a context),auto
in global declarations, e.g. inline constexpr auto hash_length { 64 };
. Though auto
has some advantage in legibility and maintainability when the type in question depends on some additional parameters (like templates), in most cases it makes little difference.I'm not knowledgeable in how much clang-format
and clang-tidy
can do, but I can imagine those points may be difficult to be enforced by linters like that. I don't suggest taking a specific path, but I think it would be worthwhile to add some guidelines regarding those things. If not explicitly in a document, then during code review.
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too