[all-commits] [llvm/llvm-project] c1dc91: [clang-tidy] Correct sizeof/alignas handling in mi...
Piotr Zegar via All-commits
all-commits at lists.llvm.org
Sat Jul 1 09:24:47 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c1dc914a8ca240650d7411d25c75ad7e2a5974e9
https://github.com/llvm/llvm-project/commit/c1dc914a8ca240650d7411d25c75ad7e2a5974e9
Author: Piotr Zegar <me at piotrzegar.pl>
Date: 2023-07-01 (Sat, 01 Jul 2023)
Changed paths:
M clang-tools-extra/clang-tidy/misc/RedundantExpressionCheck.cpp
M clang-tools-extra/docs/ReleaseNotes.rst
M clang-tools-extra/test/clang-tidy/checkers/misc/redundant-expression.cpp
Log Message:
-----------
[clang-tidy] Correct sizeof/alignas handling in misc-redundant-expression
Fixed issue with the comparison of UnaryExprOrTypeTraitExpr
objects in which only the argument type was checked, without
considering the kind of expression. This led to false positives when
using sizeof(x) and alignof(x) expressions, as only the
comparison x = x was performed without checking if sizeof
was equal to alignof.
Fixes: https://github.com/llvm/llvm-project/issues/63096
Reviewed By: Izaron
Differential Revision: https://reviews.llvm.org/D152713
More information about the All-commits
mailing list