sl@0
|
1 |
#ifndef BOOST_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED
|
sl@0
|
2 |
#define BOOST_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED
|
sl@0
|
3 |
|
sl@0
|
4 |
// MS compatible compilers support #pragma once
|
sl@0
|
5 |
|
sl@0
|
6 |
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
sl@0
|
7 |
# pragma once
|
sl@0
|
8 |
#endif
|
sl@0
|
9 |
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// boost/detail/lightweight_mutex.hpp - lightweight mutex
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Copyright (c) 2002, 2003 Peter Dimov and Multi Media Ltd.
|
sl@0
|
14 |
//
|
sl@0
|
15 |
// Distributed under the Boost Software License, Version 1.0. (See
|
sl@0
|
16 |
// accompanying file LICENSE_1_0.txt or copy at
|
sl@0
|
17 |
// http://www.boost.org/LICENSE_1_0.txt)
|
sl@0
|
18 |
//
|
sl@0
|
19 |
// typedef <unspecified> boost::detail::lightweight_mutex;
|
sl@0
|
20 |
//
|
sl@0
|
21 |
// boost::detail::lightweight_mutex is a header-only implementation of
|
sl@0
|
22 |
// a subset of the Mutex concept requirements:
|
sl@0
|
23 |
//
|
sl@0
|
24 |
// http://www.boost.org/doc/html/threads/concepts.html#threads.concepts.Mutex
|
sl@0
|
25 |
//
|
sl@0
|
26 |
// It maps to a CRITICAL_SECTION on Windows or a pthread_mutex on POSIX.
|
sl@0
|
27 |
//
|
sl@0
|
28 |
|
sl@0
|
29 |
#include <boost/config.hpp>
|
sl@0
|
30 |
|
sl@0
|
31 |
#if !defined(BOOST_HAS_THREADS)
|
sl@0
|
32 |
# include <boost/detail/lwm_nop.hpp>
|
sl@0
|
33 |
#elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__)
|
sl@0
|
34 |
# include <boost/detail/lwm_win32_cs.hpp>
|
sl@0
|
35 |
#elif defined(BOOST_HAS_PTHREADS)
|
sl@0
|
36 |
# include <boost/detail/lwm_pthreads.hpp>
|
sl@0
|
37 |
#else
|
sl@0
|
38 |
// Use #define BOOST_DISABLE_THREADS to avoid the error
|
sl@0
|
39 |
# error Unrecognized threading platform
|
sl@0
|
40 |
#endif
|
sl@0
|
41 |
|
sl@0
|
42 |
#endif // #ifndef BOOST_DETAIL_LIGHTWEIGHT_MUTEX_HPP_INCLUDED
|