2
0
mirror of https://github.com/boostorg/fiber.git synced 2026-02-18 01:52:24 +00:00
Files
fiber/src/detail/scheduler.cpp
Oliver Kowalke 6a1257442b re-factoring of thread_local_ptr<>
Conflicts:
	include/boost/fiber/detail/scheduler.hpp
	src/detail/scheduler.cpp
	src/fiber_manager.cpp
2014-10-01 23:19:36 +02:00

36 lines
750 B
C++

// Copyright Oliver Kowalke 2013.
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#include "boost/fiber/detail/scheduler.hpp"
#include <boost/assert.hpp>
#include <boost/fiber/fiber_manager.hpp>
#ifdef BOOST_HAS_ABI_HEADERS
# include BOOST_ABI_PREFIX
#endif
namespace boost {
namespace fibers {
namespace detail {
thread_local_ptr< fiber_manager > scheduler::instance_;
//thread_specific_ptr< fiber_manager > scheduler::instance_;
void
scheduler::replace( sched_algorithm * other)
{
BOOST_ASSERT( other);
fm_set_sched_algo( other);
}
}}}
#ifdef BOOST_HAS_ABI_HEADERS
# include BOOST_ABI_SUFFIX
#endif