[all-commits] [llvm/llvm-project] 2c2ad9: Reapply "[Clang] Profile singly-resolved Unresolve...

Younan Zhang via All-commits all-commits at lists.llvm.org
Wed Jun 18 23:59:54 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 2c2ad9a096e78e9129f8cb2d4ee260eb7e67473f
      https://github.com/llvm/llvm-project/commit/2c2ad9a096e78e9129f8cb2d4ee260eb7e67473f
  Author: Younan Zhang <zyn7109 at gmail.com>
  Date:   2025-06-19 (Thu, 19 Jun 2025)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/lib/AST/StmtProfile.cpp
    M clang/test/SemaCXX/exception-spec.cpp
    M clang/test/SemaTemplate/concepts-out-of-line-def.cpp

  Log Message:
  -----------
  Reapply "[Clang] Profile singly-resolved UnresolvedLookupExpr with the declaration" (#140680)

For a dependent variable template specialization, we don't build a
dependent Decl node or a DeclRefExpr to represent it. Instead, we
preserve the UnresolvedLookupExpr until instantiation.

However, this approach isn't ideal for constraint normalization. We
consider the qualifier during profiling, but since that's based on the
written code, it can introduce confusing differences, even when the
expressions resolve to the same declaration.

This change profiles the underlying VarTemplateDecl if
UnresolvedLookupExpr is used to model a dependent use of it.

Fixes https://github.com/llvm/llvm-project/issues/139476



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