https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81211
--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> --- (In reply to Stephen Kell from comment #0) > (It may also be a bug in libstdc++ that std::function should require this of > its argument type, although that's not completely bonkers.) It's explicitly required by the standard.