[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-05 Thread via cfe-commits
https://github.com/cor3ntin closed https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-05 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread via cfe-commits
cor3ntin wrote: > Probably needs a release note. Nah, this fixes a bug with deducing this I introduced on Monday :) https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread Mariya Podchishchaeva via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread Mariya Podchishchaeva via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread Mariya Podchishchaeva via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon commented: Probably needs a release note. https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-04 Thread Mariya Podchishchaeva via cfe-commits
https://github.com/Fznamznon edited https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/68090 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread Shafik Yaghmour via cfe-commits
@@ -8367,7 +8367,13 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { // Start with 'Result' referring to the complete closure object... - Result = *Info.CurrentCall-

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread Shafik Yaghmour via cfe-commits
shafik wrote: Can you write a more detailed description explaining what the problem is what the fix is. This is what usually ends up in the git log and we want that to be as descriptive as possible for folks who use it to understand changes quickly without digging into details. https://githu

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread via cfe-commits
@@ -8366,8 +8366,14 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { return false; if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { + auto *MD = cast(Info.CurrentCall->Callee); // Start with 'Result' referri

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/68090 >From d3c5351c0bddd0bf9cd743471beafbf18bbab77c Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Tue, 3 Oct 2023 13:19:50 +0200 Subject: [PATCH 1/2] [Clang] Fix constant evaluating a captured variable in a la

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread Timm Baeder via cfe-commits
@@ -8366,8 +8366,14 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { return false; if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { + auto *MD = cast(Info.CurrentCall->Callee); // Start with 'Result' referri

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread Timm Baeder via cfe-commits
@@ -8366,8 +8366,14 @@ bool LValueExprEvaluator::VisitVarDecl(const Expr *E, const VarDecl *VD) { return false; if (auto *FD = Info.CurrentCall->LambdaCaptureFields.lookup(VD)) { + auto *MD = cast(Info.CurrentCall->Callee); // Start with 'Result' referri

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Changes with an explicit parameter. Fixes #68070 --- Full diff: https://github.com/llvm/llvm-project/pull/68090.diff 2 Files Affected: - (modified) clang/lib/AST/ExprConstant.cpp (+7-1) - (modified) clang/test/SemaCXX/cxx2b-deducing-this-const

[clang] [Clang] Fix constant evaluating a captured variable in a lambda (PR #68090)

2023-10-03 Thread via cfe-commits
https://github.com/cor3ntin created https://github.com/llvm/llvm-project/pull/68090 with an explicit parameter. Fixes #68070 >From d3c5351c0bddd0bf9cd743471beafbf18bbab77c Mon Sep 17 00:00:00 2001 From: Corentin Jabot Date: Tue, 3 Oct 2023 13:19:50 +0200 Subject: [PATCH] [Clang] Fix constant