1// -*- C++ -*-
2//===--------------------------- iosfwd -----------------------------------===//
3//
4//                     The LLVM Compiler Infrastructure
5//
6// This file is dual licensed under the MIT and the University of Illinois Open
7// Source Licenses. See LICENSE.TXT for details.
8//
9//===----------------------------------------------------------------------===//
10
11#ifndef _LIBCPP_IOSFWD
12#define _LIBCPP_IOSFWD
13
14/*
15    iosfwd synopsis
16
17namespace std
18{
19
20template<class charT> struct char_traits;
21template<class T>     class allocator;
22
23class ios_base;
24template <class charT, class traits = char_traits<charT> > class basic_ios;
25
26template <class charT, class traits = char_traits<charT> > class basic_streambuf;
27template <class charT, class traits = char_traits<charT> > class basic_istream;
28template <class charT, class traits = char_traits<charT> > class basic_ostream;
29template <class charT, class traits = char_traits<charT> > class basic_iostream;
30
31template <class charT, class traits = char_traits<charT>, class Allocator = allocator<charT> >
32    class basic_stringbuf;
33template <class charT, class traits = char_traits<charT>, class Allocator = allocator<charT> >
34    class basic_istringstream;
35template <class charT, class traits = char_traits<charT>, class Allocator = allocator<charT> >
36    class basic_ostringstream;
37template <class charT, class traits = char_traits<charT>, class Allocator = allocator<charT> >
38    class basic_stringstream;
39
40template <class charT, class traits = char_traits<charT> > class basic_filebuf;
41template <class charT, class traits = char_traits<charT> > class basic_ifstream;
42template <class charT, class traits = char_traits<charT> > class basic_ofstream;
43template <class charT, class traits = char_traits<charT> > class basic_fstream;
44
45template <class charT, class traits = char_traits<charT> > class istreambuf_iterator;
46template <class charT, class traits = char_traits<charT> > class ostreambuf_iterator;
47
48typedef basic_ios<char>              ios;
49typedef basic_ios<wchar_t>           wios;
50
51typedef basic_streambuf<char>        streambuf;
52typedef basic_istream<char>          istream;
53typedef basic_ostream<char>          ostream;
54typedef basic_iostream<char>         iostream;
55
56typedef basic_stringbuf<char>        stringbuf;
57typedef basic_istringstream<char>    istringstream;
58typedef basic_ostringstream<char>    ostringstream;
59typedef basic_stringstream<char>     stringstream;
60
61typedef basic_filebuf<char>          filebuf;
62typedef basic_ifstream<char>         ifstream;
63typedef basic_ofstream<char>         ofstream;
64typedef basic_fstream<char>          fstream;
65
66typedef basic_streambuf<wchar_t>     wstreambuf;
67typedef basic_istream<wchar_t>       wistream;
68typedef basic_ostream<wchar_t>       wostream;
69typedef basic_iostream<wchar_t>      wiostream;
70
71typedef basic_stringbuf<wchar_t>     wstringbuf;
72typedef basic_istringstream<wchar_t> wistringstream;
73typedef basic_ostringstream<wchar_t> wostringstream;
74typedef basic_stringstream<wchar_t>  wstringstream;
75
76typedef basic_filebuf<wchar_t>       wfilebuf;
77typedef basic_ifstream<wchar_t>      wifstream;
78typedef basic_ofstream<wchar_t>      wofstream;
79typedef basic_fstream<wchar_t>       wfstream;
80
81template <class state> class fpos;
82typedef fpos<char_traits<char>::state_type>    streampos;
83typedef fpos<char_traits<wchar_t>::state_type> wstreampos;
84
85}  // std
86
87*/
88
89#include <__config>
90#include <wchar.h>  // for mbstate_t
91
92#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
93#pragma GCC system_header
94#endif
95
96_LIBCPP_BEGIN_NAMESPACE_STD
97
98class _LIBCPP_TYPE_VIS ios_base;
99
100template<class _CharT>  struct _LIBCPP_TYPE_VIS_ONLY char_traits;
101template<class _Tp>     class _LIBCPP_TYPE_VIS_ONLY allocator;
102
103template <class _CharT, class _Traits = char_traits<_CharT> >
104    class _LIBCPP_TYPE_VIS_ONLY basic_ios;
105
106template <class _CharT, class _Traits = char_traits<_CharT> >
107    class _LIBCPP_TYPE_VIS_ONLY basic_streambuf;
108template <class _CharT, class _Traits = char_traits<_CharT> >
109    class _LIBCPP_TYPE_VIS_ONLY basic_istream;
110template <class _CharT, class _Traits = char_traits<_CharT> >
111    class _LIBCPP_TYPE_VIS_ONLY basic_ostream;
112template <class _CharT, class _Traits = char_traits<_CharT> >
113    class _LIBCPP_TYPE_VIS_ONLY basic_iostream;
114
115template <class _CharT, class _Traits = char_traits<_CharT>,
116          class _Allocator = allocator<_CharT> >
117    class _LIBCPP_TYPE_VIS_ONLY basic_stringbuf;
118template <class _CharT, class _Traits = char_traits<_CharT>,
119          class _Allocator = allocator<_CharT> >
120    class _LIBCPP_TYPE_VIS_ONLY basic_istringstream;
121template <class _CharT, class _Traits = char_traits<_CharT>,
122          class _Allocator = allocator<_CharT> >
123    class _LIBCPP_TYPE_VIS_ONLY basic_ostringstream;
124template <class _CharT, class _Traits = char_traits<_CharT>,
125          class _Allocator = allocator<_CharT> >
126    class _LIBCPP_TYPE_VIS_ONLY basic_stringstream;
127
128template <class _CharT, class _Traits = char_traits<_CharT> >
129    class _LIBCPP_TYPE_VIS_ONLY basic_filebuf;
130template <class _CharT, class _Traits = char_traits<_CharT> >
131    class _LIBCPP_TYPE_VIS_ONLY basic_ifstream;
132template <class _CharT, class _Traits = char_traits<_CharT> >
133    class _LIBCPP_TYPE_VIS_ONLY basic_ofstream;
134template <class _CharT, class _Traits = char_traits<_CharT> >
135    class _LIBCPP_TYPE_VIS_ONLY basic_fstream;
136
137template <class _CharT, class _Traits = char_traits<_CharT> >
138    class _LIBCPP_TYPE_VIS_ONLY istreambuf_iterator;
139template <class _CharT, class _Traits = char_traits<_CharT> >
140    class _LIBCPP_TYPE_VIS_ONLY ostreambuf_iterator;
141
142typedef basic_ios<char>              ios;
143typedef basic_ios<wchar_t>           wios;
144
145typedef basic_streambuf<char>        streambuf;
146typedef basic_istream<char>          istream;
147typedef basic_ostream<char>          ostream;
148typedef basic_iostream<char>         iostream;
149
150typedef basic_stringbuf<char>        stringbuf;
151typedef basic_istringstream<char>    istringstream;
152typedef basic_ostringstream<char>    ostringstream;
153typedef basic_stringstream<char>     stringstream;
154
155typedef basic_filebuf<char>          filebuf;
156typedef basic_ifstream<char>         ifstream;
157typedef basic_ofstream<char>         ofstream;
158typedef basic_fstream<char>          fstream;
159
160typedef basic_streambuf<wchar_t>     wstreambuf;
161typedef basic_istream<wchar_t>       wistream;
162typedef basic_ostream<wchar_t>       wostream;
163typedef basic_iostream<wchar_t>      wiostream;
164
165typedef basic_stringbuf<wchar_t>     wstringbuf;
166typedef basic_istringstream<wchar_t> wistringstream;
167typedef basic_ostringstream<wchar_t> wostringstream;
168typedef basic_stringstream<wchar_t>  wstringstream;
169
170typedef basic_filebuf<wchar_t>       wfilebuf;
171typedef basic_ifstream<wchar_t>      wifstream;
172typedef basic_ofstream<wchar_t>      wofstream;
173typedef basic_fstream<wchar_t>       wfstream;
174
175template <class _State>             class _LIBCPP_TYPE_VIS_ONLY fpos;
176typedef fpos<mbstate_t>    streampos;
177typedef fpos<mbstate_t>    wstreampos;
178#ifndef _LIBCPP_HAS_NO_UNICODE_CHARS
179typedef fpos<mbstate_t>    u16streampos;
180typedef fpos<mbstate_t>    u32streampos;
181#endif  // _LIBCPP_HAS_NO_UNICODE_CHARS
182
183typedef long long streamoff;        // for char_traits in <string>
184
185template <class _CharT,             // for <stdexcept>
186          class _Traits = char_traits<_CharT>,
187          class _Allocator = allocator<_CharT> >
188    class _LIBCPP_TYPE_VIS_ONLY basic_string;
189typedef basic_string<char, char_traits<char>, allocator<char> > string;
190typedef basic_string<wchar_t, char_traits<wchar_t>, allocator<wchar_t> > wstring;
191
192_LIBCPP_END_NAMESPACE_STD
193
194#endif  // _LIBCPP_IOSFWD
195