xref: /netbsd-src/external/gpl3/gcc.old/dist/libstdc++-v3/include/bits/stringfwd.h (revision 1debfc3d3fad8af6f31804271c18e67f77b4d718)
1*1debfc3dSmrg // <string> Forward declarations -*- C++ -*-
2*1debfc3dSmrg 
3*1debfc3dSmrg // Copyright (C) 2001-2017 Free Software Foundation, Inc.
4*1debfc3dSmrg //
5*1debfc3dSmrg // This file is part of the GNU ISO C++ Library.  This library is free
6*1debfc3dSmrg // software; you can redistribute it and/or modify it under the
7*1debfc3dSmrg // terms of the GNU General Public License as published by the
8*1debfc3dSmrg // Free Software Foundation; either version 3, or (at your option)
9*1debfc3dSmrg // any later version.
10*1debfc3dSmrg 
11*1debfc3dSmrg // This library is distributed in the hope that it will be useful,
12*1debfc3dSmrg // but WITHOUT ANY WARRANTY; without even the implied warranty of
13*1debfc3dSmrg // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14*1debfc3dSmrg // GNU General Public License for more details.
15*1debfc3dSmrg 
16*1debfc3dSmrg // Under Section 7 of GPL version 3, you are granted additional
17*1debfc3dSmrg // permissions described in the GCC Runtime Library Exception, version
18*1debfc3dSmrg // 3.1, as published by the Free Software Foundation.
19*1debfc3dSmrg 
20*1debfc3dSmrg // You should have received a copy of the GNU General Public License and
21*1debfc3dSmrg // a copy of the GCC Runtime Library Exception along with this program;
22*1debfc3dSmrg // see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
23*1debfc3dSmrg // <http://www.gnu.org/licenses/>.
24*1debfc3dSmrg 
25*1debfc3dSmrg /** @file bits/stringfwd.h
26*1debfc3dSmrg  *  This is an internal header file, included by other library headers.
27*1debfc3dSmrg  *  Do not attempt to use it directly. @headername{string}
28*1debfc3dSmrg  */
29*1debfc3dSmrg 
30*1debfc3dSmrg //
31*1debfc3dSmrg // ISO C++ 14882: 21 Strings library
32*1debfc3dSmrg //
33*1debfc3dSmrg 
34*1debfc3dSmrg #ifndef _STRINGFWD_H
35*1debfc3dSmrg #define _STRINGFWD_H 1
36*1debfc3dSmrg 
37*1debfc3dSmrg #pragma GCC system_header
38*1debfc3dSmrg 
39*1debfc3dSmrg #include <bits/c++config.h>
40*1debfc3dSmrg #include <bits/memoryfwd.h>
41*1debfc3dSmrg 
42*1debfc3dSmrg namespace std _GLIBCXX_VISIBILITY(default)
43*1debfc3dSmrg {
44*1debfc3dSmrg _GLIBCXX_BEGIN_NAMESPACE_VERSION
45*1debfc3dSmrg 
46*1debfc3dSmrg   /**
47*1debfc3dSmrg    *  @defgroup strings Strings
48*1debfc3dSmrg    *
49*1debfc3dSmrg    *  @{
50*1debfc3dSmrg   */
51*1debfc3dSmrg 
52*1debfc3dSmrg   template<class _CharT>
53*1debfc3dSmrg     struct char_traits;
54*1debfc3dSmrg 
55*1debfc3dSmrg   template<> struct char_traits<char>;
56*1debfc3dSmrg 
57*1debfc3dSmrg #ifdef _GLIBCXX_USE_WCHAR_T
58*1debfc3dSmrg   template<> struct char_traits<wchar_t>;
59*1debfc3dSmrg #endif
60*1debfc3dSmrg 
61*1debfc3dSmrg #if ((__cplusplus >= 201103L) \
62*1debfc3dSmrg      && defined(_GLIBCXX_USE_C99_STDINT_TR1))
63*1debfc3dSmrg   template<> struct char_traits<char16_t>;
64*1debfc3dSmrg   template<> struct char_traits<char32_t>;
65*1debfc3dSmrg #endif
66*1debfc3dSmrg 
67*1debfc3dSmrg _GLIBCXX_BEGIN_NAMESPACE_CXX11
68*1debfc3dSmrg 
69*1debfc3dSmrg   template<typename _CharT, typename _Traits = char_traits<_CharT>,
70*1debfc3dSmrg            typename _Alloc = allocator<_CharT> >
71*1debfc3dSmrg     class basic_string;
72*1debfc3dSmrg 
73*1debfc3dSmrg   /// A string of @c char
74*1debfc3dSmrg   typedef basic_string<char>    string;
75*1debfc3dSmrg 
76*1debfc3dSmrg #ifdef _GLIBCXX_USE_WCHAR_T
77*1debfc3dSmrg   /// A string of @c wchar_t
78*1debfc3dSmrg   typedef basic_string<wchar_t> wstring;
79*1debfc3dSmrg #endif
80*1debfc3dSmrg 
81*1debfc3dSmrg #if ((__cplusplus >= 201103L) \
82*1debfc3dSmrg      && defined(_GLIBCXX_USE_C99_STDINT_TR1))
83*1debfc3dSmrg   /// A string of @c char16_t
84*1debfc3dSmrg   typedef basic_string<char16_t> u16string;
85*1debfc3dSmrg 
86*1debfc3dSmrg   /// A string of @c char32_t
87*1debfc3dSmrg   typedef basic_string<char32_t> u32string;
88*1debfc3dSmrg #endif
89*1debfc3dSmrg 
90*1debfc3dSmrg _GLIBCXX_END_NAMESPACE_CXX11
91*1debfc3dSmrg 
92*1debfc3dSmrg   /** @}  */
93*1debfc3dSmrg 
94*1debfc3dSmrg _GLIBCXX_END_NAMESPACE_VERSION
95*1debfc3dSmrg } // namespace std
96*1debfc3dSmrg 
97*1debfc3dSmrg #endif	// _STRINGFWD_H
98