Hello dear C and C++ users
We are glad to bring you new features and improvements.
You get much less false positives for all path-sensitive rules for both C and C++.
We improved our execution path-sensitive engine by removing most false positives that were raised on infeasible paths (logical inconsistencies in the execution path and program state).
On top of that, you get a few more rules, mostly continuing on C++20.
- S6234: “auto” should be used to store a result of functions that conventionally return an iterator
- S6223 [C++20]: Result of the standard remove algorithms should not be ignored
- S6222 [C++20]: “[[nodiscard]]” attributes on types should include explanations
- S6228 [C++20]: “std::has_single_bit” should be used to test if an integer is a power of two
All this is already available on SonarCloud.io and will be available with SonarQube 9.1 starting from Developer Edition.