OSDN Git Service

2002-01-04 Benjamin Kosnik <bkoz@redhat.com>
[pf3gnuchains/gcc-fork.git] / libstdc++-v3 / src / misc-inst.cc
1 // Explicit instantiation file.
2
3 // Copyright (C) 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
4 //
5 // This file is part of the GNU ISO C++ Library.  This library is free
6 // software; you can redistribute it and/or modify it under the
7 // terms of the GNU General Public License as published by the
8 // Free Software Foundation; either version 2, or (at your option)
9 // any later version.
10
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 // GNU General Public License for more details.
15
16 // You should have received a copy of the GNU General Public License along
17 // with this library; see the file COPYING.  If not, write to the Free
18 // Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
19 // USA.
20
21 // As a special exception, you may use this file as part of a free software
22 // library without restriction.  Specifically, if other files instantiate
23 // templates or use macros or inline functions from this file, or you compile
24 // this file and link it with other files to produce an executable, this
25 // file does not by itself cause the resulting executable to be covered by
26 // the GNU General Public License.  This exception does not however
27 // invalidate any other reasons why the executable file might be covered by
28 // the GNU General Public License.
29
30 //
31 // ISO C++ 14882:
32 //
33
34 #include <string>
35 #include <algorithm>
36 #include <locale>
37 #include <vector>
38 #include <iterator>
39 #include <streambuf>
40 #include <sstream>
41 #include <fstream>
42 #include <ios>
43 #include <istream>
44 #include <ostream>
45 #include <iomanip>
46
47 // NB: unnecessary if the .h headers include these
48 #ifndef  _GLIBCPP_FULLY_COMPLIANT_HEADERS
49 #include <bits/sstream.tcc>
50 #include <bits/fstream.tcc>
51 #include <bits/streambuf.tcc>
52 #include <bits/istream.tcc>
53 #include <bits/ostream.tcc>
54 #endif
55
56 namespace std
57 {
58
59   //
60   // streambuf
61   // 
62   template class basic_streambuf<char>;
63 #ifdef _GLIBCPP_USE_WCHAR_T
64   template class basic_streambuf<wchar_t>;
65 #endif
66
67
68   //
69   // stringstream
70   //
71   template class basic_stringbuf<char>;
72 #ifdef _GLIBCPP_USE_WCHAR_T
73   template class basic_stringbuf<wchar_t>;
74 #endif
75
76
77   //
78   // fstream
79   //
80   template class basic_filebuf<char, char_traits<char> >;
81 #ifdef _GLIBCPP_USE_WCHAR_T
82   template class basic_filebuf<wchar_t, char_traits<wchar_t> >;
83 #endif
84
85
86   //
87   // basic_ios
88   //
89   template class basic_ios<char>;
90 #ifdef _GLIBCPP_USE_WCHAR_T
91   template class basic_ios<wchar_t>;
92 #endif
93
94
95   //
96   // iomanip
97   //
98   template class _Setfill<char>;
99   template _Setfill<char> setfill(char);
100 #ifdef _GLIBCPP_USE_WCHAR_T
101   template class _Setfill<wchar_t>;
102   template _Setfill<wchar_t> setfill(wchar_t);
103 #endif
104
105
106   //
107   // istream
108   //
109   template class basic_istream<char>;
110   template istream& ws(istream&);
111   template istream& operator>>(istream&, char&);
112   template istream& operator>>(istream&, unsigned char&);
113   template istream& operator>>(istream&, signed char&);
114   template istream& operator>>(istream&, char*);
115   template istream& operator>>(istream&, unsigned char*);
116   template istream& operator>>(istream&, signed char*);
117
118   template istream& operator>>(istream&, _Setiosflags);
119   template istream& operator>>(istream&, _Resetiosflags);
120   template istream& operator>>(istream&, _Setbase);
121   template istream& operator>>(istream&, _Setfill<char>);
122   template istream& operator>>(istream&, _Setprecision);
123   template istream& operator>>(istream&, _Setw);
124
125 #ifdef _GLIBCPP_USE_WCHAR_T
126   template class basic_istream<wchar_t>;
127   template wistream& ws(wistream&);
128   template wistream& operator>>(wistream&, wchar_t&);
129   template wistream& operator>>(wistream&, wchar_t*);
130   template wistream& operator>>(wistream&, _Setfill<wchar_t>);
131 #endif
132
133
134   //
135   // ostream
136   //
137   template class basic_ostream<char>;
138   template ostream& endl(ostream&);
139   template ostream& ends(ostream&);
140   template ostream& flush(ostream&);
141   template ostream& operator<<(ostream&, char);
142   template ostream& operator<<(ostream&, unsigned char);
143   template ostream& operator<<(ostream&, signed char);
144   template ostream& operator<<(ostream&, const char*);
145   template ostream& operator<<(ostream&, const unsigned char*);
146   template ostream& operator<<(ostream&, const signed char*);
147
148   template ostream& operator<<(ostream&, _Setiosflags);
149   template ostream& operator<<(ostream&, _Resetiosflags);
150   template ostream& operator<<(ostream&, _Setbase);
151   template ostream& operator<<(ostream&, _Setfill<char>);
152   template ostream& operator<<(ostream&, _Setprecision);
153   template ostream& operator<<(ostream&, _Setw);
154
155 #ifdef _GLIBCPP_USE_WCHAR_T
156   template class basic_ostream<wchar_t>;
157   template wostream& endl(wostream&);
158   template wostream& ends(wostream&);
159   template wostream& flush(wostream&);
160   template wostream& operator<<(wostream&, wchar_t);
161   template wostream& operator<<(wostream&, char);
162   template wostream& operator<<(wostream&, const wchar_t*);
163   template wostream& operator<<(wostream&, const char*);
164   template wostream& operator<<(wostream&, _Setfill<wchar_t>);
165 #endif
166   
167
168   //
169   // iostream
170   //
171   template class basic_iostream<char>;
172 #ifdef _GLIBCPP_USE_WCHAR_T
173   template class basic_iostream<wchar_t>; 
174 #endif
175
176
177   //
178   // ifstream
179   //
180   template class basic_ifstream<char>;
181 #ifdef _GLIBCPP_USE_WCHAR_T
182   template class basic_ifstream<wchar_t>;
183 #endif
184
185
186   //
187   // ofstream
188   //
189   template class basic_ofstream<char>;
190 #ifdef _GLIBCPP_USE_WCHAR_T
191   template class basic_ofstream<wchar_t>;
192 #endif
193
194
195   //
196   // istringstream
197   //
198   template class basic_istringstream<char>;
199 #ifdef _GLIBCPP_USE_WCHAR_T
200   template class basic_istringstream<wchar_t>; 
201 #endif
202
203
204   //
205   // ostringstream
206   //
207   template class basic_ostringstream<char>;
208 #ifdef _GLIBCPP_USE_WCHAR_T
209   template class basic_ostringstream<wchar_t>; 
210 #endif
211
212
213   //
214   // string related to iostreams
215   //
216   template 
217     basic_istream<char>& 
218     operator>>(basic_istream<char>&, string&);
219   template 
220     basic_ostream<char>& 
221     operator<<(basic_ostream<char>&, const string&);
222   template 
223     basic_istream<char>& 
224     getline(basic_istream<char>&, string&, char);
225   template 
226     basic_istream<char>& 
227     getline(basic_istream<char>&, string&);
228 #ifdef _GLIBCPP_USE_WCHAR_T
229   template 
230     basic_istream<wchar_t>& 
231     operator>>(basic_istream<wchar_t>&, wstring&);
232   template 
233     basic_ostream<wchar_t>& 
234     operator<<(basic_ostream<wchar_t>&, const wstring&);
235   template 
236     basic_istream<wchar_t>& 
237     getline(basic_istream<wchar_t>&, wstring&, wchar_t);
238   template 
239     basic_istream<wchar_t>& 
240     getline(basic_istream<wchar_t>&, wstring&);
241 #endif
242
243   //
244   // algorithm
245   //
246   typedef  _Char_traits_match<char, char_traits<char> > char_match;
247
248   template 
249     const char*  
250     find_if<const char *, char_match>
251     (const char *, const char *, char_match, random_access_iterator_tag);
252
253 #ifdef _GLIBCPP_USE_WCHAR_T
254   typedef  _Char_traits_match<wchar_t, char_traits<wchar_t> > wchar_match;
255
256   template const wchar_t*  
257     find_if<const wchar_t*, wchar_match>
258     (const wchar_t*, const wchar_t*, wchar_match, random_access_iterator_tag);
259 #endif
260   
261   template 
262     string* 
263     __uninitialized_fill_n_aux<string*, size_t, string>
264     (string*, size_t, string const &, __false_type);
265
266   template 
267     string* 
268     __uninitialized_copy_aux<vector<string>::const_iterator, string *>
269     (vector<string>::const_iterator, vector<string>::const_iterator, 
270      string*, __false_type);
271
272   template
273     streamsize
274     __copy_streambufs(basic_ios<char>&, basic_streambuf<char>*,
275                       basic_streambuf<char>*); 
276 #ifdef _GLIBCPP_USE_WCHAR_T
277   template
278     streamsize
279     __copy_streambufs(basic_ios<wchar_t>&, basic_streambuf<wchar_t>*,
280                       basic_streambuf<wchar_t>*); 
281 #endif
282 } //std