This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] PR 79798 Fix incorrect use of std::result_of in std::bind


Another case of problems caused by incorrect use of result_of. Because
functions can't have top-level const on parameters result_of<F(const
T)> is result_of<F(T)> so doesn't give you the answer for the question
you meant to ask.

        PR libstdc++/79798
        * include/std/functional (bind::_Res_type_impl): Fix incorrect use of
        result_of that loses top-level cv-qualifiers.
        * testsuite/20_util/bind/79798.cc: New test.


Tested powerpc64le-linux, committed to trunk.

Attachment: patch.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]