This allows overload sets containing function_ref arguments to work correctly
Otherwise they're ambiguous as anything "could be" converted to a function_ref.
This matches proposed std::function_ref, absl::function_ref, etc.
Differential D88901
[ADT] function_ref's constructor is unavailable if the argument is not callable. sammccall on Oct 6 2020, 7:37 AM. Authored by
Details This allows overload sets containing function_ref arguments to work correctly This matches proposed std::function_ref, absl::function_ref, etc.
Diff Detail
Event Timeline
Comment Actions Combine SFINAE conditions into one top-level condition. Fix a couple of broken usages that no longer compile (in default-args that were |
This now has two different SFINAE approaches (one in a defaulted template type parameter, one in a defaulted function/ctor parameter) - do they need to be different? Could they be merged in some way to at least use the same/common infrastructure?