[all-commits] [llvm/llvm-project] 23988a: [libc++] Fix `std::pair`'s pair-like constructor'...

Hui via All-commits all-commits at lists.llvm.org
Mon Oct 2 23:32:45 PDT 2023


  Branch: refs/heads/release/17.x
  Home:   https://github.com/llvm/llvm-project
  Commit: 23988a1d82d51670e100791b8a8745e5d8457d35
      https://github.com/llvm/llvm-project/commit/23988a1d82d51670e100791b8a8745e5d8457d35
  Author: Hui <65944694+huixie90 at users.noreply.github.com>
  Date:   2023-10-03 (Tue, 03 Oct 2023)

  Changed paths:
    M libcxx/include/__utility/pair.h
    M libcxx/test/std/utilities/utility/pairs/pairs.pair/ctor.pair_like.pass.cpp

  Log Message:
  -----------
  [libc++] Fix `std::pair`'s  pair-like constructor's incorrect assumption (#66585)

The helper function `__pair_like_explicit_wknd` is only SFINAE-ed with
`tuple_size<remove_cvref_t<_PairLike>>::value == 2`, but its function
body assumes `std::get` being valid.

Fixes #65620

(cherry picked from commit 054f9c55c6b4520d3feb8b4354b9b942026b5124)




More information about the All-commits mailing list