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] |
This patch implements the requirement that std::function move-constructs its target object, as well as my proposed resolution to LWG issue 1288, see http://home.roadrunner.com/~hinnant/issue_review/lwg-active.html#1288 I've added __throw_bad_function_call, which I'm also going to use in std::packaged_task in another patch coming soon. * include/std/functional (function::function): Move construct target. (function::operator=): Use perfect forwarding for argument. (function::operator()): Use new __throw_bad_function_call. * include/bits/functexcept.h (__throw_bad_function_call): Declare. * src/functexcept.cc (__throw_bad_function_call): Define. * config/abi/pre/gnu.ver: Add new symbol. * testsuite/20_util/function/cons/move_target.cc: New. * testsuite/20_util/function/assign/move_target.cc: New. Tested x86_64/Linux and committed.
Attachment:
function_move_target.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |