[all-commits] [llvm/llvm-project] eaee8a: [Clang][Sema] fix a bug on template partial specia...

Qizhi Hu via All-commits all-commits at lists.llvm.org
Tue Apr 30 01:09:32 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: eaee8aa0afe111f9291d54ecef97a3640a0f6ce0
      https://github.com/llvm/llvm-project/commit/eaee8aa0afe111f9291d54ecef97a3640a0f6ce0
  Author: Qizhi Hu <836744285 at qq.com>
  Date:   2024-04-30 (Tue, 30 Apr 2024)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/lib/Sema/SemaTemplate.cpp
    A clang/test/SemaCXX/identical-type-primary-partial-specialization.cpp

  Log Message:
  -----------
  [Clang][Sema] fix a bug on template partial specialization (#89862)

attempt to fix
https://github.com/llvm/llvm-project/issues/68885#issuecomment-1764201896
Deduction of NTTP whose type is `decltype(auto)` would create an
implicit cast expression to dependent type and makes the type of primary
template definition (`InjectedClassNameSpecialization`) and its partial
specialization different. Prevent emitting cast expression to make clang
knows their types are identical by removing `CTAK == CTAK_Deduced` when
the type is `decltype(auto)`.

Co-authored-by: huqizhi <836744285 at qq.com>



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