[chore](clang-tidy): add bugprone linters (#29521)

This PR introduces 4 bugprone linter rules to .clang-tidy, these linters found some bugs in #28965. This PR also add some comments to mute false positive reports.
This commit is contained in:
py023
2024-02-05 15:55:54 +08:00
committed by yiguolei
parent 7840e7cb81
commit 4b42156fc0
8 changed files with 27 additions and 18 deletions

View File

@ -62,7 +62,7 @@ ColumnPtr wrap_in_nullable(const ColumnPtr& src, const Block& block, const Colum
if (const auto* nullable = assert_cast<const ColumnNullable*>(elem.column.get());
nullable->has_null()) {
const ColumnPtr& null_map_column = nullable->get_null_map_column_ptr();
if (!result_null_map_column) {
if (!result_null_map_column) { // NOLINT(bugprone-use-after-move)
result_null_map_column = null_map_column->clone_resized(input_rows_count);
continue;
}