https://github.com/HerrCai0907 closed
https://github.com/llvm/llvm-project/pull/84095
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HerrCai0907 updated
https://github.com/llvm/llvm-project/pull/84095
>From 160add4d95f34608a3d423482ad50fb45f6db522 Mon Sep 17 00:00:00 2001
From: Congcong Cai
Date: Wed, 6 Mar 2024 06:55:30 +0800
Subject: [PATCH 1/4] [clang-tidy][NFC]refactor AssertSideEffectCheck logic
---
@@ -60,16 +60,27 @@ AST_MATCHER_P2(Expr, hasSideEffect, bool,
CheckFunctionCalls,
}
if (const auto *CExpr = dyn_cast(E)) {
-bool Result = CheckFunctionCalls;
+if (!CheckFunctionCalls)
+ return false;
if (const auto *FuncDecl = CExpr->getDirectCallee())
https://github.com/5chmidti edited
https://github.com/llvm/llvm-project/pull/84095
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -122,6 +122,10 @@ New check aliases
Changes in existing checks
^^
+- Improved :doc:`bugprone-assert-side-effect
+ ` check by detection side
5chmidti wrote:
`... detecting side effects from calling a method ...`
https://github.com/5chmidti approved this pull request.
LGTM
https://github.com/llvm/llvm-project/pull/84095
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/HerrCai0907 updated
https://github.com/llvm/llvm-project/pull/84095
>From 160add4d95f34608a3d423482ad50fb45f6db522 Mon Sep 17 00:00:00 2001
From: Congcong Cai
Date: Wed, 6 Mar 2024 06:55:30 +0800
Subject: [PATCH 1/3] [clang-tidy][NFC]refactor AssertSideEffectCheck logic
---
llvmbot wrote:
@llvm/pr-subscribers-clang-tools-extra
Author: Congcong Cai (HerrCai0907)
Changes
Fixes: #84092
---
Full diff: https://github.com/llvm/llvm-project/pull/84095.diff
3 Files Affected:
- (modified) clang-tools-extra/clang-tidy/bugprone/AssertSideEffectCheck.cpp
(+17-5)
-
https://github.com/HerrCai0907 created
https://github.com/llvm/llvm-project/pull/84095
Fixes: #84092
>From 160add4d95f34608a3d423482ad50fb45f6db522 Mon Sep 17 00:00:00 2001
From: Congcong Cai
Date: Wed, 6 Mar 2024 06:55:30 +0800
Subject: [PATCH 1/2] [clang-tidy][NFC]refactor