@@ -130,6 +149,12 @@ static const llvm::StringSet<> TypeTraits = {
"result_of",
"invoke_result",
"type_identity",
+"tuple_element",
vbvictor wrote:
There are no tests that will handle recursive traits (AFAIK there weren't any
recursive trait i
https://github.com/vbvictor requested changes to this pull request.
Thank you for the patch!
Could you please add tests with new traits from C++20, 23, 26 standards to make
sure we get warning. You will need to change `-std=c++17` to
`-std=c++17-or-later` in tests.
https://github.com/llvm/llvm
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147074
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147074
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147048
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -144,7 +144,8 @@ TaggedUnionMemberCountCheck::getNumberOfEnumValues(const
EnumDecl *ED) {
if (EnableCountingEnumHeuristic && LastEnumConstant &&
isCountingEnumLikeName(LastEnumConstant->getName()) &&
- (LastEnumConstant->getInitVal() == (EnumValues.size() - 1)
@@ -0,0 +1,260 @@
+//===--- AvoidPlatformSpecificFundamentalTypesCheck.cpp - clang-tidy
--===//
+//
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM
Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Ap
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/147074
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor approved this pull request.
https://github.com/llvm/llvm-project/pull/147197
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -174,6 +176,21 @@ void QualifiedAutoCheck::registerMatchers(MatchFinder
*Finder) {
void QualifiedAutoCheck::check(const MatchFinder::MatchResult &Result) {
if (const auto *Var = Result.Nodes.getNodeAs("auto")) {
+if (RespectOpaqueTypes) {
vbvictor wr
@@ -0,0 +1,239 @@
+// RUN: %check_clang_tidy %s readability-qualified-auto %t --
-config="{CheckOptions: [\
vbvictor wrote:
Please write tests in existing `qualified-auto.cpp`. You can have multiple RUN
commands in one file.
https://github.com/llvm/llvm-projec
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147060
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor requested changes to this pull request.
Please, describe your option in check docs.
I find option name a little unclear, I don't encounter "opaque" term ofter,
maybe `DesugarTypes` is better?
https://github.com/llvm/llvm-project/pull/147060
_
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147060
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147060
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147060
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
> In that case the default should be true though right?
Yes, that would be just as current default behavior.
https://github.com/llvm/llvm-project/pull/147060
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.o
vbvictor wrote:
I'd suggest marking it `[[deprecated]]` for now and removing it completely
after 2 releases of LLVM (AFAIK that's usual procedure).
I've
[searched](https://sourcegraph.com/search?q=context:global+::clang::ast_matchers::internal::makeMatcher+-file:.*Matchers%5C.h%24+-file:.*ASTM
@@ -0,0 +1,508 @@
+#include "clang/Analysis/Analyses/LifetimeSafety.h"
+#include "clang/AST/Decl.h"
+#include "clang/AST/Expr.h"
+#include "clang/AST/StmtVisitor.h"
+#include "clang/AST/Type.h"
+#include "clang/Analysis/AnalysisDeclContext.h"
+#include "clang/Analysis/CFG.h"
+#inc
@@ -0,0 +1,13 @@
+#ifndef LLVM_CLANG_ANALYSIS_ANALYSES_LIFETIME_SAFETY_H
vbvictor wrote:
I think this file has a "Header" with `Part of the LLVM Project ...` and a
little in-place description like any other file in `Analyses/` dir. Same to
.cpp file.
https://g
@@ -0,0 +1,508 @@
+#include "clang/Analysis/Analyses/LifetimeSafety.h"
+#include "clang/AST/Decl.h"
+#include "clang/AST/Expr.h"
+#include "clang/AST/StmtVisitor.h"
+#include "clang/AST/Type.h"
+#include "clang/Analysis/AnalysisDeclContext.h"
+#include "clang/Analysis/CFG.h"
+#inc
@@ -0,0 +1,508 @@
+#include "clang/Analysis/Analyses/LifetimeSafety.h"
+#include "clang/AST/Decl.h"
+#include "clang/AST/Expr.h"
+#include "clang/AST/StmtVisitor.h"
+#include "clang/AST/Type.h"
+#include "clang/Analysis/AnalysisDeclContext.h"
+#include "clang/Analysis/CFG.h"
+#inc
@@ -0,0 +1,508 @@
+#include "clang/Analysis/Analyses/LifetimeSafety.h"
+#include "clang/AST/Decl.h"
+#include "clang/AST/Expr.h"
+#include "clang/AST/StmtVisitor.h"
+#include "clang/AST/Type.h"
+#include "clang/Analysis/AnalysisDeclContext.h"
+#include "clang/Analysis/CFG.h"
+#inc
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/142313
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,13 @@
+#ifndef LLVM_CLANG_ANALYSIS_ANALYSES_LIFETIME_SAFETY_H
vbvictor wrote:
```suggestion
#ifndef LLVM_CLANG_ANALYSIS_ANALYSES_LIFETIMESAFETY_H
```
Underscore should be path separators,
https://llvm.org/docs/CodingStandards.html#header-guard.
https
https://github.com/vbvictor commented:
Thank you for your work! Interested to see this feature in clang.
Left a couple of nit comments on code style.
https://github.com/llvm/llvm-project/pull/142313
___
cfe-commits mailing list
cfe-commits@lists.llvm.o
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/142313
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/142313
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
> I'm planning for an autofix of float and double since it's unambiguous what
> those types should be.
For int types, maybe I'll give 3 options for an autofix:
Fixed (int32_t)
Fast (int_fast32_t)
Least (int_least32_t)
You could make a universal option to configure autofixes. Mak
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147066
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147074
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -130,6 +149,12 @@ static const llvm::StringSet<> TypeTraits = {
"result_of",
"invoke_result",
"type_identity",
+"tuple_element",
vbvictor wrote:
I'd also suggest adding "Limitation" section in check docs. Search in docs
directory for refere
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147301
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor approved this pull request.
Could we just use `StringLiteral` without `llvm::`?
https://github.com/llvm/llvm-project/pull/147301
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/
@@ -55,7 +55,8 @@ namespace clang::tidy {
namespace {
#if CLANG_TIDY_ENABLE_STATIC_ANALYZER
-static const char *AnalyzerCheckNamePrefix = "clang-analyzer-";
+static constexpr llvm::StringLiteral AnalyzerCheckNamePrefix =
vbvictor wrote:
```suggestion
static c
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147301
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147301
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147301
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/146830
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -144,7 +144,9 @@ TaggedUnionMemberCountCheck::getNumberOfEnumValues(const
EnumDecl *ED) {
if (EnableCountingEnumHeuristic && LastEnumConstant &&
isCountingEnumLikeName(LastEnumConstant->getName()) &&
- (LastEnumConstant->getInitVal() == (EnumValues.size() - 1)
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147048
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -0,0 +1,62 @@
+.. title:: clang-tidy - misc-bool-bitwise-operation
+
+misc-bool-bitwise-operation
+===
+
+Finds potentially inefficient use of bitwise operators such as ``&``, ``|``
+and their compound analogues on Boolean values where logical operator
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/147048
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
Did any of the builders caught this, or it is some local configuration?
Asking just in case if we should create one for catching such CE's.
https://github.com/llvm/llvm-project/pull/147503
___
cfe-commits mailing list
cfe-commits@lists
vbvictor wrote:
> > Please remove unnecessary comments that tell the same as code itself,
> > speaking mostly about comments in `registerMatchers`. They mostly don't
> > give any more information that matchers themselves.
>
> To be honest, this is because I coded 98% of this with AI (except fo
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/141304
>From 7323c1b3ed55790cdab240f233113bfb1d52badb Mon Sep 17 00:00:00 2001
From: Baranov Victor
Date: Sat, 17 May 2025 18:40:54 +0300
Subject: [PATCH 1/5] [clang-tidy] Add isFriendOfClass helper function for
Pass
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/147793
>From a0fd1b04817c03685bacd70f763ef0f62dd4e425 Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Wed, 9 Jul 2025 21:00:30 +0300
Subject: [PATCH 1/2] [clang-tidy][NFC] add '.clang-tidy' config for clang-tidy
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/141304
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor created
https://github.com/llvm/llvm-project/pull/147793
Added `.clang-tidy` config as discussed in
[RFC](https://discourse.llvm.org/t/rfc-create-hardened-clang-tidy-config-for-clang-tidy-directory/87247).
Added `bugprone` checks that didn't create many warnings.
Fix
vbvictor wrote:
Added all people that participated in RFC and regular clang-tidy reviewers to
see this change.
https://github.com/llvm/llvm-project/pull/147793
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mail
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147793
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
> How about adding modernize relevant to currently used C++ standard? Also some
> of readability checks are useful.
Yes, I will add more and more checks to config. Just started with `bugprone` as
it is the most straightforward improvement.
> Please also consider top-level .cla
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/147793
>From a0fd1b04817c03685bacd70f763ef0f62dd4e425 Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Wed, 9 Jul 2025 21:00:30 +0300
Subject: [PATCH] [clang-tidy][NFC] add '.clang-tidy' config for clang-tidy
proj
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/142839
>From d9ecaedefd6d98c653affc76e375fa1f8644a0df Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Wed, 4 Jun 2025 22:29:51 +0300
Subject: [PATCH 1/4] [clang-tidy] Add new check
`llvm-prefer-static-over-anonym
vbvictor wrote:
Ping if anyone else what to review this new check.
https://github.com/llvm/llvm-project/pull/142839
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/142839
>From d9ecaedefd6d98c653affc76e375fa1f8644a0df Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Wed, 4 Jun 2025 22:29:51 +0300
Subject: [PATCH 1/3] [clang-tidy] Add new check
`llvm-prefer-static-over-anonym
vbvictor wrote:
Please make the title more detailed about what you changed excatly.
https://github.com/llvm/llvm-project/pull/147406
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -672,9 +672,15 @@ class Matcher {
DynTypedMatcher Implementation;
}; // class Matcher
-/// A convenient helper for creating a Matcher without specifying
-/// the template type argument.
+// Deduction guide for Matcher.
+template Matcher(MatcherInterface *) -> Matcher;
+
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/147301
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147197
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/147793
>From c4466d677619e6eb8ca65ed943bfb103207527c9 Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Wed, 9 Jul 2025 21:00:30 +0300
Subject: [PATCH 1/3] [clang-tidy][NFC] add '.clang-tidy' config for clang-tidy
vbvictor wrote:
Based on [carlosgalvezp](https://github.com/carlosgalvezp)'s comment in
https://github.com/llvm/llvm-project/pull/147902#pullrequestreview-3005674950
changed `Checks: []` to `Checks: >` to comply with older version of
`clang-tidy`.
https://github.com/llvm/llvm-project/pull/147
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/147793
>From c4466d677619e6eb8ca65ed943bfb103207527c9 Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Wed, 9 Jul 2025 21:00:30 +0300
Subject: [PATCH 1/4] [clang-tidy][NFC] add '.clang-tidy' config for clang-tidy
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/148357
>From 82bee931621536e7e59910f1833289510909ce23 Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Sat, 12 Jul 2025 14:24:31 +0300
Subject: [PATCH] [clang-tidy] Use lexical anon-ns matcher in
llvm-prefer-stati
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/148352
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/147793
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
I will take a look at the weekend.
Sorry for double ping of other reviewers, GitHub mobile is kind of strange..
https://github.com/llvm/llvm-project/pull/144240
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.
vbvictor wrote:
Build errors seem unrelated to this change
https://github.com/llvm/llvm-project/pull/147197
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor created
https://github.com/llvm/llvm-project/pull/148352
None
>From faae7788f2789634796d065c8497e8f408c6b8e4 Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Sat, 12 Jul 2025 13:13:48 +0300
Subject: [PATCH] [clang-tidy][NFC] fixed invalid formatting in
ReleaseNo
https://github.com/vbvictor created
https://github.com/llvm/llvm-project/pull/148357
When having this code:
```cpp
namespace {
class MyClassOutOfAnon {
public:
MyClassOutOfAnon();
} // namespace
MyClassOutOfAnon::MyClassOutOfAnon() {}
```
`MyClassOutOfAnon::MyClassOutOfAnon` is located in ano
@@ -21,6 +21,17 @@ AST_MATCHER(NamedDecl, isInMacro) {
AST_MATCHER(VarDecl, isLocalVariable) { return Node.isLocalVarDecl(); }
+AST_MATCHER(Decl, isLexicallyInAnonymousNamespace) {
+ for (const DeclContext *DC = Node.getLexicalDeclContext(); DC != nullptr;
+ DC = DC->g
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/147197
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor created
https://github.com/llvm/llvm-project/pull/148384
I'm not sure if we need to add label inside link or not, but `lists.llvm.org`
seems outdated for sure, WDYT?
>From 11662e5e11ff14667893282cd05c4fa7c4be706e Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date:
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/148357
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/148384
>From 11662e5e11ff14667893282cd05c4fa7c4be706e Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Sat, 12 Jul 2025 19:51:24 +0300
Subject: [PATCH 1/2] [clang-tools-extra] fix link to code review in README.txt
vbvictor wrote:
> There are dedicated Discourse topics for Clangd and Clang-Tidy. May be they
> should be mentioned explicitly?
Added links to them as a list, do you think we need a new entry for each of the
link?
https://github.com/llvm/llvm-project/pull/148384
__
vbvictor wrote:
> One last thing I'm missing: can you update the clang-tidy contributors guide,
> to explain that we expect people to run clang-tidy as well (and what command
> to run)? Since it's not currently enforced in CI.
I will add it in a separate PR. Don't feel right to make kind-of un
vbvictor wrote:
Buildbot failure seems unrelated
https://github.com/llvm/llvm-project/pull/146830
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
Ran this check on `Poco`, `VTK` and `opencv` successfully, stack traces are
printed correctly.
https://github.com/llvm/llvm-project/pull/134375
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mail
@@ -985,6 +985,20 @@ auto buildTransferMatchSwitch() {
isOptionalMemberCallWithNameMatcher(hasName("isNull")),
transferOptionalIsNullCall)
+ // NullableValue::makeValue, NullableValue::makeValueInplace
+ // Only NullableValue has these methods, bu
vbvictor wrote:
Analysis reviewers, could you please take a look at this
https://github.com/llvm/llvm-project/pull/144313#discussion_r2188585118. Your
opinion is highly appreciated!
https://github.com/llvm/llvm-project/pull/144313
___
cfe-commits mai
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/146830
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
vbvictor wrote:
Ping @carlosgalvezp, @5chmidti, @HerrCai0907 as original reviewers of the check.
You may have more thought here, second opinion in appreciated since this PR is
a reland.
https://github.com/llvm/llvm-project/pull/144240
___
cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/144240
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/144240
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/148547
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor closed
https://github.com/llvm/llvm-project/pull/147142
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor created
https://github.com/llvm/llvm-project/pull/148547
Follow up to https://github.com/llvm/llvm-project/pull/147793.
Originally suggested in
https://github.com/llvm/llvm-project/pull/147793#issuecomment-3059021433
>From 9ee0621a78423ee97d2dcafb6b8de35783222b4e M
https://github.com/vbvictor created
https://github.com/llvm/llvm-project/pull/148549
Set `performance-move-const-arg.CheckTriviallyCopyableMove` option to `false`
because "trivially copyable" is too strict and give warning for e.g. `MixData`
class:
https://github.com/llvm/llvm-project/blob/1f
https://github.com/vbvictor approved this pull request.
LGTM
As I understand now, `IgnoreImplicitAsWritten` does not skip `CXXConstructExpr`
and other similar nodes but `IgnoreUnlessSpelledInSource` does. To drill down
to the `StringLiteral` we need to use `IgnoreUnlessSpelledInSource`.
https:/
vbvictor wrote:
IMO, we should implicitly use `multiprocessing.cpu_count()` in `run-clang-tidy`
and `clang-tidy-diff` and use that number if user didn't specify `-j`
explicitly.
P.S. running lint over all clang-tidy is not so fast now:)
```bash
$ time run-clang-tidy -p build/ clang-tools-extra
vbvictor wrote:
> Clang-Tidy pull requests are usually small, so is `-j` really necessary?
I may say why not to use all cores when we can.
If PR only touches 1 file, `clang-tidy-diff` will not load other cores.
If PR touches multiple files, the user can have N times faster linting time,
which i
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147793
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/vbvictor edited
https://github.com/llvm/llvm-project/pull/147953
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -84,7 +95,8 @@ void NamedParameterCheck::check(const
MatchFinder::MatchResult &Result) {
for (auto P : UnnamedParams) {
// Fallback to an unused marker.
- StringRef NewName = "unused";
+ constexpr StringRef FallbackName = "unused";
vbvi
https://github.com/vbvictor approved this pull request.
LGTM with nit
https://github.com/llvm/llvm-project/pull/147953
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -105,12 +117,26 @@ void NamedParameterCheck::check(const
MatchFinder::MatchResult &Result) {
NewName = Name;
}
- // Now insert the comment. Note that getLocation() points to the place
+ // Now insert the fix. Note that getLocation() points to the
@@ -1,29 +1,46 @@
// RUN: %check_clang_tidy %s readability-named-parameter %t
+// RUN: %check_clang_tidy -check-suffix=PLAIN-NAMES %s
readability-named-parameter %t -- -config="{CheckOptions: [{key:
readability-named-parameter.InsertPlainNamesInForwardDecls, value: true}]}"
---
vbvictor wrote:
> I suppose this patch does not impede further refactoring if we want to go in
> that direction in the future.
Yes, also with these tests we will be sure that future `llvm-` alias works
properly.
https://github.com/llvm/llvm-project/pull/142839
https://github.com/vbvictor updated
https://github.com/llvm/llvm-project/pull/144270
>From ba7db62070dc669d5ee0e54df075abb35772faee Mon Sep 17 00:00:00 2001
From: Victor Baranov
Date: Sun, 15 Jun 2025 19:56:05 +0300
Subject: [PATCH 1/4] [Clang] Improve diagnostics when 'placement new' was
call
1101 - 1200 of 1283 matches
Mail list logo