mirror-llvm-project/libcxx/include/__functional
Hui a434fe87cc
[libc++] Implement std::function_ref (#186692)
Papers:
- P0792R14: function_ref: a type-erased callable reference
- P3948R1 constant_wrapper is the only tool needed for passing constant
expressions via function arguments
- P3961R1 Less double indirection in function_ref (RU-220)

LWG issues:
- LWG4256: Incorrect constraints for function_ref constructors from
nontype_t
- LWG4425: CTAD function_ref of data member pointer should produce
noexcept signature

Fixes #189606
Fixes #105376
Fixes #189604
Fixes #171321
Fixes #171387

---------

Co-authored-by: Xiaoyang Liu <siujoeng.lau@gmail.com>
Co-authored-by: Louis Dionne <ldionne.2@gmail.com>
2026-07-25 17:44:55 +01:00
..
binary_function.h
binary_negate.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
bind.h [libc++] Simplify a few places where we use __index_sequence (#167213) 2025-12-02 15:02:04 +01:00
bind_back.h [libc++] Applied [[nodiscard]] to some general utilities (#169322) 2025-11-25 16:24:38 +02:00
bind_front.h [libc++][functional] Implement std::bind_front<NTTP> (#165096) 2026-04-19 23:59:28 +08:00
binder1st.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
binder2nd.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
boyer_moore_searcher.h [libc++][NFC] Remove __remove_uncvref (#140531) 2025-07-04 11:16:47 +02:00
compose.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
default_searcher.h
function.h Reapply "[libc++][NFC] Inline std::function members into the class body" (#209555) (#210260) 2026-07-20 10:35:29 +02:00
function_ref.h [libc++] Implement std::function_ref (#186692) 2026-07-25 17:44:55 +01:00
function_ref_common.h [libc++] Implement std::function_ref (#186692) 2026-07-25 17:44:55 +01:00
function_ref_impl.h [libc++] Implement std::function_ref (#186692) 2026-07-25 17:44:55 +01:00
hash.h [libc++] Introduce implicit and explicit ABI annotations (#193045) 2026-05-08 12:21:31 +02:00
identity.h [libc++] Add [[clang::lifetimebound]] to std::identity (#165854) 2025-11-02 10:27:09 +01:00
invoke.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
is_transparent.h [libc++] Refactor __is_transparent_v to make it clear what it depends on (#186419) 2026-03-18 10:53:47 -04:00
mem_fn.h [libc++] Applied [[nodiscard]] to some general utilities (#169322) 2025-11-25 16:24:38 +02:00
mem_fun_ref.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
not_fn.h
operations.h [libc++][NFC] Rename the template parameter of __make_transparent (#186435) 2026-03-17 10:15:37 -04:00
perfect_forward.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
pointer_to_binary_function.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
pointer_to_unary_function.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
ranges_operations.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
reference_wrapper.h [libc++] Applied [[nodiscard]] to some general utilities (#169322) 2025-11-25 16:24:38 +02:00
unary_function.h
unary_negate.h [libc++] Consistently use version guards outside namespace macros (#181136) 2026-06-29 14:44:44 +02:00
weak_result_type.h [libc++][NFC] Simplify SFINAE detections in weak_result_type.h (#169870) 2025-11-28 18:55:13 +08:00