[Boost-bugs] [Boost C++ Libraries] #13182: Boost.Fiber ignores lambda captures

Subject: [Boost-bugs] [Boost C++ Libraries] #13182: Boost.Fiber ignores lambda captures
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2017-08-30 00:43:19


#13182: Boost.Fiber ignores lambda captures
---------------------------------------+---------------------
 Reporter: Sergey Babin <axilmail@…> | Owner: olli
     Type: Bugs | Status: new
Milestone: Boost 1.65.0 | Component: context
  Version: Boost 1.65.0 | Severity: Problem
 Keywords: Fiber |
---------------------------------------+---------------------
 In version 1.65, the following code doesn't work:

 boost::fibers::fiber([p=std::make_shared<std::string>("Hi")]{
   assert(p);
 }).detach();

 This probably because when you call std::apply(std::move(fn_), std::move(
 arg_)) in function "worker_context::run_", should have used "fn" and "arg"
 instead of "fn_" and "arg_".

 Please look at "boost\fiber\context.hpp" line 428

-- 
Ticket URL: <https://svn.boost.org/trac10/boost/ticket/13182>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-08-30 00:48:30 UTC