32#ifdef _RWSTD_REENTRANT
33# ifdef _RWSTD_OS_SUNOS
38# define _RWSTD_THREAD_ONCE(once, func) pthread_once (once, func)
39# define _RWSTD_THREAD_YIELD() thr_yield ()
40# define _RWSTD_ONCE_INIT PTHREAD_ONCE_INIT
42typedef pthread_once_t __rw_once_t;
44# elif defined (_RWSTD_POSIX_THREADS)
48# ifndef _RWSTD_NO_PTHREAD_ONCE
50typedef pthread_once_t __rw_once_t;
52# define _RWSTD_THREAD_ONCE(once, func) pthread_once (once, func)
53# define _RWSTD_ONCE_INIT PTHREAD_ONCE_INIT
60 pthread_mutex_t _C_mutex;
66# define _RWSTD_ONCE_INIT { PTHREAD_MUTEX_INITIALIZER, -1 }
70# ifndef _RWSTD_NO_SCHED_YIELD
71# define _RWSTD_THREAD_YIELD() sched_yield ()
73# elif defined (_RWSTD_DCE_THREADS)
75# if defined (_RWSTD_NO_DCE_PTHREAD_H)
78# include <dce/pthread.h>
83typedef pthread_once_t __rw_once_t;
87# define _RWSTD_THREAD_ONCE(once, func) pthread_once (once, func)
88# define _RWSTD_THREAD_YIELD() pthread_yield ()
89# define _RWSTD_ONCE_INIT PTHREAD_ONCE_INIT
91# elif defined (_WIN32)
97struct __rw_once_t {
int _C_init; };
101# define _RWSTD_THREAD_YIELD() Sleep (0)
102# define _RWSTD_ONCE_INIT { 0 }
107struct __rw_once_t {
int _C_init; };
111# define _RWSTD_ONCE_INIT { 0 }
117struct __rw_once_t {
int _C_init; };
123# define _RWSTD_ONCE_INIT { -1 }
127#ifndef _RWSTD_THREAD_YIELD
128# define _RWSTD_THREAD_YIELD() (void)0
136#if !defined (_RWSTD_MSVC) || !defined (_RWSTD_REENTRANT)
139__rw_once (__rw_once_t*,
void (*)());
154__rw_once (__rw_once_t*,
void (*)()
throw (...))
throw (...);
#define _RWSTD_NAMESPACE(name)