[all-commits] [llvm/llvm-project] 7415a7: [libc++][NFC] Simplify SFINAE detections in `weak_...

A. Jiang via All-commits all-commits at lists.llvm.org
Fri Nov 28 02:55:34 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7415a7fc11fd7d4865e2f0e08b378c561aae7a4f
      https://github.com/llvm/llvm-project/commit/7415a7fc11fd7d4865e2f0e08b378c561aae7a4f
  Author: A. Jiang <de34 at live.cn>
  Date:   2025-11-28 (Fri, 28 Nov 2025)

  Changed paths:
    M libcxx/include/__functional/weak_result_type.h

  Log Message:
  -----------
  [libc++][NFC] Simplify SFINAE detections in `weak_result_type.h` (#169870)

For `__has_result_type`, it can be replaced with a variable template
`__has_result_type_v`. Note that the pre-existing extraneous `*` used in
detection is buggy, but it's a functional change to fix it.

`false_type` and `true_type` are no longer directly used, so direct
inclusion of `<__type_traits/integral_constant.h>` is removed.

For `__derives_from_{unary,binary}_function`, it's unnecessary to invent
a `__two` type for each specialization. So `void` is used instead. Also,
`nullptr` is now used instead of `0`.



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