[all-commits] [llvm/llvm-project] e9ce75: [libc++] Remove the constexpr `hash<vector<bool>>`...

A. Jiang via All-commits all-commits at lists.llvm.org
Tue May 13 16:20:48 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e9ce7527691ec2b3748895598cd5ee31ac644f3a
      https://github.com/llvm/llvm-project/commit/e9ce7527691ec2b3748895598cd5ee31ac644f3a
  Author: A. Jiang <de34 at live.cn>
  Date:   2025-05-14 (Wed, 14 May 2025)

  Changed paths:
    M libcxx/docs/ReleaseNotes/21.rst
    M libcxx/include/__vector/vector_bool.h
    M libcxx/test/std/containers/sequences/vector.bool/enabled_hash.pass.cpp
    M libcxx/test/std/containers/sequences/vector.bool/vector_bool.pass.cpp

  Log Message:
  -----------
  [libc++] Remove the constexpr `hash<vector<bool>>` extension (#132617)

libc++ makes the `hash<vector<bool, A>>::operator()` `constexpr` since
C++20, which is a conforming extension, but it was unintended.

This patch removes the extension, with an escape hatch macro for it, and
the escape hatch will be removed in the future. Test cases for
`constexpr` along with the assumption of hash values are moved to the
`libcxx/test/libcxx/` subdirectory.

---------

Co-authored-by: Louis Dionne <ldionne.2 at gmail.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