Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r75802 - trunk/boost/thread/win32
From: vicente.botet_at_[hidden]
Date: 2011-12-04 10:18:33


Author: viboes
Date: 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
New Revision: 75802
URL: http://svn.boost.org/trac/boost/changeset/75802

Log:
Thread: #3762 Thread can't be compiled with winscw (Codewarrior by Nokia) (win part)
Text files modified:
   trunk/boost/thread/win32/basic_recursive_mutex.hpp | 14 +++++-----
   trunk/boost/thread/win32/basic_timed_mutex.hpp | 22 ++++++++--------
   trunk/boost/thread/win32/condition_variable.hpp | 54 ++++++++++++++++++++--------------------
   trunk/boost/thread/win32/mutex.hpp | 2
   trunk/boost/thread/win32/recursive_mutex.hpp | 8 ++--
   trunk/boost/thread/win32/thread_data.hpp | 16 +++++-----
   trunk/boost/thread/win32/thread_heap_alloc.hpp | 10 +++---
   7 files changed, 63 insertions(+), 63 deletions(-)

Modified: trunk/boost/thread/win32/basic_recursive_mutex.hpp
==============================================================================
--- trunk/boost/thread/win32/basic_recursive_mutex.hpp (original)
+++ trunk/boost/thread/win32/basic_recursive_mutex.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -3,14 +3,14 @@
 
 // basic_recursive_mutex.hpp
 //
-// (C) Copyright 2006-8 Anthony Williams
+// (C) Copyright 2006-8 Anthony Williams
 //
 // 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 "thread_primitives.hpp"
-#include "basic_timed_mutex.hpp"
+#include <boost/thread/win32/thread_primitives.hpp>
+#include <boost/thread/win32/basic_timed_mutex.hpp>
 
 #include <boost/config/abi_prefix.hpp>
 
@@ -42,7 +42,7 @@
                 long const current_thread_id=win32::GetCurrentThreadId();
                 return try_recursive_lock(current_thread_id) || try_basic_lock(current_thread_id);
             }
-
+
             void lock()
             {
                 long const current_thread_id=win32::GetCurrentThreadId();
@@ -83,7 +83,7 @@
                 }
                 return false;
             }
-
+
             bool try_basic_lock(long current_thread_id)
             {
                 if(mutex.try_lock())
@@ -94,7 +94,7 @@
                 }
                 return false;
             }
-
+
             bool try_timed_lock(long current_thread_id,::boost::system_time const& target)
             {
                 if(mutex.timed_lock(target))
@@ -105,7 +105,7 @@
                 }
                 return false;
             }
-
+
         };
 
         typedef basic_recursive_mutex_impl<basic_timed_mutex> basic_recursive_mutex;

Modified: trunk/boost/thread/win32/basic_timed_mutex.hpp
==============================================================================
--- trunk/boost/thread/win32/basic_timed_mutex.hpp (original)
+++ trunk/boost/thread/win32/basic_timed_mutex.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -3,15 +3,15 @@
 
 // basic_timed_mutex_win32.hpp
 //
-// (C) Copyright 2006-8 Anthony Williams
+// (C) Copyright 2006-8 Anthony Williams
 //
 // 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/assert.hpp>
-#include "thread_primitives.hpp"
-#include "interlocked_read.hpp"
+#include <boost/thread/win32/thread_primitives.hpp>
+#include <boost/thread/win32/interlocked_read.hpp>
 #include <boost/thread/thread_time.hpp>
 #include <boost/thread/xtime.hpp>
 #include <boost/detail/interlocked.hpp>
@@ -52,13 +52,13 @@
                     win32::CloseHandle(old_event);
                 }
             }
-
-
+
+
             bool try_lock()
             {
                 return !win32::interlocked_bit_test_and_set(&active_count,lock_flag_bit);
             }
-
+
             void lock()
             {
                 if(try_lock())
@@ -112,8 +112,8 @@
                     old_count=current;
                 }
             }
-
-
+
+
             bool timed_lock(::boost::system_time const& wait_until)
             {
                 if(try_lock())
@@ -171,7 +171,7 @@
             void* get_event()
             {
                 void* current_event=::boost::detail::interlocked_read_acquire(&event);
-
+
                 if(!current_event)
                 {
                     void* const new_event=win32::create_anonymous_event(win32::auto_reset_event,win32::event_initially_reset);
@@ -196,9 +196,9 @@
                 }
                 return current_event;
             }
-
+
         };
-
+
     }
 }
 

Modified: trunk/boost/thread/win32/condition_variable.hpp
==============================================================================
--- trunk/boost/thread/win32/condition_variable.hpp (original)
+++ trunk/boost/thread/win32/condition_variable.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -6,13 +6,13 @@
 // (C) Copyright 2007-8 Anthony Williams
 
 #include <boost/thread/mutex.hpp>
-#include "thread_primitives.hpp"
+#include <boost/thread/win32/thread_primitives.hpp>
 #include <limits.h>
 #include <boost/assert.hpp>
 #include <algorithm>
 #include <boost/thread/thread.hpp>
 #include <boost/thread/thread_time.hpp>
-#include "interlocked_read.hpp"
+#include <boost/thread/win32/interlocked_read.hpp>
 #include <boost/thread/xtime.hpp>
 #include <vector>
 #include <boost/intrusive_ptr.hpp>
@@ -26,7 +26,7 @@
         class basic_cv_list_entry;
         void intrusive_ptr_add_ref(basic_cv_list_entry * p);
         void intrusive_ptr_release(basic_cv_list_entry * p);
-
+
         class basic_cv_list_entry
         {
         private:
@@ -38,7 +38,7 @@
 
             basic_cv_list_entry(basic_cv_list_entry&);
             void operator=(basic_cv_list_entry&);
-
+
         public:
             explicit basic_cv_list_entry(detail::win32::handle_manager const& wake_sem_):
                 semaphore(detail::win32::create_anonymous_semaphore(0,LONG_MAX)),
@@ -55,7 +55,7 @@
             {
                 BOOST_INTERLOCKED_INCREMENT(&waiters);
             }
-
+
             void remove_waiter()
             {
                 BOOST_INTERLOCKED_DECREMENT(&waiters);
@@ -97,7 +97,7 @@
         {
             BOOST_INTERLOCKED_INCREMENT(&p->references);
         }
-
+
         inline void intrusive_ptr_release(basic_cv_list_entry * p)
         {
             if(!BOOST_INTERLOCKED_DECREMENT(&p->references))
@@ -125,13 +125,13 @@
                 detail::interlocked_write_release(&total_count,total_count-count_to_wake);
                 detail::win32::ReleaseSemaphore(wake_sem,count_to_wake,0);
             }
-
+
             template<typename lock_type>
             struct relocker
             {
                 lock_type& lock;
                 bool unlocked;
-
+
                 relocker(lock_type& lock_):
                     lock(lock_),unlocked(false)
                 {}
@@ -146,13 +146,13 @@
                     {
                         lock.lock();
                     }
-
+
                 }
             private:
                 relocker(relocker&);
                 void operator=(relocker&);
             };
-
+
 
             entry_ptr get_wait_entry()
             {
@@ -177,15 +177,15 @@
                     return generations.back();
                 }
             }
-
+
             struct entry_manager
             {
                 entry_ptr const entry;
-
+
                 entry_manager(entry_ptr const& entry_):
                     entry(entry_)
                 {}
-
+
                 ~entry_manager()
                 {
                     entry->remove_waiter();
@@ -200,14 +200,14 @@
                 void operator=(entry_manager&);
                 entry_manager(entry_manager&);
             };
-
+
 
         protected:
             template<typename lock_type>
             bool do_wait(lock_type& lock,timeout wait_until)
             {
                 relocker<lock_type> locker(lock);
-
+
                 entry_manager entry(get_wait_entry());
 
                 locker.unlock();
@@ -219,7 +219,7 @@
                     {
                         return false;
                     }
-
+
                     woken=entry->woken();
                 }
                 return woken;
@@ -235,7 +235,7 @@
                 }
                 return true;
             }
-
+
             basic_condition_variable(const basic_condition_variable& other);
             basic_condition_variable& operator=(const basic_condition_variable& other);
 
@@ -243,7 +243,7 @@
             basic_condition_variable():
                 total_count(0),active_generation_count(0),wake_sem(0)
             {}
-
+
             ~basic_condition_variable()
             {}
 
@@ -267,7 +267,7 @@
                     generations.erase(std::remove_if(generations.begin(),generations.end(),&basic_cv_list_entry::no_waiters),generations.end());
                 }
             }
-
+
             void notify_all()
             {
                 if(detail::interlocked_read_acquire(&total_count))
@@ -288,7 +288,7 @@
                     wake_sem=detail::win32::handle(0);
                 }
             }
-
+
         };
     }
 
@@ -301,10 +301,10 @@
     public:
         condition_variable()
         {}
-
+
         using detail::basic_condition_variable::notify_one;
         using detail::basic_condition_variable::notify_all;
-
+
         void wait(unique_lock<mutex>& m)
         {
             do_wait(m,detail::timeout::sentinel());
@@ -315,7 +315,7 @@
         {
             while(!pred()) wait(m);
         }
-
+
 
         bool timed_wait(unique_lock<mutex>& m,boost::system_time const& wait_until)
         {
@@ -348,7 +348,7 @@
             return do_wait(m,wait_duration.total_milliseconds(),pred);
         }
     };
-
+
     class condition_variable_any:
         private detail::basic_condition_variable
     {
@@ -358,10 +358,10 @@
     public:
         condition_variable_any()
         {}
-
+
         using detail::basic_condition_variable::notify_one;
         using detail::basic_condition_variable::notify_all;
-
+
         template<typename lock_type>
         void wait(lock_type& m)
         {
@@ -373,7 +373,7 @@
         {
             while(!pred()) wait(m);
         }
-
+
         template<typename lock_type>
         bool timed_wait(lock_type& m,boost::system_time const& wait_until)
         {

Modified: trunk/boost/thread/win32/mutex.hpp
==============================================================================
--- trunk/boost/thread/win32/mutex.hpp (original)
+++ trunk/boost/thread/win32/mutex.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -5,7 +5,7 @@
 // accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt)
 
-#include "basic_timed_mutex.hpp"
+#include <boost/thread/win32/basic_timed_mutex.hpp>
 #include <boost/utility.hpp>
 #include <boost/thread/exceptions.hpp>
 #include <boost/thread/locks.hpp>

Modified: trunk/boost/thread/win32/recursive_mutex.hpp
==============================================================================
--- trunk/boost/thread/win32/recursive_mutex.hpp (original)
+++ trunk/boost/thread/win32/recursive_mutex.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -3,7 +3,7 @@
 
 // recursive_mutex.hpp
 //
-// (C) Copyright 2006-7 Anthony Williams
+// (C) Copyright 2006-7 Anthony Williams
 //
 // Distributed under the Boost Software License, Version 1.0. (See
 // accompanying file LICENSE_1_0.txt or copy at
@@ -11,7 +11,7 @@
 
 
 #include <boost/utility.hpp>
-#include "basic_recursive_mutex.hpp"
+#include <boost/thread/win32/basic_recursive_mutex.hpp>
 #include <boost/thread/exceptions.hpp>
 #include <boost/thread/locks.hpp>
 
@@ -24,7 +24,7 @@
     {
     private:
         recursive_mutex(recursive_mutex const&);
- recursive_mutex& operator=(recursive_mutex const&);
+ recursive_mutex& operator=(recursive_mutex const&);
     public:
         recursive_mutex()
         {
@@ -46,7 +46,7 @@
     {
     private:
         recursive_timed_mutex(recursive_timed_mutex const&);
- recursive_timed_mutex& operator=(recursive_timed_mutex const&);
+ recursive_timed_mutex& operator=(recursive_timed_mutex const&);
     public:
         recursive_timed_mutex()
         {

Modified: trunk/boost/thread/win32/thread_data.hpp
==============================================================================
--- trunk/boost/thread/win32/thread_data.hpp (original)
+++ trunk/boost/thread/win32/thread_data.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -8,8 +8,8 @@
 #include <boost/thread/detail/config.hpp>
 #include <boost/intrusive_ptr.hpp>
 #include <boost/thread/thread_time.hpp>
-#include "thread_primitives.hpp"
-#include "thread_heap_alloc.hpp"
+#include <boost/thread/win32/thread_primitives.hpp>
+#include <boost/thread/win32/thread_heap_alloc.hpp>
 
 #include <boost/config/abi_prefix.hpp>
 
@@ -23,7 +23,7 @@
         struct thread_data_base;
         void intrusive_ptr_add_ref(thread_data_base * p);
         void intrusive_ptr_release(thread_data_base * p);
-
+
         struct BOOST_SYMBOL_VISIBLE thread_data_base
         {
             long count;
@@ -48,7 +48,7 @@
             {
                 BOOST_INTERLOCKED_INCREMENT(&p->count);
             }
-
+
             friend void intrusive_ptr_release(thread_data_base * p)
             {
                 if(!BOOST_INTERLOCKED_DECREMENT(&p->count))
@@ -61,7 +61,7 @@
             {
                 BOOST_VERIFY(detail::win32::SetEvent(interruption_handle)!=0);
             }
-
+
             typedef detail::win32::handle native_handle_type;
 
             virtual void run()=0;
@@ -130,7 +130,7 @@
             {
                 return milliseconds==~uintmax_t(0);
             }
-
+
 
             static timeout sentinel()
             {
@@ -139,7 +139,7 @@
         private:
             struct sentinel_type
             {};
-
+
             explicit timeout(sentinel_type):
                 start(0),milliseconds(~uintmax_t(0)),relative(true)
             {}
@@ -175,7 +175,7 @@
             interruptible_wait(abs_time);
         }
     }
-
+
 }
 
 #include <boost/config/abi_suffix.hpp>

Modified: trunk/boost/thread/win32/thread_heap_alloc.hpp
==============================================================================
--- trunk/boost/thread/win32/thread_heap_alloc.hpp (original)
+++ trunk/boost/thread/win32/thread_heap_alloc.hpp 2011-12-04 10:18:32 EST (Sun, 04 Dec 2011)
@@ -5,7 +5,7 @@
 #ifndef THREAD_HEAP_ALLOC_HPP
 #define THREAD_HEAP_ALLOC_HPP
 #include <new>
-#include "thread_primitives.hpp"
+#include <boost/thread/win32/thread_primitives.hpp>
 #include <stdexcept>
 #include <boost/assert.hpp>
 #include <boost/throw_exception.hpp>
@@ -70,7 +70,7 @@
         {
             BOOST_VERIFY(detail::win32::HeapFree(detail::win32::GetProcessHeap(),0,heap_memory)!=0);
         }
-
+
         template<typename T>
         inline T* heap_new()
         {
@@ -226,7 +226,7 @@
         {
             return heap_new_impl<T,A1&>(a1);
         }
-
+
         template<typename T,typename A1,typename A2>
         inline T* heap_new(A1 const& a1,A2 const& a2)
         {
@@ -372,8 +372,8 @@
         {
             return heap_new_impl<T,A1&,A2&,A3&,A4&>(a1,a2,a3,a4);
         }
-
-#endif
+
+#endif
         template<typename T>
         inline void heap_delete(T* data)
         {


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