|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r81932 - in trunk/boost: . atomic atomic/detail
From: andrey.semashev_at_[hidden]
Date: 2012-12-14 06:13:34
Author: andysem
Date: 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
New Revision: 81932
URL: http://svn.boost.org/trac/boost/changeset/81932
Log:
Rearranged public headers and added #pragma once for compilers that support it.
Added:
trunk/boost/atomic/atomic.hpp
- copied, changed from r81828, /trunk/boost/atomic.hpp
trunk/boost/atomic/detail/config.hpp
- copied, changed from r81931, /trunk/boost/atomic/config.hpp
trunk/boost/atomic/detail/platform.hpp
- copied, changed from r81931, /trunk/boost/atomic/platform.hpp
Removed:
trunk/boost/atomic/config.hpp
trunk/boost/atomic/platform.hpp
Text files modified:
trunk/boost/atomic.hpp | 164 ---------------------------------------
trunk/boost/atomic/atomic.hpp | 12 +
trunk/boost/atomic/detail/base.hpp | 5 +
trunk/boost/atomic/detail/cas32strong.hpp | 5 +
trunk/boost/atomic/detail/cas32weak.hpp | 5 +
trunk/boost/atomic/detail/cas64strong.hpp | 5 +
trunk/boost/atomic/detail/config.hpp | 18 +++-
trunk/boost/atomic/detail/gcc-alpha.hpp | 5 +
trunk/boost/atomic/detail/gcc-armv6plus.hpp | 6 +
trunk/boost/atomic/detail/gcc-cas.hpp | 6 +
trunk/boost/atomic/detail/gcc-ppc.hpp | 6 +
trunk/boost/atomic/detail/gcc-sparcv9.hpp | 6 +
trunk/boost/atomic/detail/gcc-x86.hpp | 6 +
trunk/boost/atomic/detail/generic-cas.hpp | 5 +
trunk/boost/atomic/detail/interlocked.hpp | 5 +
trunk/boost/atomic/detail/linux-arm.hpp | 5 +
trunk/boost/atomic/detail/lockpool.hpp | 6 +
trunk/boost/atomic/detail/platform.hpp | 11 ++
trunk/boost/atomic/detail/type-classifier.hpp | 6 +
19 files changed, 116 insertions(+), 171 deletions(-)
Modified: trunk/boost/atomic.hpp
==============================================================================
--- trunk/boost/atomic.hpp (original)
+++ trunk/boost/atomic.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -7,168 +7,12 @@
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
-#include <cstddef>
-#include <boost/cstdint.hpp>
+// This header includes all Boost.Atomic public headers
-#include <boost/memory_order.hpp>
+#include <boost/atomic/atomic.hpp>
-#include <boost/atomic/config.hpp>
-#include <boost/atomic/platform.hpp>
-#include <boost/atomic/detail/type-classifier.hpp>
-#include <boost/type_traits/is_signed.hpp>
-
-namespace boost {
-
-#ifndef BOOST_ATOMIC_CHAR_LOCK_FREE
-#define BOOST_ATOMIC_CHAR_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_CHAR16_T_LOCK_FREE
-#define BOOST_ATOMIC_CHAR16_T_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_CHAR32_T_LOCK_FREE
-#define BOOST_ATOMIC_CHAR32_T_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_WCHAR_T_LOCK_FREE
-#define BOOST_ATOMIC_WCHAR_T_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_SHORT_LOCK_FREE
-#define BOOST_ATOMIC_SHORT_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_INT_LOCK_FREE
-#define BOOST_ATOMIC_INT_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_LONG_LOCK_FREE
-#define BOOST_ATOMIC_LONG_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_LLONG_LOCK_FREE
-#define BOOST_ATOMIC_LLONG_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_POINTER_LOCK_FREE
-#define BOOST_ATOMIC_POINTER_LOCK_FREE 0
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
#endif
-#define BOOST_ATOMIC_ADDRESS_LOCK_FREE BOOST_ATOMIC_POINTER_LOCK_FREE
-
-#ifndef BOOST_ATOMIC_BOOL_LOCK_FREE
-#define BOOST_ATOMIC_BOOL_LOCK_FREE 0
-#endif
-
-#ifndef BOOST_ATOMIC_THREAD_FENCE
-#define BOOST_ATOMIC_THREAD_FENCE 0
-static inline void
-atomic_thread_fence(memory_order)
-{
-}
-#endif
-
-#ifndef BOOST_ATOMIC_SIGNAL_FENCE
-#define BOOST_ATOMIC_SIGNAL_FENCE 0
-static inline void
-atomic_signal_fence(memory_order order)
-{
- atomic_thread_fence(order);
-}
-#endif
-
-template<typename T>
-class atomic : public atomics::detail::base_atomic<T, typename atomics::detail::type_classifier<T>::test, sizeof(T), boost::is_signed<T>::value > {
-private:
- typedef T value_type;
- typedef atomics::detail::base_atomic<T, typename atomics::detail::type_classifier<T>::test, sizeof(T), boost::is_signed<T>::value > super;
-public:
- atomic(void) : super() {}
- explicit atomic(const value_type & v) : super(v) {}
-
- atomic & operator=(value_type v) volatile
- {
- super::operator=(v);
- return *const_cast<atomic *>(this);
- }
-private:
- atomic(const atomic &) /* =delete */ ;
- atomic & operator=(const atomic &) /* =delete */ ;
-};
-
-typedef atomic<char> atomic_char;
-typedef atomic<unsigned char> atomic_uchar;
-typedef atomic<signed char> atomic_schar;
-typedef atomic<uint8_t> atomic_uint8_t;
-typedef atomic<int8_t> atomic_int8_t;
-typedef atomic<unsigned short> atomic_ushort;
-typedef atomic<short> atomic_short;
-typedef atomic<uint16_t> atomic_uint16_t;
-typedef atomic<int16_t> atomic_int16_t;
-typedef atomic<unsigned int> atomic_uint;
-typedef atomic<int> atomic_int;
-typedef atomic<uint32_t> atomic_uint32_t;
-typedef atomic<int32_t> atomic_int32_t;
-typedef atomic<unsigned long> atomic_ulong;
-typedef atomic<long> atomic_long;
-typedef atomic<uint64_t> atomic_uint64_t;
-typedef atomic<int64_t> atomic_int64_t;
-#ifdef BOOST_HAS_LONG_LONG
-typedef atomic<boost::ulong_long_type> atomic_ullong;
-typedef atomic<boost::long_long_type> atomic_llong;
-#endif
-typedef atomic<void*> atomic_address;
-typedef atomic<bool> atomic_bool;
-
-#ifndef BOOST_ATOMIC_FLAG_LOCK_FREE
-#define BOOST_ATOMIC_FLAG_LOCK_FREE 0
-class atomic_flag {
-public:
- atomic_flag(void) : v_(false) {}
-
- bool
- test_and_set(memory_order order = memory_order_seq_cst)
- {
- return v_.exchange(true, order);
- }
-
- void
- clear(memory_order order = memory_order_seq_cst) volatile
- {
- v_.store(false, order);
- }
-private:
- atomic_flag(const atomic_flag &) /* = delete */ ;
- atomic_flag & operator=(const atomic_flag &) /* = delete */ ;
- atomic<bool> v_;
-};
-#endif
-
-typedef atomic<char> atomic_char;
-typedef atomic<unsigned char> atomic_uchar;
-typedef atomic<signed char> atomic_schar;
-typedef atomic<uint8_t> atomic_uint8_t;
-typedef atomic<int8_t> atomic_int8_t;
-typedef atomic<unsigned short> atomic_ushort;
-typedef atomic<short> atomic_short;
-typedef atomic<uint16_t> atomic_uint16_t;
-typedef atomic<int16_t> atomic_int16_t;
-typedef atomic<unsigned int> atomic_uint;
-typedef atomic<int> atomic_int;
-typedef atomic<uint32_t> atomic_uint32_t;
-typedef atomic<int32_t> atomic_int32_t;
-typedef atomic<unsigned long> atomic_ulong;
-typedef atomic<long> atomic_long;
-typedef atomic<uint64_t> atomic_uint64_t;
-typedef atomic<int64_t> atomic_int64_t;
-#ifdef BOOST_HAS_LONG_LONG
-typedef atomic<boost::ulong_long_type> atomic_ullong;
-typedef atomic<boost::long_long_type> atomic_llong;
-#endif
-typedef atomic<void*> atomic_address;
-typedef atomic<bool> atomic_bool;
-
-}
-
#endif
Copied: trunk/boost/atomic/atomic.hpp (from r81828, /trunk/boost/atomic.hpp)
==============================================================================
--- /trunk/boost/atomic.hpp (original)
+++ trunk/boost/atomic/atomic.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -1,5 +1,5 @@
-#ifndef BOOST_ATOMIC_HPP
-#define BOOST_ATOMIC_HPP
+#ifndef BOOST_ATOMIC_ATOMIC_HPP
+#define BOOST_ATOMIC_ATOMIC_HPP
// Copyright (c) 2011 Helge Bahmann
//
@@ -12,11 +12,15 @@
#include <boost/memory_order.hpp>
-#include <boost/atomic/config.hpp>
-#include <boost/atomic/platform.hpp>
+#include <boost/atomic/detail/config.hpp>
+#include <boost/atomic/detail/platform.hpp>
#include <boost/atomic/detail/type-classifier.hpp>
#include <boost/type_traits/is_signed.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
#ifndef BOOST_ATOMIC_CHAR_LOCK_FREE
Deleted: trunk/boost/atomic/config.hpp
==============================================================================
--- trunk/boost/atomic/config.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
+++ (empty file)
@@ -1,46 +0,0 @@
-#ifndef BOOST_ATOMIC_CONFIG_HPP
-#define BOOST_ATOMIC_CONFIG_HPP
-
-// Copyright (c) 2012 Hartmut Kaiser
-//
-// 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/config.hpp>
-
-///////////////////////////////////////////////////////////////////////////////
-// Set up dll import/export options
-#if (defined(BOOST_ATOMIC_DYN_LINK) || defined(BOOST_ALL_DYN_LINK)) && \
- !defined(BOOST_ATOMIC_STATIC_LINK)
-
-#if defined(BOOST_ATOMIC_SOURCE)
-#define BOOST_ATOMIC_DECL BOOST_SYMBOL_EXPORT
-#define BOOST_ATOMIC_BUILD_DLL
-#else
-#define BOOST_ATOMIC_DECL BOOST_SYMBOL_IMPORT
-#endif
-
-#endif // building a shared library
-
-#ifndef BOOST_ATOMIC_DECL
-#define BOOST_ATOMIC_DECL
-#endif
-
-///////////////////////////////////////////////////////////////////////////////
-// Auto library naming
-#if !defined(BOOST_ATOMIC_SOURCE) && !defined(BOOST_ALL_NO_LIB) && \
- !defined(BOOST_ATOMIC_NO_LIB)
-
-#define BOOST_LIB_NAME boost_atomic
-
-// tell the auto-link code to select a dll when required:
-#if defined(BOOST_ALL_DYN_LINK) || defined(BOOST_ATOMIC_DYN_LINK)
-#define BOOST_DYN_LINK
-#endif
-
-#include <boost/config/auto_link.hpp>
-
-#endif // auto-linking disabled
-
-#endif
Modified: trunk/boost/atomic/detail/base.hpp
==============================================================================
--- trunk/boost/atomic/detail/base.hpp (original)
+++ trunk/boost/atomic/detail/base.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -13,8 +13,13 @@
#include <string.h>
+#include <boost/atomic/detail/config.hpp>
#include <boost/atomic/detail/lockpool.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
#define BOOST_ATOMIC_DECLARE_BASE_OPERATORS \
operator value_type(void) volatile const \
{ \
Modified: trunk/boost/atomic/detail/cas32strong.hpp
==============================================================================
--- trunk/boost/atomic/detail/cas32strong.hpp (original)
+++ trunk/boost/atomic/detail/cas32strong.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -11,8 +11,13 @@
// a platform_cmpxchg32_strong primitive.
#include <boost/memory_order.hpp>
+#include <boost/atomic/detail/config.hpp>
#include <boost/atomic/detail/base.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Modified: trunk/boost/atomic/detail/cas32weak.hpp
==============================================================================
--- trunk/boost/atomic/detail/cas32weak.hpp (original)
+++ trunk/boost/atomic/detail/cas32weak.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -8,8 +8,13 @@
// Copyright (c) 2011 Helge Bahmann
#include <boost/memory_order.hpp>
+#include <boost/atomic/detail/config.hpp>
#include <boost/atomic/detail/base.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Modified: trunk/boost/atomic/detail/cas64strong.hpp
==============================================================================
--- trunk/boost/atomic/detail/cas64strong.hpp (original)
+++ trunk/boost/atomic/detail/cas64strong.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -12,8 +12,13 @@
// atomic, so they are funnelled through cmpxchg as well.
#include <boost/memory_order.hpp>
+#include <boost/atomic/detail/config.hpp>
#include <boost/atomic/detail/base.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Copied: trunk/boost/atomic/detail/config.hpp (from r81931, /trunk/boost/atomic/config.hpp)
==============================================================================
--- /trunk/boost/atomic/config.hpp (original)
+++ trunk/boost/atomic/detail/config.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -1,5 +1,5 @@
-#ifndef BOOST_ATOMIC_CONFIG_HPP
-#define BOOST_ATOMIC_CONFIG_HPP
+#ifndef BOOST_ATOMIC_DETAIL_CONFIG_HPP
+#define BOOST_ATOMIC_DETAIL_CONFIG_HPP
// Copyright (c) 2012 Hartmut Kaiser
//
@@ -9,16 +9,24 @@
#include <boost/config.hpp>
+#if (defined(_MSC_VER) && (_MSC_VER >= 1020)) || defined(__GNUC__) || defined(BOOST_CLANG) || defined(BOOST_INTEL) || defined(__COMO__) || defined(__DMC__)
+#define BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#endif
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
///////////////////////////////////////////////////////////////////////////////
// Set up dll import/export options
#if (defined(BOOST_ATOMIC_DYN_LINK) || defined(BOOST_ALL_DYN_LINK)) && \
!defined(BOOST_ATOMIC_STATIC_LINK)
-
+
#if defined(BOOST_ATOMIC_SOURCE)
-#define BOOST_ATOMIC_DECL BOOST_SYMBOL_EXPORT
+#define BOOST_ATOMIC_DECL BOOST_SYMBOL_EXPORT
#define BOOST_ATOMIC_BUILD_DLL
#else
-#define BOOST_ATOMIC_DECL BOOST_SYMBOL_IMPORT
+#define BOOST_ATOMIC_DECL BOOST_SYMBOL_IMPORT
#endif
#endif // building a shared library
Modified: trunk/boost/atomic/detail/gcc-alpha.hpp
==============================================================================
--- trunk/boost/atomic/detail/gcc-alpha.hpp (original)
+++ trunk/boost/atomic/detail/gcc-alpha.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -7,9 +7,14 @@
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
+#include <boost/atomic/detail/config.hpp>
#include <boost/atomic/detail/base.hpp>
#include <boost/atomic/detail/builder.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
/*
Refer to http://h71000.www7.hp.com/doc/82final/5601/5601pro_004.html
(HP OpenVMS systems documentation) and the alpha reference manual.
Modified: trunk/boost/atomic/detail/gcc-armv6plus.hpp
==============================================================================
--- trunk/boost/atomic/detail/gcc-armv6plus.hpp (original)
+++ trunk/boost/atomic/detail/gcc-armv6plus.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -9,6 +9,12 @@
// Copyright (c) 2009 Phil Endecott
// ARM Code by Phil Endecott, based on other architectures.
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
// From the ARM Architecture Reference Manual for architecture v6:
//
// LDREX{<cond>} <Rd>, [<Rn>]
Modified: trunk/boost/atomic/detail/gcc-cas.hpp
==============================================================================
--- trunk/boost/atomic/detail/gcc-cas.hpp (original)
+++ trunk/boost/atomic/detail/gcc-cas.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -10,6 +10,12 @@
#ifndef BOOST_ATOMIC_DETAIL_GENERIC_CAS_HPP
#define BOOST_ATOMIC_DETAIL_GENERIC_CAS_HPP
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
#define BOOST_ATOMIC_THREAD_FENCE 2
Modified: trunk/boost/atomic/detail/gcc-ppc.hpp
==============================================================================
--- trunk/boost/atomic/detail/gcc-ppc.hpp (original)
+++ trunk/boost/atomic/detail/gcc-ppc.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -7,6 +7,12 @@
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
/*
Refer to: Motorola: "Programming Environments Manual for 32-Bit
Implementations of the PowerPC Architecture", Appendix E:
Modified: trunk/boost/atomic/detail/gcc-sparcv9.hpp
==============================================================================
--- trunk/boost/atomic/detail/gcc-sparcv9.hpp (original)
+++ trunk/boost/atomic/detail/gcc-sparcv9.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -7,6 +7,12 @@
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Modified: trunk/boost/atomic/detail/gcc-x86.hpp
==============================================================================
--- trunk/boost/atomic/detail/gcc-x86.hpp (original)
+++ trunk/boost/atomic/detail/gcc-x86.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -8,6 +8,12 @@
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Modified: trunk/boost/atomic/detail/generic-cas.hpp
==============================================================================
--- trunk/boost/atomic/detail/generic-cas.hpp (original)
+++ trunk/boost/atomic/detail/generic-cas.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -10,9 +10,14 @@
#include <stdint.h>
#include <boost/memory_order.hpp>
+#include <boost/atomic/detail/config.hpp>
#include <boost/atomic/detail/base.hpp>
#include <boost/atomic/detail/builder.hpp>
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
/* fallback implementation for various compilation targets;
this is *not* efficient, particularly because all operations
are fully fenced (full memory barriers before and after
Modified: trunk/boost/atomic/detail/interlocked.hpp
==============================================================================
--- trunk/boost/atomic/detail/interlocked.hpp (original)
+++ trunk/boost/atomic/detail/interlocked.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -8,6 +8,11 @@
// http://www.boost.org/LICENSE_1_0.txt)
#include <boost/detail/interlocked.hpp>
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
namespace boost {
namespace atomics {
Modified: trunk/boost/atomic/detail/linux-arm.hpp
==============================================================================
--- trunk/boost/atomic/detail/linux-arm.hpp (original)
+++ trunk/boost/atomic/detail/linux-arm.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -31,6 +31,11 @@
// semantics.
#include <boost/memory_order.hpp>
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
namespace boost {
namespace atomics {
Modified: trunk/boost/atomic/detail/lockpool.hpp
==============================================================================
--- trunk/boost/atomic/detail/lockpool.hpp (original)
+++ trunk/boost/atomic/detail/lockpool.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -8,11 +8,15 @@
// http://www.boost.org/LICENSE_1_0.txt)
-#include <boost/atomic/config.hpp>
+#include <boost/atomic/detail/config.hpp>
#ifndef BOOST_ATOMIC_FLAG_LOCK_FREE
#include <boost/thread/mutex.hpp>
#endif
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Copied: trunk/boost/atomic/detail/platform.hpp (from r81931, /trunk/boost/atomic/platform.hpp)
==============================================================================
--- /trunk/boost/atomic/platform.hpp (original)
+++ trunk/boost/atomic/detail/platform.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -1,3 +1,6 @@
+#ifndef BOOST_ATOMIC_DETAIL_PLATFORM_HPP
+#define BOOST_ATOMIC_DETAIL_PLATFORM_HPP
+
// Copyright (c) 2009 Helge Bahmann
//
// Distributed under the Boost Software License, Version 1.0.
@@ -6,7 +9,11 @@
// Platform selection file
-#include <boost/config.hpp>
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__))
@@ -51,3 +58,5 @@
#include <boost/atomic/detail/base.hpp>
#endif
+
+#endif
Modified: trunk/boost/atomic/detail/type-classifier.hpp
==============================================================================
--- trunk/boost/atomic/detail/type-classifier.hpp (original)
+++ trunk/boost/atomic/detail/type-classifier.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
@@ -7,6 +7,12 @@
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
+#include <boost/atomic/detail/config.hpp>
+
+#ifdef BOOST_ATOMIC_HAS_PRAGMA_ONCE
+#pragma once
+#endif
+
namespace boost {
namespace atomics {
namespace detail {
Deleted: trunk/boost/atomic/platform.hpp
==============================================================================
--- trunk/boost/atomic/platform.hpp 2012-12-14 06:13:30 EST (Fri, 14 Dec 2012)
+++ (empty file)
@@ -1,53 +0,0 @@
-// Copyright (c) 2009 Helge Bahmann
-//
-// 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)
-
-// Platform selection file
-
-#include <boost/config.hpp>
-
-#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__))
-
- #include <boost/atomic/detail/gcc-x86.hpp>
-
-#elif 0 && defined(__GNUC__) && defined(__alpha__) /* currently does not work correctly */
-
- #include <boost/atomic/detail/base.hpp>
- #include <boost/atomic/detail/gcc-alpha.hpp>
-
-#elif defined(__GNUC__) && (defined(__POWERPC__) || defined(__PPC__))
-
- #include <boost/atomic/detail/gcc-ppc.hpp>
-
-// This list of ARM architecture versions comes from Apple's arm/arch.h header.
-// I don't know how complete it is.
-#elif defined(__GNUC__) && (defined(__ARM_ARCH_6__) || defined(__ARM_ARCH_6J__) \
- || defined(__ARM_ARCH_6Z__) || defined(__ARM_ARCH_6ZK__) \
- || defined(__ARM_ARCH_6K__) || defined(__ARM_ARCH_7A__))
-
- #include <boost/atomic/detail/gcc-armv6plus.hpp>
-
-#elif defined(__linux__) && defined(__arm__)
-
- #include <boost/atomic/detail/linux-arm.hpp>
-
-#elif defined(__GNUC__) && defined(__sparc_v9__)
-
- #include <boost/atomic/detail/gcc-sparcv9.hpp>
-
-#elif defined(BOOST_USE_WINDOWS_H) || defined(_WIN32_CE) || defined(BOOST_MSVC) || defined(BOOST_INTEL_WIN) || defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
-
- #include <boost/atomic/detail/interlocked.hpp>
-
-#elif 0 && defined(__GNUC__) /* currently does not work correctly */
-
- #include <boost/atomic/detail/base.hpp>
- #include <boost/atomic/detail/gcc-cas.hpp>
-
-#else
-
-#include <boost/atomic/detail/base.hpp>
-
-#endif
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk