[all-commits] [llvm/llvm-project] 939a3d: [Concepts] Fix Concepts on generic lambda in a Var...
Erich Keane via All-commits
all-commits at lists.llvm.org
Mon Oct 3 12:44:39 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 939a3d22e21f80246fc6a417da7193c0b93a7a44
https://github.com/llvm/llvm-project/commit/939a3d22e21f80246fc6a417da7193c0b93a7a44
Author: Erich Keane <erich.keane at intel.com>
Date: 2022-10-03 (Mon, 03 Oct 2022)
Changed paths:
M clang/include/clang/AST/DeclBase.h
M clang/include/clang/Sema/Sema.h
M clang/lib/AST/DeclBase.cpp
M clang/lib/Sema/SemaConcept.cpp
M clang/lib/Sema/SemaTemplate.cpp
M clang/lib/Sema/SemaTemplateDeduction.cpp
M clang/lib/Sema/SemaTemplateInstantiate.cpp
M clang/test/SemaTemplate/concepts-lambda.cpp
Log Message:
-----------
[Concepts] Fix Concepts on generic lambda in a VarTemplateSpecDecl
As fallout of the Deferred Concept Instantiation patch (babdef27c5), we
got a number of reports of a regression, where we asserted when
instantiating a constraint on a generic lambda inside of a variable
template. See: https://github.com/llvm/llvm-project/issues/57958
The problem was that getTemplateInstantiationArgs function only walked
up declaration contexts, and missed that this is not necessarily the
case with a lambda (which can ALSO be in a separate context).
This patch refactors the getTemplateInstantiationArgs function in a way
that is hopefully more readable, and fixes the problem with the concepts
on a generic lambda.
Differential Revision: https://reviews.llvm.org/D134874
More information about the All-commits
mailing list