4 Commits

Author SHA1 Message Date
David Rivera
3c1053811e
Revert "[clang-tidy] Improve integer comparison by matching valid expressions outside implicitCastExpr" (#143944)
Reverts llvm/llvm-project#134188
related: https://github.com/llvm/llvm-project/issues/143927
2025-06-12 14:33:06 -04:00
David Rivera
e65d323166
[clang-tidy] Improve integer comparison by matching valid expressions outside implicitCastExpr (#134188)
Aims to fix #127471
Covered the edge case where an int expression is not necessarily
directly wrapped around an 'ImplicitCastExpr' which seemed to be a
requirement in 'use-integer-sign-comparison.cpp' check to trigger.

**For instance**:

```cpp
#include <vector>

bool f() {
  std::vector<int> v;
  unsigned int i = 0;

  return i >= v.size();
}
```
2025-06-10 10:57:11 +03:00
qt-tatiana
aa580c2ec5
[clang-tidy] Add EnableQtSupport option to modernize-use-integer-sign-comprison (#122127)
- add an option `EnableQtSupport`, that makes C++17 `q20::cmp_*`
alternative available for Qt-based applications.
2025-01-22 23:30:53 +08:00
qt-tatiana
8b63bfbf6d
[clang-tidy] Create a check for signed and unsigned integers comparison (#113144)
- modernize-use-integer-sign-comparison replaces comparisons between
signed and unsigned integers with their safe C++20 ``std::cmp_*``
alternative, if available.
2024-12-12 00:38:05 +08:00