-
Notifications
You must be signed in to change notification settings - Fork 14.9k
NFC: remove some instances of deprecated capture #154884
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
j2kun
commented
Aug 22, 2025
@llvm/pr-subscribers-mlir-sparse @llvm/pr-subscribers-llvm-support Author: Jeremy Kun (j2kun) Changes
Full diff: https://github.com/llvm/llvm-project/pull/154884.diff 2 Files Affected:
diff --git a/llvm/lib/Support/Parallel.cpp b/llvm/lib/Support/Parallel.cpp
index 2ba02b73dd8f1..3ac6fc74fd3e0 100644
--- a/llvm/lib/Support/Parallel.cpp
+++ b/llvm/lib/Support/Parallel.cpp
@@ -60,7 +60,7 @@ class ThreadPoolExecutor : public Executor {
auto &Thread0 = Threads[0];
Thread0 = std::thread([this, S] {
for (unsigned I = 1; I < ThreadCount; ++I) {
- Threads.emplace_back([=] { work(S, I); });
+ Threads.emplace_back([this, S, I] { work(S, I); });
if (Stop)
break;
}
diff --git a/mlir/lib/Transforms/InlinerPass.cpp b/mlir/lib/Transforms/InlinerPass.cpp
index 703e517d45374..45c2506964559 100644
--- a/mlir/lib/Transforms/InlinerPass.cpp
+++ b/mlir/lib/Transforms/InlinerPass.cpp
@@ -138,7 +138,7 @@ void InlinerPass::runOnOperation() {
}
// By default, assume that any inlining is profitable.
- auto profitabilityCb = [=](const Inliner::ResolvedCall &call) {
+ auto profitabilityCb = [this, inliningThreshold](const Inliner::ResolvedCall &call) {
return isProfitableToInline(call, inliningThreshold);
};
|
|
✅ With the latest revision this PR passed the C/C++ code formatter. |
75d11fb
to
3f9d457
Compare
5a86e84
to
88e9055
Compare
Looks like the test failing is failing at head and unrelated to the change in this PR |
88e9055
to
9e48dd9
Compare
``` warning: implicit capture of 'this' with a capture default of '=' is deprecated [-Wdeprecated-this-capture] ```
Is it OK to bypass the failing CI here? |
It's OK if you're confident (pre-merge didn't even exist not that long ago). (That said a rebase-rerun is also fairly cheap, there is an "Update branch" button that should do it) |
LLVM Buildbot has detected a new failure on builder Full details are available at: https://lab.llvm.org/buildbot/#/builders/123/builds/26006 Here is the relevant piece of the build log for the reference
|