[all-commits] [llvm/llvm-project] e8ded3: [clang] fix nondeduced mismatch with nullptr templ...

Matheus Izvekov via All-commits all-commits at lists.llvm.org
Sun Jan 26 19:17:22 PST 2025


  Branch: refs/heads/users/mizvekov/clang-fix-nullptr-nondeduced-mismatch
  Home:   https://github.com/llvm/llvm-project
  Commit: e8ded39966b65d36c6d84572626882e3c2594c78
      https://github.com/llvm/llvm-project/commit/e8ded39966b65d36c6d84572626882e3c2594c78
  Author: Matheus Izvekov <mizvekov at gmail.com>
  Date:   2025-01-27 (Mon, 27 Jan 2025)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/lib/Sema/SemaTemplateDeduction.cpp
    M clang/test/SemaTemplate/cwg2398.cpp

  Log Message:
  -----------
  [clang] fix nondeduced mismatch with nullptr template arguments

In deduction, when comparing template arguments of value kind,
we should check if the value matches. Values of different types can
still match. For example, `short(0)` matches `int(0)`.

Values of nullptr kind always match each other, since there is only
one such possible value. Similarly to integrals, the type does not
matter.



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