This patch attempts to fix the lambda call expression inside of a type alias declaration from two aspects: 1. Defer the lambda call expression building until after we have sufficient template arguments. This avoids the overeager (and often wrong) semantic checking before the type alias instantiation. 2. Properly obtain template arguments involving a template type alias for constraint checking. It is unfortunate that a `TypeAliasTemplateDecl` (or a `TypeAliasDecl`) is never a `DeclContext`, nor does it have an associated specialization Decl from which we could collect these template arguments. Thus, I added a new CodeSynthesisContext to record template arguments for alias declarations. Fixes https://github.com/llvm/llvm-project/issues/70601 Fixes https://github.com/llvm/llvm-project/issues/76674 Fixes https://github.com/llvm/llvm-project/issues/79555 Fixes https://github.com/llvm/llvm-project/issues/81145 Fixes https://github.com/llvm/llvm-project/issues/82104 Note that this doesn't involve the fix for https://github.com/llvm/llvm-project/issues/28461. That seems different, and I'd like to leave it as a follow-up.
68 KiB
68 KiB