[all-commits] [llvm/llvm-project] 9ea993: [Clang] Recover GLTemplateParameterList for generi...

Younan Zhang via All-commits all-commits at lists.llvm.org
Mon Dec 2 18:10:38 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9ea993f975b045679907a0789d6fd4d7180593a0
      https://github.com/llvm/llvm-project/commit/9ea993f975b045679907a0789d6fd4d7180593a0
  Author: Younan Zhang <zyn7109 at gmail.com>
  Date:   2024-12-03 (Tue, 03 Dec 2024)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/lib/Sema/SemaDecl.cpp
    M clang/test/SemaCXX/lambda-capture-type-deduction.cpp

  Log Message:
  -----------
  [Clang] Recover GLTemplateParameterList for generic lambdas in RebuildLambdaScopeInfo (#118176)

The NTTP argument appearing inside a trailing return type of a generic
lambda would have us check for potential lambda captures, where the
function needs GLTemplateParameterList of the current LSI to tell
whether the lambda is generic.

The lambda scope in this context is rebuilt by the
LambdaScopeForCallOperatorInstantiationRAII when substituting the lambda
operator during template argument deduction. Thus, I think the template
parameter list should be preserved in the rebuilding process, as it
seems otherwise innocuous to me.

Fixes #115931



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list