OSDN Git Service

2010-10-28 Paolo Carlini <paolo.carlini@oracle.com>
[pf3gnuchains/gcc-fork.git] / libstdc++-v3 / include / bits / atomicfwd_cxx.h
1 // -*- C++ -*- header.
2
3 // Copyright (C) 2008, 2009, 2010
4 // Free Software Foundation, Inc.
5 //
6 // This file is part of the GNU ISO C++ Library.  This library is free
7 // software; you can redistribute it and/or modify it under the
8 // terms of the GNU General Public License as published by the
9 // Free Software Foundation; either version 3, or (at your option)
10 // any later version.
11
12 // This library is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 // GNU General Public License for more details.
16
17 // Under Section 7 of GPL version 3, you are granted additional
18 // permissions described in the GCC Runtime Library Exception, version
19 // 3.1, as published by the Free Software Foundation.
20
21 // You should have received a copy of the GNU General Public License and
22 // a copy of the GCC Runtime Library Exception along with this program;
23 // see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
24 // <http://www.gnu.org/licenses/>.
25
26 /** @file bits/atomicfwd_cxx.h
27  *  This is an internal header file, included by other library headers.
28  *  You should not attempt to use it directly.
29  */
30
31 // "C++" only bits.
32
33 #define _ATOMIC_MEMBER_ _M_i
34
35 _GLIBCXX_END_EXTERN_C
36
37   namespace __atomic0
38   {
39     template<typename _IntTp>
40       struct __atomic_base;
41
42     struct atomic_flag;
43     struct atomic_address;
44     struct atomic_bool;
45   } 
46
47   namespace __atomic2
48   {
49     template<typename _IntTp>
50       struct __atomic_base;
51
52     struct atomic_flag;
53     struct atomic_address;
54     struct atomic_bool;
55   } 
56
57   namespace __atomic1
58   {
59     using __atomic2::atomic_flag;
60     using __atomic2::atomic_bool;
61     using __atomic0::atomic_address;
62     using __atomic0::__atomic_base;
63   } 
64
65   /**
66    * @addtogroup atomics
67    * @{
68    */
69
70   /// atomic_char
71   typedef __atomic_base<char>                   atomic_char;
72
73   /// atomic_schar
74   typedef __atomic_base<signed char>            atomic_schar;
75
76   /// atomic_uchar
77   typedef __atomic_base<unsigned char>          atomic_uchar;
78
79   /// atomic_short
80   typedef __atomic_base<short>                  atomic_short;
81
82   /// atomic_ushort
83   typedef __atomic_base<unsigned short>         atomic_ushort;
84
85   /// atomic_int
86   typedef __atomic_base<int>                    atomic_int;
87
88   /// atomic_uint
89   typedef __atomic_base<unsigned int>           atomic_uint;
90
91   /// atomic_long
92   typedef __atomic_base<long>                   atomic_long;
93
94   /// atomic_ulong
95   typedef __atomic_base<unsigned long>          atomic_ulong;
96
97   /// atomic_llong
98   typedef __atomic_base<long long>              atomic_llong;
99
100   /// atomic_ullong
101   typedef __atomic_base<unsigned long long>     atomic_ullong;
102
103   /// atomic_wchar_t
104   typedef __atomic_base<wchar_t>                atomic_wchar_t;
105
106   /// atomic_char16_t
107   typedef __atomic_base<char16_t>               atomic_char16_t;
108
109   /// atomic_char32_t
110   typedef __atomic_base<char32_t>               atomic_char32_t;
111
112   template<typename _Tp>
113     struct atomic;
114
115   // @} group atomics
116
117 _GLIBCXX_BEGIN_EXTERN_C