[clang] [clang] Don't use `VarDecl` of local variables as `ManglingContextDecl` for lambdas (PR #179035)

Chuanqi Xu via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 2 18:09:31 PST 2026


Jan =?utf-8?q?Kokemüller?= <jan.kokemueller at gmail.com>,
Jan =?utf-8?q?Kokemüller?= <jan.kokemueller at gmail.com>,
Jan =?utf-8?q?Kokemüller?= <jan.kokemueller at gmail.com>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/179035 at github.com>


ChuanqiXu9 wrote:

> I had a look in Compiler Explorer, and GCC generates code for both lambdas. But I haven't looked at GCC's code.

This is an ABI thing. We need to be align with the ABI standard (https://github.com/itanium-cxx-abi/cxx-abi/issues/186 , sadly the ABI group seems not active recently...). 

For the PR itself, I think we can land it now as it makes clang self contained. And let's continue the discussion in the itanium ABI group.

https://github.com/llvm/llvm-project/pull/179035


More information about the cfe-commits mailing list