[Bug libstdc++/121858] function_ref(nontype_t<__fn>, _Up&& __ref) did not consider that _Up is a reference_wrapper
tkaminsk at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Oct 24 14:09:43 GMT 2025
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121858
--- Comment #8 from Tomasz Kamiński <tkaminsk at gcc dot gnu.org> ---
> Yes. But if we know it is a reference_wrapper, we can dispatch function_ref(nontype_t<f>, cv T*) using reference_wrapper::get().
Only if f is member pointer, f may accept reference_wrapper<T>& and use it
address.
More information about the Gcc-bugs
mailing list