P0433 (adopted in C++17) added two deduction guides for std::function.
This patch implements those deduction guides in libc++.
__function_ctad<_Tp> is really tedious. It could be simplified by:
- using macros to generate the 2x2x2x2 = 16 partial specializations (MSVC does this)
- using noexcept(_Np) to deduce the noexcept-specification, reducing the number of partial specializations by half (libstdc++ does this)
- completely ignoring the possibility of volatile-qualified operator() overloads, reducing the number of partial specializations by half (libstdc++ does this)
- deciding that it would be easier to ask LWG to revert this whole part of P0433, than bother to implement it