Extend std::function test for PR 68995

* testsuite/20_util/function/68995.cc: Test reference_wrapper cases.

From-SVN: r232294
This commit is contained in:
Jonathan Wakely 2016-01-12 19:39:47 +00:00 committed by Jonathan Wakely
parent 9e530bcd02
commit bd285a8bdb
2 changed files with 7 additions and 0 deletions

View File

@ -1,5 +1,7 @@
2016-01-12 Jonathan Wakely <jwakely@redhat.com>
* testsuite/20_util/function/68995.cc: Test reference_wrapper cases.
PR libstdc++/69005
PR libstdc++/69222
* include/std/functional (function::_Invoke): Remove, use result_of.

View File

@ -25,3 +25,8 @@
std::tr1::shared_ptr<int> test() { return {}; }
std::function<std::tr1::shared_ptr<int>()> func = test;
std::function<std::tr1::shared_ptr<int>()> funcr = std::ref(test);
void test2(std::tr1::shared_ptr<int>) { }
std::function<void(std::tr1::shared_ptr<int>)> func2 = std::ref(test2);