[all-commits] [llvm/llvm-project] 84959a: [Concepts] Instantiate invented template type para...

Saar Raz via All-commits all-commits at lists.llvm.org
Mon Feb 3 06:52:56 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 84959ae47f447fca9d56a9c61e8c46e993d0387a
      https://github.com/llvm/llvm-project/commit/84959ae47f447fca9d56a9c61e8c46e993d0387a
  Author: Saar Raz <saar at raz.email>
  Date:   2020-02-03 (Mon, 03 Feb 2020)

  Changed paths:
    M clang/lib/Sema/SemaTemplateInstantiate.cpp
    M clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
    A clang/test/SemaTemplate/instantiate-abbreviated-template.cpp

  Log Message:
  -----------
  [Concepts] Instantiate invented template type parameter type-constraint along with function parameters

We previously instantiated type-constraints of template type parameters along with the type parameter itself,
this caused problems when the type-constraints created by abbreviated templates refreneced other parameters
in the abbreviated templates.

When encountering a template type parameter with a type constraint, if it is implicit, delay instantiation of
the type-constraint until the function parameter which created the invented template type parameter is
instantiated.

Reland after fixing bug caused by another flow reaching SubstParmVarDecl and instantiating the TypeConstraint
a second time.




More information about the All-commits mailing list