2 * Copyright 2011 Piotr Caban for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
29 #include "wine/debug.h"
30 WINE_DEFAULT_DEBUG_CHANNEL(msvcp);
32 /* ?_Index@ios_base@std@@0HA */
33 int ios_base_Index = 0;
34 /* ?_Sync@ios_base@std@@0_NA */
35 MSVCP_bool ios_base_Sync = FALSE;
39 __int64 DECLSPEC_ALIGN(8) pos;
43 static inline const char* debugstr_fpos_int(fpos_int *fpos)
45 return wine_dbg_sprintf("fpos(%ld %s %d)", fpos->off, wine_dbgstr_longlong(fpos->pos), fpos->state);
49 void (__cdecl *pfunc)(ios_base*, streamsize);
54 void (__cdecl *pfunc)(ios_base*, int);
62 } basic_filebuf__Initfl;
65 basic_streambuf_char base;
75 basic_streambuf_wchar base;
82 } basic_filebuf_wchar;
85 STRINGBUF_allocated = 1,
86 STRINGBUF_no_write = 2,
87 STRINGBUF_no_read = 4,
90 } basic_stringbuf_state;
93 basic_streambuf_char base;
96 char allocator; /* empty struct */
97 } basic_stringbuf_char;
100 basic_streambuf_wchar base;
103 char allocator; /* empty struct */
104 } basic_stringbuf_wchar;
108 basic_streambuf_char *strbuf;
109 struct _basic_ostream_char *stream;
115 basic_streambuf_wchar *strbuf;
116 struct _basic_ostream_wchar *stream;
120 typedef struct _basic_ostream_char {
122 /* virtual inheritance
123 * basic_ios_char basic_ios;
125 } basic_ostream_char;
127 typedef struct _basic_ostream_wchar {
129 /* virtual inheritance
130 * basic_ios_wchar basic_ios;
132 } basic_ostream_wchar;
137 /* virtual inheritance
138 * basic_ios_char basic_ios;
140 } basic_istream_char;
145 /* virtual inheritance
146 * basic_ios_wchar basic_ios;
148 } basic_istream_wchar;
151 basic_istream_char base1;
152 basic_ostream_char base2;
153 /* virtual inheritance
154 * basic_ios_char basic_ios;
156 } basic_iostream_char;
159 basic_istream_wchar base1;
160 basic_ostream_wchar base2;
161 /* virtual inheritance
162 * basic_ios_wchar basic_ios;
164 } basic_iostream_wchar;
167 basic_ostream_char base;
168 basic_filebuf_char filebuf;
169 /* virtual inheritance
170 * basic_ios_char basic_ios;
172 } basic_ofstream_char;
175 basic_ostream_wchar base;
176 basic_filebuf_wchar filebuf;
177 /* virtual inheritance
178 * basic_ios_wchar basic_ios;
180 } basic_ofstream_wchar;
183 basic_istream_char base;
184 basic_filebuf_char filebuf;
185 /* virtual inheritance
186 * basic_ios_char basic_ios;
188 } basic_ifstream_char;
191 basic_istream_wchar base;
192 basic_filebuf_wchar filebuf;
193 /* virtual inheritance
194 * basic_ios_wchar basic_ios;
196 } basic_ifstream_wchar;
199 basic_iostream_char base;
200 basic_filebuf_char filebuf;
201 /* virtual inheritance
202 * basic_ios_char basic_ios;
204 } basic_fstream_char;
207 basic_iostream_wchar base;
208 basic_filebuf_wchar filebuf;
209 /* virtual inheritance
210 * basic_ios_char basic_ios;
212 } basic_fstream_wchar;
215 basic_ostream_char base;
216 basic_stringbuf_char strbuf;
217 /* virtual inheritance
218 * basic_ios_char basic_ios;
220 } basic_ostringstream_char;
223 basic_ostream_wchar base;
224 basic_stringbuf_wchar strbuf;
225 /* virtual inheritance
226 * basic_ios_wchar basic_ios;
228 } basic_ostringstream_wchar;
231 basic_istream_char base;
232 basic_stringbuf_char strbuf;
233 /* virtual inheritance
234 * basic_ios_char basic_ios;
236 } basic_istringstream_char;
239 basic_istream_wchar base;
240 basic_stringbuf_wchar strbuf;
241 /* virtual inheritance
242 * basic_ios_wchar basic_ios;
244 } basic_istringstream_wchar;
247 basic_iostream_char base;
248 basic_stringbuf_char strbuf;
249 /* virtual inheritance
250 * basic_ios_char basic_ios;
252 } basic_stringstream_char;
255 basic_iostream_wchar base;
256 basic_stringbuf_wchar strbuf;
257 /* virtual inheritance
258 * basic_ios_wchar basic_ios;
260 } basic_stringstream_wchar;
263 STRSTATE_Allocated = 1,
264 STRSTATE_Constant = 2,
265 STRSTATE_Dynamic = 4,
267 } strstreambuf__Strstate;
270 basic_streambuf_char base;
275 void* (__cdecl *palloc)(MSVCP_size_t);
276 void (__cdecl *pfree)(void*);
279 extern const vtable_ptr MSVCP_iosb_vtable;
281 /* ??_7ios_base@std@@6B@ */
282 extern const vtable_ptr MSVCP_ios_base_vtable;
284 /* ??_7?$basic_ios@DU?$char_traits@D@std@@@std@@6B@ */
285 extern const vtable_ptr MSVCP_basic_ios_char_vtable;
287 /* ??_7?$basic_ios@_WU?$char_traits@_W@std@@@std@@6B@ */
288 extern const vtable_ptr MSVCP_basic_ios_wchar_vtable;
290 /* ??_7?$basic_ios@GU?$char_traits@G@std@@@std@@6B@ */
291 extern const vtable_ptr MSVCP_basic_ios_short_vtable;
293 /* ??_7?$basic_streambuf@DU?$char_traits@D@std@@@std@@6B@ */
294 extern const vtable_ptr MSVCP_basic_streambuf_char_vtable;
296 /* ??_7?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@6B@ */
297 extern const vtable_ptr MSVCP_basic_streambuf_wchar_vtable;
299 /* ??_7?$basic_streambuf@GU?$char_traits@G@std@@@std@@6B@ */
300 extern const vtable_ptr MSVCP_basic_streambuf_short_vtable;
302 /* ??_7?$basic_filebuf@DU?$char_traits@D@std@@@std@@6B@ */
303 extern const vtable_ptr MSVCP_basic_filebuf_char_vtable;
305 /* ??_7?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@6B@ */
306 extern const vtable_ptr MSVCP_basic_filebuf_wchar_vtable;
308 /* ??_7?$basic_filebuf@GU?$char_traits@G@std@@@std@@6B@ */
309 extern const vtable_ptr MSVCP_basic_filebuf_short_vtable;
311 /* ??_7?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
312 extern const vtable_ptr MSVCP_basic_stringbuf_char_vtable;
314 /* ??_7?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
315 extern const vtable_ptr MSVCP_basic_stringbuf_wchar_vtable;
317 /* ??_7?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
318 extern const vtable_ptr MSVCP_basic_stringbuf_short_vtable;
320 /* ??_8?$basic_ostream@DU?$char_traits@D@std@@@std@@7B@ */
321 const int basic_ostream_char_vbtable[] = {0, sizeof(basic_ostream_char)};
322 /* ??_7?$basic_ostream@DU?$char_traits@D@std@@@std@@6B@ */
323 extern const vtable_ptr MSVCP_basic_ostream_char_vtable;
325 /* ??_8?$basic_ostream@_WU?$char_traits@_W@std@@@std@@7B@ */
326 const int basic_ostream_wchar_vbtable[] = {0, sizeof(basic_ostream_wchar)};
327 /* ??_7?$basic_ostream@_WU?$char_traits@_W@std@@@std@@6B@ */
328 extern const vtable_ptr MSVCP_basic_ostream_wchar_vtable;
330 /* ??_8?$basic_ostream@GU?$char_traits@G@std@@@std@@7B@ */
331 const int basic_ostream_short_vbtable[] = {0, sizeof(basic_ostream_wchar)};
332 /* ??_7?$basic_ostream@GU?$char_traits@G@std@@@std@@6B@ */
333 extern const vtable_ptr MSVCP_basic_ostream_short_vtable;
335 /* ??_8?$basic_istream@DU?$char_traits@D@std@@@std@@7B@ */
336 const int basic_istream_char_vbtable[] = {0, sizeof(basic_istream_char)};
337 /* ??_7?$basic_istream@DU?$char_traits@D@std@@@std@@6B@ */
338 extern const vtable_ptr MSVCP_basic_istream_char_vtable;
340 /* ??_8?$basic_istream@_WU?$char_traits@_W@std@@@std@@7B@ */
341 const int basic_istream_wchar_vbtable[] = {0, sizeof(basic_istream_wchar)};
342 /* ??_7?$basic_istream@_WU?$char_traits@_W@std@@@std@@6B@ */
343 extern const vtable_ptr MSVCP_basic_istream_wchar_vtable;
345 /* ??_8?$basic_istream@GU?$char_traits@G@std@@@std@@7B@ */
346 const int basic_istream_short_vbtable[] = {0, sizeof(basic_istream_wchar)};
347 /* ??_7?$basic_istream@GU?$char_traits@G@std@@@std@@6B@ */
348 extern const vtable_ptr MSVCP_basic_istream_short_vtable;
350 /* ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
351 const int basic_iostream_char_vbtable1[] = {0, sizeof(basic_iostream_char)};
352 /* ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
353 const int basic_iostream_char_vbtable2[] = {0, sizeof(basic_iostream_char)-FIELD_OFFSET(basic_iostream_char, base2)};
354 /* ??_7?$basic_iostream@DU?$char_traits@D@std@@@std@@6B@ */
355 extern const vtable_ptr MSVCP_basic_iostream_char_vtable;
357 /* ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
358 /* ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
359 const int basic_iostream_wchar_vbtable1[] = {0, sizeof(basic_iostream_wchar)};
360 /* ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
361 /* ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
362 const int basic_iostream_wchar_vbtable2[] = {0, sizeof(basic_iostream_wchar)-FIELD_OFFSET(basic_iostream_wchar, base2)};
363 /* ??_7?$basic_iostream@_WU?$char_traits@_W@std@@@std@@6B@ */
364 extern const vtable_ptr MSVCP_basic_iostream_wchar_vtable;
365 /* ??_7?$basic_iostream@GU?$char_traits@G@std@@@std@@6B@ */
366 extern const vtable_ptr MSVCP_basic_iostream_short_vtable;
368 /* ??_8?$basic_ofstream@DU?$char_traits@D@std@@@std@@7B@ */
369 const int basic_ofstream_char_vbtable[] = {0, sizeof(basic_ofstream_char)};
370 /* ??_7?$basic_ofstream@DU?$char_traits@D@std@@@std@@6B@ */
371 extern const vtable_ptr MSVCP_basic_ofstream_char_vtable;
373 /* ??_8?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@7B@ */
374 const int basic_ofstream_wchar_vbtable[] = {0, sizeof(basic_ofstream_wchar)};
375 /* ??_7?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@6B@ */
376 extern const vtable_ptr MSVCP_basic_ofstream_wchar_vtable;
378 /* ??_8?$basic_ofstream@GU?$char_traits@G@std@@@std@@7B@ */
379 const int basic_ofstream_short_vbtable[] = {0, sizeof(basic_ofstream_wchar)};
380 /* ??_7?$basic_ofstream@GU?$char_traits@G@std@@@std@@6B@ */
381 extern const vtable_ptr MSVCP_basic_ofstream_short_vtable;
383 /* ??_8?$basic_ifstream@DU?$char_traits@D@std@@@std@@7B@ */
384 const int basic_ifstream_char_vbtable[] = {0, sizeof(basic_ifstream_char)};
385 /* ??_7?$basic_ifstream@DU?$char_traits@D@std@@@std@@6B@ */
386 extern const vtable_ptr MSVCP_basic_ifstream_char_vtable;
388 /* ??_8?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@7B@ */
389 const int basic_ifstream_wchar_vbtable[] = {0, sizeof(basic_ifstream_wchar)};
390 /* ??_7?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@6B@ */
391 extern const vtable_ptr MSVCP_basic_ifstream_wchar_vtable;
393 /* ??_8?$basic_ifstream@GU?$char_traits@G@std@@@std@@7B@ */
394 const int basic_ifstream_short_vbtable[] = {0, sizeof(basic_ifstream_wchar)};
395 /* ??_7?$basic_ifstream@GU?$char_traits@G@std@@@std@@6B@ */
396 extern const vtable_ptr MSVCP_basic_ifstream_short_vtable;
398 /* ??_8?$basic_fstream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
399 const int basic_fstream_char_vbtable1[] = {0, sizeof(basic_fstream_char)};
400 /* ??_8?$basic_fstream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
401 const int basic_fstream_char_vbtable2[] = {0, sizeof(basic_fstream_char)-FIELD_OFFSET(basic_fstream_char, base.base2)};
402 /* ??_7?$basic_fstream@DU?$char_traits@D@std@@@std@@6B@ */
403 extern const vtable_ptr MSVCP_basic_fstream_char_vtable;
405 /* ??_8?$basic_fstream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
406 /* ??_8?$basic_fstream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
407 const int basic_fstream_wchar_vbtable1[] = {0, sizeof(basic_fstream_wchar)};
408 /* ??_8?$basic_fstream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
409 /* ??_8?$basic_fstream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
410 const int basic_fstream_wchar_vbtable2[] = {0, sizeof(basic_fstream_wchar)-FIELD_OFFSET(basic_fstream_wchar, base.base2)};
411 /* ??_7?$basic_fstream@_WU?$char_traits@_W@std@@@std@@6B@ */
412 extern const vtable_ptr MSVCP_basic_fstream_wchar_vtable;
413 /* ??_7?$basic_fstream@GU?$char_traits@G@std@@@std@@6B@ */
414 extern const vtable_ptr MSVCP_basic_fstream_short_vtable;
416 /* ??_8?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@ */
417 const int basic_ostringstream_char_vbtable[] = {0, sizeof(basic_ostringstream_char)};
418 /* ??_7?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
419 extern const vtable_ptr MSVCP_basic_ostringstream_char_vtable;
421 /* ??_8?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B@ */
422 const int basic_ostringstream_wchar_vbtable[] = {0, sizeof(basic_ostringstream_wchar)};
423 /* ??_7?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
424 extern const vtable_ptr MSVCP_basic_ostringstream_wchar_vtable;
426 /* ??_8?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B@ */
427 const int basic_ostringstream_short_vbtable[] = {0, sizeof(basic_ostringstream_wchar)};
428 /* ??_7?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
429 extern const vtable_ptr MSVCP_basic_ostringstream_short_vtable;
431 /* ??_8?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@ */
432 const int basic_istringstream_char_vbtable[] = {0, sizeof(basic_istringstream_char)};
433 /* ??_7?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
434 extern const vtable_ptr MSVCP_basic_istringstream_char_vtable;
436 /* ??_8?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B@ */
437 const int basic_istringstream_wchar_vbtable[] = {0, sizeof(basic_istringstream_wchar)};
438 /* ??_7?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
439 extern const vtable_ptr MSVCP_basic_istringstream_wchar_vtable;
441 /* ??_8?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B@ */
442 const int basic_istringstream_short_vbtable[] = {0, sizeof(basic_istringstream_wchar)};
443 /* ??_7?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
444 extern const vtable_ptr MSVCP_basic_istringstream_short_vtable;
446 /* ??_8?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
447 const int basic_stringstream_char_vbtable1[] = {0, sizeof(basic_stringstream_char)};
448 /* ??_8?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
449 const int basic_stringstream_char_vbtable2[] = {0, sizeof(basic_stringstream_char)-FIELD_OFFSET(basic_stringstream_char, base.base2)};
450 /* ??_7?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
451 extern const vtable_ptr MSVCP_basic_stringstream_char_vtable;
453 /* ??_8?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
454 const int basic_stringstream_wchar_vbtable1[] = {0, sizeof(basic_stringstream_wchar)};
455 /* ??_8?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
456 const int basic_stringstream_wchar_vbtable2[] = {0, sizeof(basic_stringstream_wchar)-FIELD_OFFSET(basic_stringstream_wchar, base.base2)};
457 /* ??_7?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
458 extern const vtable_ptr MSVCP_basic_stringstream_wchar_vtable;
460 /* ??_8?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
461 const int basic_stringstream_short_vbtable1[] = {0, sizeof(basic_stringstream_wchar)};
462 /* ??_8?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
463 const int basic_stringstream_short_vbtable2[] = {0, sizeof(basic_stringstream_wchar)-FIELD_OFFSET(basic_stringstream_wchar, base.base2)};
464 /* ??_7?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
465 extern const vtable_ptr MSVCP_basic_stringstream_short_vtable;
467 /* ??_7strstreambuf@std@@6B */
468 extern const vtable_ptr MSVCP_strstreambuf_vtable;
470 DEFINE_RTTI_DATA0(iosb, 0, ".?AV?$_Iosb@H@std@@");
471 DEFINE_RTTI_DATA1(ios_base, 0, &iosb_rtti_base_descriptor, ".?AV?$_Iosb@H@std@@");
472 DEFINE_RTTI_DATA2(basic_ios_char, 0, &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
473 ".?AV?$basic_ios@DU?$char_traits@D@std@@@std@@");
474 DEFINE_RTTI_DATA2(basic_ios_wchar, 0, &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
475 ".?AV?$basic_ios@_WU?$char_traits@_W@std@@@std@@");
476 DEFINE_RTTI_DATA2(basic_ios_short, 0, &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
477 ".?AV?$basic_ios@GU?$char_traits@G@std@@@std@@");
478 DEFINE_RTTI_DATA0(basic_streambuf_char, 0,
479 ".?AV?$basic_streambuf@DU?$char_traits@D@std@@@std@@");
480 DEFINE_RTTI_DATA0(basic_streambuf_wchar, 0,
481 ".?AV?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@");
482 DEFINE_RTTI_DATA0(basic_streambuf_short, 0,
483 ".?AV?$basic_streambuf@GU?$char_traits@G@std@@@std@@");
484 DEFINE_RTTI_DATA1(basic_filebuf_char, 0, &basic_streambuf_char_rtti_base_descriptor,
485 ".?AV?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@");
486 DEFINE_RTTI_DATA1(basic_filebuf_wchar, 0, &basic_streambuf_wchar_rtti_base_descriptor,
487 ".?AV?$basic_filebuf@GU?$char_traits@G@std@@@std@@");
488 DEFINE_RTTI_DATA1(basic_filebuf_short, 0, &basic_streambuf_short_rtti_base_descriptor,
489 ".?AV?$basic_filebuf@DU?$char_traits@D@std@@@std@@");
490 DEFINE_RTTI_DATA1(basic_stringbuf_char, 0, &basic_streambuf_char_rtti_base_descriptor,
491 ".?AV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@");
492 DEFINE_RTTI_DATA1(basic_stringbuf_wchar, 0, &basic_streambuf_wchar_rtti_base_descriptor,
493 ".?AV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@");
494 DEFINE_RTTI_DATA1(basic_stringbuf_short, 0, &basic_streambuf_short_rtti_base_descriptor,
495 ".?AV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@");
496 DEFINE_RTTI_DATA3(basic_ostream_char, sizeof(basic_ostream_char), &basic_ios_char_rtti_base_descriptor,
497 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
498 ".?AV?$basic_ostream@DU?$char_traits@D@std@@@std@@");
499 DEFINE_RTTI_DATA3(basic_ostream_wchar, sizeof(basic_ostream_wchar), &basic_ios_wchar_rtti_base_descriptor,
500 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
501 ".?AV?$basic_ostream@_WU?$char_traits@_W@std@@@std@@");
502 DEFINE_RTTI_DATA3(basic_ostream_short, sizeof(basic_ostream_wchar), &basic_ios_short_rtti_base_descriptor,
503 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
504 ".?AV?$basic_ostream@GU?$char_traits@G@std@@@std@@");
505 DEFINE_RTTI_DATA3(basic_istream_char, sizeof(basic_istream_char), &basic_ios_char_rtti_base_descriptor,
506 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
507 ".?AV?$basic_istream@DU?$char_traits@D@std@@@std@@");
508 DEFINE_RTTI_DATA3(basic_istream_wchar, sizeof(basic_istream_wchar), &basic_ios_wchar_rtti_base_descriptor,
509 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
510 ".?AV?$basic_istream@_WU?$char_traits@_W@std@@@std@@");
511 DEFINE_RTTI_DATA3(basic_istream_short, sizeof(basic_istream_wchar), &basic_ios_short_rtti_base_descriptor,
512 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
513 ".?AV?$basic_istream@GU?$char_traits@G@std@@@std@@");
514 DEFINE_RTTI_DATA8(basic_iostream_char, sizeof(basic_iostream_char),
515 &basic_istream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
516 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
517 &basic_ostream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
518 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
519 ".?AV?$basic_iostream@DU?$char_traits@D@std@@@std@@");
520 DEFINE_RTTI_DATA8(basic_iostream_wchar, sizeof(basic_iostream_wchar),
521 &basic_istream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
522 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
523 &basic_ostream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
524 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
525 ".?AV?$basic_iostream@_WU?$char_traits@_W@std@@@std@@");
526 DEFINE_RTTI_DATA8(basic_iostream_short, sizeof(basic_iostream_wchar),
527 &basic_istream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
528 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
529 &basic_ostream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
530 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
531 ".?AV?$basic_iostream@GU?$char_traits@G@std@@@std@@");
532 DEFINE_RTTI_DATA4(basic_ofstream_char, sizeof(basic_ofstream_char),
533 &basic_ostream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
534 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
535 ".?AV?$basic_ofstream@DU?$char_traits@D@std@@@std@@");
536 DEFINE_RTTI_DATA4(basic_ofstream_wchar, sizeof(basic_ofstream_wchar),
537 &basic_ostream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
538 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
539 ".?AV?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@");
540 DEFINE_RTTI_DATA4(basic_ofstream_short, sizeof(basic_ofstream_wchar),
541 &basic_ostream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
542 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
543 ".?AV?$basic_ofstream@GU?$char_traits@G@std@@@std@@");
544 DEFINE_RTTI_DATA4(basic_ifstream_char, sizeof(basic_ifstream_char),
545 &basic_istream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
546 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
547 ".?AV?$basic_ifstream@DU?$char_traits@D@std@@@std@@");
548 DEFINE_RTTI_DATA4(basic_ifstream_wchar, sizeof(basic_ifstream_wchar),
549 &basic_istream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
550 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
551 ".?AV?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@");
552 DEFINE_RTTI_DATA4(basic_ifstream_short, sizeof(basic_ifstream_wchar),
553 &basic_istream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
554 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
555 ".?AV?$basic_ifstream@GU?$char_traits@G@std@@@std@@");
556 DEFINE_RTTI_DATA8(basic_fstream_char, sizeof(basic_fstream_char),
557 &basic_istream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
558 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
559 &basic_ostream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
560 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
561 ".?AV?$basic_fstream@DU?$char_traits@D@std@@@std@@");
562 DEFINE_RTTI_DATA8(basic_fstream_wchar, sizeof(basic_fstream_wchar),
563 &basic_istream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
564 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
565 &basic_ostream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
566 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
567 ".?AV?$basic_fstream@_WU?$char_traits@_W@std@@@std@@");
568 DEFINE_RTTI_DATA8(basic_fstream_short, sizeof(basic_fstream_wchar),
569 &basic_istream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
570 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
571 &basic_ostream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
572 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
573 ".?AV?$basic_fstream@GU?$char_traits@G@std@@@std@@");
574 DEFINE_RTTI_DATA4(basic_ostringstream_char, sizeof(basic_ostringstream_char),
575 &basic_ostream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
576 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
577 ".?AV?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@");
578 DEFINE_RTTI_DATA4(basic_ostringstream_wchar, sizeof(basic_ostringstream_wchar),
579 &basic_ostream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
580 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
581 ".?AV?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@");
582 DEFINE_RTTI_DATA4(basic_ostringstream_short, sizeof(basic_ostringstream_wchar),
583 &basic_ostream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
584 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
585 ".?AV?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@");
586 DEFINE_RTTI_DATA4(basic_istringstream_char, sizeof(basic_istringstream_char),
587 &basic_ostream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
588 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
589 ".?AV?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@");
590 DEFINE_RTTI_DATA4(basic_istringstream_wchar, sizeof(basic_istringstream_wchar),
591 &basic_ostream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
592 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
593 ".?AV?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@");
594 DEFINE_RTTI_DATA4(basic_istringstream_short, sizeof(basic_istringstream_wchar),
595 &basic_ostream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
596 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
597 ".?AV?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@");
598 DEFINE_RTTI_DATA8(basic_stringstream_char, sizeof(basic_stringstream_char),
599 &basic_istream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
600 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
601 &basic_ostream_char_rtti_base_descriptor, &basic_ios_char_rtti_base_descriptor,
602 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
603 ".?AV?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@");
604 DEFINE_RTTI_DATA8(basic_stringstream_wchar, sizeof(basic_stringstream_wchar),
605 &basic_istream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
606 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
607 &basic_ostream_wchar_rtti_base_descriptor, &basic_ios_wchar_rtti_base_descriptor,
608 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
609 ".?AV?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@");
610 DEFINE_RTTI_DATA8(basic_stringstream_short, sizeof(basic_stringstream_wchar),
611 &basic_istream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
612 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
613 &basic_ostream_short_rtti_base_descriptor, &basic_ios_short_rtti_base_descriptor,
614 &ios_base_rtti_base_descriptor, &iosb_rtti_base_descriptor,
615 ".?AV?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@");
616 DEFINE_RTTI_DATA1(strstreambuf, sizeof(strstreambuf),
617 &basic_streambuf_char_rtti_base_descriptor, ".?AVstrstreambuf@std@@");
620 void __asm_dummy_vtables(void) {
623 VTABLE_ADD_FUNC(iosb_vector_dtor));
624 __ASM_VTABLE(ios_base,
625 VTABLE_ADD_FUNC(ios_base_vector_dtor));
626 __ASM_VTABLE(basic_ios_char,
627 VTABLE_ADD_FUNC(basic_ios_char_vector_dtor));
628 __ASM_VTABLE(basic_ios_wchar,
629 VTABLE_ADD_FUNC(basic_ios_wchar_vector_dtor));
630 __ASM_VTABLE(basic_ios_short,
631 VTABLE_ADD_FUNC(basic_ios_wchar_vector_dtor));
632 __ASM_VTABLE(basic_streambuf_char,
633 VTABLE_ADD_FUNC(basic_streambuf_char_vector_dtor)
634 VTABLE_ADD_FUNC(basic_streambuf_char_overflow)
635 VTABLE_ADD_FUNC(basic_streambuf_char_pbackfail)
636 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc)
637 VTABLE_ADD_FUNC(basic_streambuf_char_underflow)
638 VTABLE_ADD_FUNC(basic_streambuf_char_uflow)
639 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn)
640 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s)
641 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn)
642 VTABLE_ADD_FUNC(basic_streambuf_char_seekoff)
643 VTABLE_ADD_FUNC(basic_streambuf_char_seekpos)
644 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf)
645 VTABLE_ADD_FUNC(basic_streambuf_char_sync)
646 VTABLE_ADD_FUNC(basic_streambuf_char_imbue));
647 __ASM_VTABLE(basic_streambuf_wchar,
648 VTABLE_ADD_FUNC(basic_streambuf_wchar_vector_dtor)
649 VTABLE_ADD_FUNC(basic_streambuf_wchar_overflow)
650 VTABLE_ADD_FUNC(basic_streambuf_wchar_pbackfail)
651 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc)
652 VTABLE_ADD_FUNC(basic_streambuf_wchar_underflow)
653 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow)
654 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn)
655 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s)
656 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn)
657 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekoff)
658 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekpos)
659 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf)
660 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync)
661 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue));
662 __ASM_VTABLE(basic_streambuf_short,
663 VTABLE_ADD_FUNC(basic_streambuf_wchar_vector_dtor)
664 VTABLE_ADD_FUNC(basic_streambuf_wchar_overflow)
665 VTABLE_ADD_FUNC(basic_streambuf_wchar_pbackfail)
666 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc)
667 VTABLE_ADD_FUNC(basic_streambuf_wchar_underflow)
668 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow)
669 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn)
670 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s)
671 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn)
672 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekoff)
673 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekpos)
674 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf)
675 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync)
676 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue));
677 __ASM_VTABLE(basic_filebuf_char,
678 VTABLE_ADD_FUNC(basic_filebuf_char_vector_dtor)
679 VTABLE_ADD_FUNC(basic_filebuf_char_overflow)
680 VTABLE_ADD_FUNC(basic_filebuf_char_pbackfail)
681 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc)
682 VTABLE_ADD_FUNC(basic_filebuf_char_underflow)
683 VTABLE_ADD_FUNC(basic_filebuf_char_uflow)
684 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn)
685 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s)
686 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn)
687 VTABLE_ADD_FUNC(basic_filebuf_char_seekoff)
688 VTABLE_ADD_FUNC(basic_filebuf_char_seekpos)
689 VTABLE_ADD_FUNC(basic_filebuf_char_setbuf)
690 VTABLE_ADD_FUNC(basic_filebuf_char_sync)
691 VTABLE_ADD_FUNC(basic_filebuf_char_imbue));
692 __ASM_VTABLE(basic_filebuf_wchar,
693 VTABLE_ADD_FUNC(basic_filebuf_wchar_vector_dtor)
694 VTABLE_ADD_FUNC(basic_filebuf_wchar_overflow)
695 VTABLE_ADD_FUNC(basic_filebuf_wchar_pbackfail)
696 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc)
697 VTABLE_ADD_FUNC(basic_filebuf_wchar_underflow)
698 VTABLE_ADD_FUNC(basic_filebuf_wchar_uflow)
699 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn)
700 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s)
701 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn)
702 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekoff)
703 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekpos)
704 VTABLE_ADD_FUNC(basic_filebuf_wchar_setbuf)
705 VTABLE_ADD_FUNC(basic_filebuf_wchar_sync)
706 VTABLE_ADD_FUNC(basic_filebuf_wchar_imbue));
707 __ASM_VTABLE(basic_filebuf_short,
708 VTABLE_ADD_FUNC(basic_filebuf_wchar_vector_dtor)
709 VTABLE_ADD_FUNC(basic_filebuf_wchar_overflow)
710 VTABLE_ADD_FUNC(basic_filebuf_wchar_pbackfail)
711 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc)
712 VTABLE_ADD_FUNC(basic_filebuf_wchar_underflow)
713 VTABLE_ADD_FUNC(basic_filebuf_wchar_uflow)
714 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn)
715 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s)
716 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn)
717 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekoff)
718 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekpos)
719 VTABLE_ADD_FUNC(basic_filebuf_short_setbuf)
720 VTABLE_ADD_FUNC(basic_filebuf_wchar_sync)
721 VTABLE_ADD_FUNC(basic_filebuf_short_imbue));
722 __ASM_VTABLE(basic_stringbuf_char,
723 VTABLE_ADD_FUNC(basic_stringbuf_char_vector_dtor)
724 VTABLE_ADD_FUNC(basic_stringbuf_char_overflow)
725 VTABLE_ADD_FUNC(basic_stringbuf_char_pbackfail)
726 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc)
727 VTABLE_ADD_FUNC(basic_stringbuf_char_underflow)
728 VTABLE_ADD_FUNC(basic_streambuf_char_uflow)
729 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn)
730 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s)
731 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn)
732 VTABLE_ADD_FUNC(basic_stringbuf_char_seekoff)
733 VTABLE_ADD_FUNC(basic_stringbuf_char_seekpos)
734 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf)
735 VTABLE_ADD_FUNC(basic_streambuf_char_sync)
736 VTABLE_ADD_FUNC(basic_streambuf_char_imbue));
737 __ASM_VTABLE(basic_stringbuf_wchar,
738 VTABLE_ADD_FUNC(basic_stringbuf_wchar_vector_dtor)
739 VTABLE_ADD_FUNC(basic_stringbuf_wchar_overflow)
740 VTABLE_ADD_FUNC(basic_stringbuf_wchar_pbackfail)
741 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc)
742 VTABLE_ADD_FUNC(basic_stringbuf_wchar_underflow)
743 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow)
744 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn)
745 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s)
746 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn)
747 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekoff)
748 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekpos)
749 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf)
750 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync)
751 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue));
752 __ASM_VTABLE(basic_stringbuf_short,
753 VTABLE_ADD_FUNC(basic_stringbuf_wchar_vector_dtor)
754 VTABLE_ADD_FUNC(basic_stringbuf_wchar_overflow)
755 VTABLE_ADD_FUNC(basic_stringbuf_wchar_pbackfail)
756 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc)
757 VTABLE_ADD_FUNC(basic_stringbuf_wchar_underflow)
758 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow)
759 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn)
760 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s)
761 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn)
762 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekoff)
763 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekpos)
764 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf)
765 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync)
766 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue));
767 __ASM_VTABLE(basic_ostream_char,
768 VTABLE_ADD_FUNC(basic_ostream_char_vector_dtor));
769 __ASM_VTABLE(basic_ostream_wchar,
770 VTABLE_ADD_FUNC(basic_ostream_wchar_vector_dtor));
771 __ASM_VTABLE(basic_ostream_short,
772 VTABLE_ADD_FUNC(basic_ostream_wchar_vector_dtor));
773 __ASM_VTABLE(basic_istream_char,
774 VTABLE_ADD_FUNC(basic_istream_char_vector_dtor));
775 __ASM_VTABLE(basic_istream_wchar,
776 VTABLE_ADD_FUNC(basic_istream_wchar_vector_dtor));
777 __ASM_VTABLE(basic_istream_short,
778 VTABLE_ADD_FUNC(basic_istream_wchar_vector_dtor));
779 __ASM_VTABLE(basic_iostream_char,
780 VTABLE_ADD_FUNC(basic_iostream_char_vector_dtor));
781 __ASM_VTABLE(basic_iostream_wchar,
782 VTABLE_ADD_FUNC(basic_iostream_wchar_vector_dtor));
783 __ASM_VTABLE(basic_iostream_short,
784 VTABLE_ADD_FUNC(basic_iostream_wchar_vector_dtor));
785 __ASM_VTABLE(basic_ofstream_char,
786 VTABLE_ADD_FUNC(basic_ofstream_char_vector_dtor));
787 __ASM_VTABLE(basic_ofstream_wchar,
788 VTABLE_ADD_FUNC(basic_ofstream_wchar_vector_dtor));
789 __ASM_VTABLE(basic_ofstream_short,
790 VTABLE_ADD_FUNC(basic_ofstream_wchar_vector_dtor));
791 __ASM_VTABLE(basic_ifstream_char,
792 VTABLE_ADD_FUNC(basic_ifstream_char_vector_dtor));
793 __ASM_VTABLE(basic_ifstream_wchar,
794 VTABLE_ADD_FUNC(basic_ifstream_wchar_vector_dtor));
795 __ASM_VTABLE(basic_ifstream_short,
796 VTABLE_ADD_FUNC(basic_ifstream_wchar_vector_dtor));
797 __ASM_VTABLE(basic_fstream_char,
798 VTABLE_ADD_FUNC(basic_fstream_char_vector_dtor));
799 __ASM_VTABLE(basic_fstream_wchar,
800 VTABLE_ADD_FUNC(basic_fstream_wchar_vector_dtor));
801 __ASM_VTABLE(basic_fstream_short,
802 VTABLE_ADD_FUNC(basic_fstream_wchar_vector_dtor));
803 __ASM_VTABLE(basic_ostringstream_char,
804 VTABLE_ADD_FUNC(basic_ostringstream_char_vector_dtor));
805 __ASM_VTABLE(basic_ostringstream_wchar,
806 VTABLE_ADD_FUNC(basic_ostringstream_wchar_vector_dtor));
807 __ASM_VTABLE(basic_ostringstream_short,
808 VTABLE_ADD_FUNC(basic_ostringstream_wchar_vector_dtor));
809 __ASM_VTABLE(basic_istringstream_char,
810 VTABLE_ADD_FUNC(basic_istringstream_char_vector_dtor));
811 __ASM_VTABLE(basic_istringstream_wchar,
812 VTABLE_ADD_FUNC(basic_istringstream_wchar_vector_dtor));
813 __ASM_VTABLE(basic_istringstream_short,
814 VTABLE_ADD_FUNC(basic_istringstream_wchar_vector_dtor));
815 __ASM_VTABLE(basic_stringstream_char,
816 VTABLE_ADD_FUNC(basic_stringstream_char_vector_dtor));
817 __ASM_VTABLE(basic_stringstream_wchar,
818 VTABLE_ADD_FUNC(basic_stringstream_wchar_vector_dtor));
819 __ASM_VTABLE(basic_stringstream_short,
820 VTABLE_ADD_FUNC(basic_stringstream_wchar_vector_dtor));
821 __ASM_VTABLE(strstreambuf,
822 VTABLE_ADD_FUNC(strstreambuf_vector_dtor)
823 VTABLE_ADD_FUNC(strstreambuf_overflow)
824 VTABLE_ADD_FUNC(strstreambuf_pbackfail)
825 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc)
826 VTABLE_ADD_FUNC(strstreambuf_underflow)
827 VTABLE_ADD_FUNC(basic_streambuf_char_uflow)
828 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn)
829 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s)
830 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn)
831 VTABLE_ADD_FUNC(strstreambuf_seekoff)
832 VTABLE_ADD_FUNC(strstreambuf_seekpos)
833 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf)
834 VTABLE_ADD_FUNC(basic_streambuf_char_sync)
835 VTABLE_ADD_FUNC(basic_streambuf_char_imbue));
840 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z */
841 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z */
842 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setp_next, 16)
843 void __thiscall basic_streambuf_char_setp_next(basic_streambuf_char *this, char *first, char *next, char *last)
845 TRACE("(%p %p %p %p)\n", this, first, next, last);
849 this->wsize = last-next;
852 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD0@Z */
853 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD0@Z */
854 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setp, 12)
855 void __thiscall basic_streambuf_char_setp(basic_streambuf_char *this, char *first, char *last)
857 basic_streambuf_char_setp_next(this, first, first, last);
860 /* ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z */
861 /* ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z */
862 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setg, 16)
863 void __thiscall basic_streambuf_char_setg(basic_streambuf_char *this, char *first, char *next, char *last)
865 TRACE("(%p %p %p %p)\n", this, first, next, last);
869 this->rsize = last-next;
872 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXXZ */
873 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXXZ */
874 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Init_empty, 4)
875 void __thiscall basic_streambuf_char__Init_empty(basic_streambuf_char *this)
877 TRACE("(%p)\n", this);
879 this->prbuf = &this->rbuf;
880 this->pwbuf = &this->wbuf;
881 this->prpos = &this->rpos;
882 this->pwpos = &this->wpos;
883 this->prsize = &this->rsize;
884 this->pwsize = &this->wsize;
886 basic_streambuf_char_setp(this, NULL, NULL);
887 basic_streambuf_char_setg(this, NULL, NULL, NULL);
890 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@W4_Uninitialized@1@@Z */
891 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
892 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_ctor_uninitialized, 8)
893 basic_streambuf_char* __thiscall basic_streambuf_char_ctor_uninitialized(basic_streambuf_char *this, int uninitialized)
895 TRACE("(%p %d)\n", this, uninitialized);
896 this->vtable = &MSVCP_basic_streambuf_char_vtable;
897 mutex_ctor(&this->lock);
901 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@XZ */
902 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@XZ */
903 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_ctor, 4)
904 basic_streambuf_char* __thiscall basic_streambuf_char_ctor(basic_streambuf_char *this)
906 TRACE("(%p)\n", this);
908 this->vtable = &MSVCP_basic_streambuf_char_vtable;
909 mutex_ctor(&this->lock);
910 this->loc = MSVCRT_operator_new(sizeof(locale));
911 locale_ctor(this->loc);
912 basic_streambuf_char__Init_empty(this);
917 /* ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAE@XZ */
918 /* ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAA@XZ */
919 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_dtor, 4)
920 void __thiscall basic_streambuf_char_dtor(basic_streambuf_char *this)
922 TRACE("(%p)\n", this);
924 mutex_dtor(&this->lock);
925 locale_dtor(this->loc);
926 MSVCRT_operator_delete(this->loc);
929 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_vector_dtor, 8)
930 basic_streambuf_char* __thiscall basic_streambuf_char_vector_dtor(basic_streambuf_char *this, unsigned int flags)
932 TRACE("(%p %x)\n", this, flags);
934 /* we have an array, with the number of elements stored before the first object */
935 INT_PTR i, *ptr = (INT_PTR *)this-1;
937 for(i=*ptr-1; i>=0; i--)
938 basic_streambuf_char_dtor(this+i);
939 MSVCRT_operator_delete(ptr);
941 basic_streambuf_char_dtor(this);
943 MSVCRT_operator_delete(this);
949 /* ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEHXZ */
950 /* ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ */
951 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gnavail, 4)
952 streamsize __thiscall basic_streambuf_char__Gnavail(const basic_streambuf_char *this)
954 TRACE("(%p)\n", this);
955 return *this->prpos ? *this->prsize : 0;
958 /* ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
959 /* ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
960 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gndec, 4)
961 char* __thiscall basic_streambuf_char__Gndec(basic_streambuf_char *this)
963 TRACE("(%p)\n", this);
969 /* ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
970 /* ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
971 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gninc, 4)
972 char* __thiscall basic_streambuf_char__Gninc(basic_streambuf_char *this)
974 TRACE("(%p)\n", this);
976 return (*this->prpos)++;
979 /* ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
980 /* ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
981 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gnpreinc, 4)
982 char* __thiscall basic_streambuf_char__Gnpreinc(basic_streambuf_char *this)
984 TRACE("(%p)\n", this);
990 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAPAD0PAH001@Z */
991 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAPEAD0PEAH001@Z */
992 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Init, 28)
993 void __thiscall basic_streambuf_char__Init(basic_streambuf_char *this, char **gf, char **gn, int *gc, char **pf, char **pn, int *pc)
995 TRACE("(%p %p %p %p %p %p %p)\n", this, gf, gn, gc, pf, pn, pc);
1005 /* ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1006 /* ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1007 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Lock, 4)
1008 void __thiscall basic_streambuf_char__Lock(basic_streambuf_char *this)
1010 TRACE("(%p)\n", this);
1011 mutex_lock(&this->lock);
1014 /* ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEHXZ */
1015 /* ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ */
1016 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Pnavail, 4)
1017 streamsize __thiscall basic_streambuf_char__Pnavail(const basic_streambuf_char *this)
1019 TRACE("(%p)\n", this);
1020 return *this->pwpos ? *this->pwsize : 0;
1023 /* ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1024 /* ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1025 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Pninc, 4)
1026 char* __thiscall basic_streambuf_char__Pninc(basic_streambuf_char *this)
1028 TRACE("(%p)\n", this);
1030 return (*this->pwpos)++;
1033 /* ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1034 /* ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1035 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_underflow, 4)
1036 #define call_basic_streambuf_char_underflow(this) CALL_VTBL_FUNC(this, 16, \
1037 int, (basic_streambuf_char*), (this))
1038 int __thiscall basic_streambuf_char_underflow(basic_streambuf_char *this)
1040 TRACE("(%p)\n", this);
1044 /* ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1045 /* ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1046 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_uflow, 4)
1047 #define call_basic_streambuf_char_uflow(this) CALL_VTBL_FUNC(this, 20, \
1048 int, (basic_streambuf_char*), (this))
1049 int __thiscall basic_streambuf_char_uflow(basic_streambuf_char *this)
1053 TRACE("(%p)\n", this);
1055 if(call_basic_streambuf_char_underflow(this)==EOF)
1058 ret = **this->prpos;
1064 /* ?_Xsgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPADIH@Z */
1065 /* ?_Xsgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_K_J@Z */
1066 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Xsgetn_s, 16)
1067 #define call_basic_streambuf_char__Xsgetn_s(this, ptr, size, count) CALL_VTBL_FUNC(this, 28, \
1068 streamsize, (basic_streambuf_char*, char*, MSVCP_size_t, streamsize), (this, ptr, size, count))
1069 streamsize __thiscall basic_streambuf_char__Xsgetn_s(basic_streambuf_char *this, char *ptr, MSVCP_size_t size, streamsize count)
1071 streamsize copied, chunk;
1074 TRACE("(%p %p %lu %ld)\n", this, ptr, size, count);
1076 for(copied=0; copied<count && size;) {
1077 chunk = basic_streambuf_char__Gnavail(this);
1078 if(chunk > count-copied)
1079 chunk = count-copied;
1082 memcpy_s(ptr+copied, size, *this->prpos, chunk);
1083 *this->prpos += chunk;
1084 *this->prsize -= chunk;
1087 }else if((c = call_basic_streambuf_char_uflow(this)) != EOF) {
1099 /* ?_Sgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPADIH@Z */
1100 /* ?_Sgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_K_J@Z */
1101 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Sgetn_s, 16)
1102 streamsize __thiscall basic_streambuf_char__Sgetn_s(basic_streambuf_char *this, char *ptr, MSVCP_size_t size, streamsize count)
1104 TRACE("(%p %p %lu %ld)\n", this, ptr, size, count);
1105 return call_basic_streambuf_char__Xsgetn_s(this, ptr, size, count);
1108 /* ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1109 /* ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1110 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Unlock, 4)
1111 void __thiscall basic_streambuf_char__Unlock(basic_streambuf_char *this)
1113 TRACE("(%p)\n", this);
1114 mutex_unlock(&this->lock);
1117 /* ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1118 /* ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1119 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_eback, 4)
1120 char* __thiscall basic_streambuf_char_eback(const basic_streambuf_char *this)
1122 TRACE("(%p)\n", this);
1123 return *this->prbuf;
1126 /* ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1127 /* ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1128 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_gptr, 4)
1129 char* __thiscall basic_streambuf_char_gptr(const basic_streambuf_char *this)
1131 TRACE("(%p)\n", this);
1132 return *this->prpos;
1135 /* ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1136 /* ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1137 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_egptr, 4)
1138 char* __thiscall basic_streambuf_char_egptr(const basic_streambuf_char *this)
1140 TRACE("(%p)\n", this);
1141 return *this->prpos+*this->prsize;
1144 /* ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1145 /* ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1146 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_epptr, 4)
1147 char* __thiscall basic_streambuf_char_epptr(const basic_streambuf_char *this)
1149 TRACE("(%p)\n", this);
1150 return *this->pwpos+*this->pwsize;
1153 /* ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z */
1154 /* ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z */
1155 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_gbump, 8)
1156 void __thiscall basic_streambuf_char_gbump(basic_streambuf_char *this, int off)
1158 TRACE("(%p %d)\n", this, off);
1159 *this->prpos += off;
1160 *this->prsize -= off;
1163 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QBE?AVlocale@2@XZ */
1164 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEBA?AVlocale@2@XZ */
1165 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_getloc, 8)
1166 locale* __thiscall basic_streambuf_char_getloc(const basic_streambuf_char *this, locale *ret)
1168 TRACE("(%p)\n", this);
1169 return locale_copy_ctor(ret, this->loc);
1172 /* ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z */
1173 /* ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z */
1174 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_imbue, 8)
1175 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 52, \
1176 void, (basic_streambuf_char*, const locale*), (this, loc))
1177 void __thiscall basic_streambuf_char_imbue(basic_streambuf_char *this, const locale *loc)
1179 TRACE("(%p %p)\n", this, loc);
1182 /* ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
1183 /* ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
1184 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_overflow, 8)
1185 #define call_basic_streambuf_char_overflow(this, ch) CALL_VTBL_FUNC(this, 4, \
1186 int, (basic_streambuf_char*, int), (this, ch))
1187 int __thiscall basic_streambuf_char_overflow(basic_streambuf_char *this, int ch)
1189 TRACE("(%p %d)\n", this, ch);
1193 /* ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
1194 /* ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
1195 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbackfail, 8)
1196 #define call_basic_streambuf_char_pbackfail(this, ch) CALL_VTBL_FUNC(this, 8, \
1197 int, (basic_streambuf_char*, int), (this, ch))
1198 int __thiscall basic_streambuf_char_pbackfail(basic_streambuf_char *this, int ch)
1200 TRACE("(%p %d)\n", this, ch);
1204 /* ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1205 /* ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1206 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbase, 4)
1207 char* __thiscall basic_streambuf_char_pbase(const basic_streambuf_char *this)
1209 TRACE("(%p)\n", this);
1210 return *this->pwbuf;
1213 /* ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z */
1214 /* ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z */
1215 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbump, 8)
1216 void __thiscall basic_streambuf_char_pbump(basic_streambuf_char *this, int off)
1218 TRACE("(%p %d)\n", this, off);
1219 *this->pwpos += off;
1220 *this->pwsize -= off;
1223 /* ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1224 /* ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1225 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pptr, 4)
1226 char* __thiscall basic_streambuf_char_pptr(const basic_streambuf_char *this)
1228 TRACE("(%p)\n", this);
1229 return *this->pwpos;
1232 /* ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
1233 /* ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
1234 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubimbue, 12)
1235 locale* __thiscall basic_streambuf_char_pubimbue(basic_streambuf_char *this, locale *ret, const locale *loc)
1237 TRACE("(%p %p)\n", this, loc);
1238 memcpy(ret, this->loc, sizeof(locale));
1239 call_basic_streambuf_char_imbue(this, loc);
1240 locale_copy_ctor(this->loc, loc);
1244 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
1245 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
1246 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekoff, 20)
1247 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 36, \
1248 fpos_int*, (basic_streambuf_char*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
1249 fpos_int* __thiscall basic_streambuf_char_seekoff(basic_streambuf_char *this,
1250 fpos_int *ret, streamoff off, int way, int mode)
1252 TRACE("(%p %ld %d %d)\n", this, off, way, mode);
1259 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
1260 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
1261 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff, 20)
1262 fpos_int* __thiscall basic_streambuf_char_pubseekoff(basic_streambuf_char *this,
1263 fpos_int *ret, streamoff off, int way, int mode)
1265 TRACE("(%p %ld %d %d)\n", this, off, way, mode);
1266 return call_basic_streambuf_char_seekoff(this, ret, off, way, mode);
1269 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
1270 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
1271 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff_old, 20)
1272 fpos_int* __thiscall basic_streambuf_char_pubseekoff_old(basic_streambuf_char *this,
1273 fpos_int *ret, streamoff off, unsigned int way, unsigned int mode)
1275 TRACE("(%p %ld %d %d)\n", this, off, way, mode);
1276 return basic_streambuf_char_pubseekoff(this, ret, off, way, mode);
1279 /* ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
1280 /* ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
1281 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekpos, 36)
1282 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 40, \
1283 fpos_int*, (basic_streambuf_char*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
1284 fpos_int* __thiscall basic_streambuf_char_seekpos(basic_streambuf_char *this,
1285 fpos_int *ret, fpos_int pos, int mode)
1287 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos), mode);
1294 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
1295 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
1296 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekpos, 36)
1297 fpos_int* __thiscall basic_streambuf_char_pubseekpos(basic_streambuf_char *this,
1298 fpos_int *ret, fpos_int pos, int mode)
1300 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos), mode);
1301 return call_basic_streambuf_char_seekpos(this, ret, pos, mode);
1304 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
1305 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
1306 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekpos_old, 36)
1307 fpos_int* __thiscall basic_streambuf_char_pubseekpos_old(basic_streambuf_char *this,
1308 fpos_int *ret, fpos_int pos, unsigned int mode)
1310 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos), mode);
1311 return basic_streambuf_char_pubseekpos(this, ret, pos, mode);
1314 /* ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEPAV12@PADH@Z */
1315 /* ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAPEAV12@PEAD_J@Z */
1316 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setbuf, 12)
1317 #define call_basic_streambuf_char_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 44, \
1318 basic_streambuf_char*, (basic_streambuf_char*, char*, streamsize), (this, buf, count))
1319 basic_streambuf_char* __thiscall basic_streambuf_char_setbuf(basic_streambuf_char *this, char *buf, streamsize count)
1321 TRACE("(%p %p %ld)\n", this, buf, count);
1325 /* ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PADH@Z */
1326 /* ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEAD_J@Z */
1327 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsetbuf, 12)
1328 basic_streambuf_char* __thiscall basic_streambuf_char_pubsetbuf(basic_streambuf_char *this, char *buf, streamsize count)
1330 TRACE("(%p %p %ld)\n", this, buf, count);
1331 return call_basic_streambuf_char_setbuf(this, buf, count);
1334 /* ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1335 /* ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1336 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sync, 4)
1337 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 48, \
1338 int, (basic_streambuf_char*), (this))
1339 int __thiscall basic_streambuf_char_sync(basic_streambuf_char *this)
1341 TRACE("(%p)\n", this);
1345 /* ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1346 /* ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1347 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsync, 4)
1348 int __thiscall basic_streambuf_char_pubsync(basic_streambuf_char *this)
1350 TRACE("(%p)\n", this);
1351 return call_basic_streambuf_char_sync(this);
1354 /* ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPADH@Z */
1355 /* ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z */
1356 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetn, 12)
1357 streamsize __thiscall basic_streambuf_char_sgetn(basic_streambuf_char *this, char *ptr, streamsize count)
1359 TRACE("(%p %p %ld)\n", this, ptr, count);
1360 return call_basic_streambuf_char__Xsgetn_s(this, ptr, -1, count);
1363 /* ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1364 /* ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JXZ */
1365 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_showmanyc, 4)
1366 #define call_basic_streambuf_char_showmanyc(this) CALL_VTBL_FUNC(this, 12, \
1367 streamsize, (basic_streambuf_char*), (this))
1368 streamsize __thiscall basic_streambuf_char_showmanyc(basic_streambuf_char *this)
1370 TRACE("(%p)\n", this);
1374 /* ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1375 /* ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JXZ */
1376 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_in_avail, 4)
1377 streamsize __thiscall basic_streambuf_char_in_avail(basic_streambuf_char *this)
1381 TRACE("(%p)\n", this);
1383 ret = basic_streambuf_char__Gnavail(this);
1384 return ret ? ret : call_basic_streambuf_char_showmanyc(this);
1387 /* ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z */
1388 /* ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z */
1389 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputbackc, 8)
1390 int __thiscall basic_streambuf_char_sputbackc(basic_streambuf_char *this, char ch)
1392 TRACE("(%p %d)\n", this, ch);
1393 if(*this->prpos && *this->prpos>*this->prbuf && (*this->prpos)[-1]==ch) {
1399 return call_basic_streambuf_char_pbackfail(this, ch);
1402 /* ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z */
1403 /* ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z */
1404 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputc, 8)
1405 int __thiscall basic_streambuf_char_sputc(basic_streambuf_char *this, char ch)
1407 TRACE("(%p %d)\n", this, ch);
1408 return basic_streambuf_char__Pnavail(this) ?
1409 (*basic_streambuf_char__Pninc(this) = ch) :
1410 call_basic_streambuf_char_overflow(this, ch);
1413 /* ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1414 /* ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1415 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sungetc, 4)
1416 int __thiscall basic_streambuf_char_sungetc(basic_streambuf_char *this)
1418 TRACE("(%p)\n", this);
1419 if(*this->prpos && *this->prpos>*this->prbuf) {
1422 return **this->prpos;
1425 return call_basic_streambuf_char_pbackfail(this, EOF);
1428 /* ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1429 /* ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1430 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_stossc, 4)
1431 void __thiscall basic_streambuf_char_stossc(basic_streambuf_char *this)
1433 TRACE("(%p)\n", this);
1434 if(basic_streambuf_char__Gnavail(this))
1435 basic_streambuf_char__Gninc(this);
1437 call_basic_streambuf_char_uflow(this);
1440 /* ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1441 /* ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1442 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sbumpc, 4)
1443 int __thiscall basic_streambuf_char_sbumpc(basic_streambuf_char *this)
1445 TRACE("(%p)\n", this);
1446 return basic_streambuf_char__Gnavail(this) ?
1447 *basic_streambuf_char__Gninc(this) : call_basic_streambuf_char_uflow(this);
1450 /* ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1451 /* ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1452 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetc, 4)
1453 int __thiscall basic_streambuf_char_sgetc(basic_streambuf_char *this)
1455 TRACE("(%p)\n", this);
1456 return basic_streambuf_char__Gnavail(this) ?
1457 *basic_streambuf_char_gptr(this) : call_basic_streambuf_char_underflow(this);
1460 /* ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1461 /* ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1462 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_snextc, 4)
1463 int __thiscall basic_streambuf_char_snextc(basic_streambuf_char *this)
1465 TRACE("(%p)\n", this);
1467 if(basic_streambuf_char__Gnavail(this) > 1)
1468 return *basic_streambuf_char__Gnpreinc(this);
1469 return basic_streambuf_char_sbumpc(this)==EOF ?
1470 EOF : basic_streambuf_char_sgetc(this);
1473 /* ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPADH@Z */
1474 /* ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_J@Z */
1475 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsgetn, 12)
1476 #define call_basic_streambuf_char_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 24, \
1477 streamsize, (basic_streambuf_char*, char*, streamsize), (this, ptr, count))
1478 streamsize __thiscall basic_streambuf_char_xsgetn(basic_streambuf_char *this, char *ptr, streamsize count)
1480 TRACE("(%p %p %ld)\n", this, ptr, count);
1481 return call_basic_streambuf_char__Xsgetn_s(this, ptr, -1, count);
1484 /* ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPBDH@Z */
1485 /* ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEBD_J@Z */
1486 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsputn, 12)
1487 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 32, \
1488 streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1489 streamsize __thiscall basic_streambuf_char_xsputn(basic_streambuf_char *this, const char *ptr, streamsize count)
1491 streamsize copied, chunk;
1493 TRACE("(%p %p %ld)\n", this, ptr, count);
1495 for(copied=0; copied<count;) {
1496 chunk = basic_streambuf_char__Pnavail(this);
1497 if(chunk > count-copied)
1498 chunk = count-copied;
1501 memcpy(*this->pwpos, ptr+copied, chunk);
1502 *this->pwpos += chunk;
1503 *this->pwsize -= chunk;
1505 }else if(call_basic_streambuf_char_overflow(this, ptr[copied]) != EOF) {
1515 /* ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPBDH@Z */
1516 /* ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEBD_J@Z */
1517 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputn, 12)
1518 streamsize __thiscall basic_streambuf_char_sputn(basic_streambuf_char *this, const char *ptr, streamsize count)
1520 TRACE("(%p %p %ld)\n", this, ptr, count);
1521 return call_basic_streambuf_char_xsputn(this, ptr, count);
1524 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z */
1525 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z */
1526 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z */
1527 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z */
1528 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setp_next, 16)
1529 void __thiscall basic_streambuf_wchar_setp_next(basic_streambuf_wchar *this, wchar_t *first, wchar_t *next, wchar_t *last)
1531 TRACE("(%p %p %p %p)\n", this, first, next, last);
1535 this->wsize = last-next;
1538 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W0@Z */
1539 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W0@Z */
1540 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG0@Z */
1541 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG0@Z */
1542 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setp, 12)
1543 void __thiscall basic_streambuf_wchar_setp(basic_streambuf_wchar *this, wchar_t *first, wchar_t *last)
1545 basic_streambuf_wchar_setp_next(this, first, first, last);
1548 /* ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z */
1549 /* ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z */
1550 /* ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z */
1551 /* ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z */
1552 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setg, 16)
1553 void __thiscall basic_streambuf_wchar_setg(basic_streambuf_wchar *this, wchar_t *first, wchar_t *next, wchar_t *last)
1555 TRACE("(%p %p %p %p)\n", this, first, next, last);
1559 this->rsize = last-next;
1562 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXXZ */
1563 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXXZ */
1564 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXXZ */
1565 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXXZ */
1566 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Init_empty, 4)
1567 void __thiscall basic_streambuf_wchar__Init_empty(basic_streambuf_wchar *this)
1569 TRACE("(%p)\n", this);
1571 this->prbuf = &this->rbuf;
1572 this->pwbuf = &this->wbuf;
1573 this->prpos = &this->rpos;
1574 this->pwpos = &this->wpos;
1575 this->prsize = &this->rsize;
1576 this->pwsize = &this->wsize;
1578 basic_streambuf_wchar_setp(this, NULL, NULL);
1579 basic_streambuf_wchar_setg(this, NULL, NULL, NULL);
1582 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@W4_Uninitialized@1@@Z */
1583 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
1584 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_ctor_uninitialized, 8)
1585 basic_streambuf_wchar* __thiscall basic_streambuf_wchar_ctor_uninitialized(basic_streambuf_wchar *this, int uninitialized)
1587 TRACE("(%p %d)\n", this, uninitialized);
1588 this->vtable = &MSVCP_basic_streambuf_wchar_vtable;
1589 mutex_ctor(&this->lock);
1593 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@W4_Uninitialized@1@@Z */
1594 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
1595 DEFINE_THISCALL_WRAPPER(basic_streambuf_short_ctor_uninitialized, 8)
1596 basic_streambuf_wchar* __thiscall basic_streambuf_short_ctor_uninitialized(basic_streambuf_wchar *this, int uninitialized)
1598 TRACE("(%p %d)\n", this, uninitialized);
1599 basic_streambuf_wchar_ctor_uninitialized(this, uninitialized);
1600 this->vtable = &MSVCP_basic_streambuf_short_vtable;
1604 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@XZ */
1605 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@XZ */
1606 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_ctor, 4)
1607 basic_streambuf_wchar* __thiscall basic_streambuf_wchar_ctor(basic_streambuf_wchar *this)
1609 TRACE("(%p)\n", this);
1611 this->vtable = &MSVCP_basic_streambuf_wchar_vtable;
1612 mutex_ctor(&this->lock);
1613 this->loc = MSVCRT_operator_new(sizeof(locale));
1614 locale_ctor(this->loc);
1615 basic_streambuf_wchar__Init_empty(this);
1620 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@XZ */
1621 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@XZ */
1622 DEFINE_THISCALL_WRAPPER(basic_streambuf_short_ctor, 4)
1623 basic_streambuf_wchar* __thiscall basic_streambuf_short_ctor(basic_streambuf_wchar *this)
1625 TRACE("(%p)\n", this);
1626 basic_streambuf_wchar_ctor(this);
1627 this->vtable = &MSVCP_basic_streambuf_short_vtable;
1631 /* ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
1632 /* ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
1633 /* ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAE@XZ */
1634 /* ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UEAA@XZ */
1635 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_dtor, 4)
1636 void __thiscall basic_streambuf_wchar_dtor(basic_streambuf_wchar *this)
1638 TRACE("(%p)\n", this);
1640 mutex_dtor(&this->lock);
1641 locale_dtor(this->loc);
1642 MSVCRT_operator_delete(this->loc);
1645 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_vector_dtor, 8)
1646 basic_streambuf_wchar* __thiscall basic_streambuf_wchar_vector_dtor(basic_streambuf_wchar *this, unsigned int flags)
1648 TRACE("(%p %x)\n", this, flags);
1650 /* we have an array, with the number of elements stored before the first object */
1651 INT_PTR i, *ptr = (INT_PTR *)this-1;
1653 for(i=*ptr-1; i>=0; i--)
1654 basic_streambuf_wchar_dtor(this+i);
1655 MSVCRT_operator_delete(ptr);
1657 basic_streambuf_wchar_dtor(this);
1659 MSVCRT_operator_delete(this);
1665 /* ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
1666 /* ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ */
1667 /* ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEHXZ */
1668 /* ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ */
1669 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gnavail, 4)
1670 streamsize __thiscall basic_streambuf_wchar__Gnavail(const basic_streambuf_wchar *this)
1672 TRACE("(%p)\n", this);
1673 return *this->prpos ? *this->prsize : 0;
1676 /* ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1677 /* ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1678 /* ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1679 /* ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1680 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gndec, 4)
1681 wchar_t* __thiscall basic_streambuf_wchar__Gndec(basic_streambuf_wchar *this)
1683 TRACE("(%p)\n", this);
1686 return *this->prpos;
1689 /* ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1690 /* ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1691 /* ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1692 /* ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1693 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gninc, 4)
1694 wchar_t* __thiscall basic_streambuf_wchar__Gninc(basic_streambuf_wchar *this)
1696 TRACE("(%p)\n", this);
1698 return (*this->prpos)++;
1701 /* ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1702 /* ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1703 /* ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1704 /* ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1705 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gnpreinc, 4)
1706 wchar_t* __thiscall basic_streambuf_wchar__Gnpreinc(basic_streambuf_wchar *this)
1708 TRACE("(%p)\n", this);
1711 return *this->prpos;
1714 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPAPA_W0PAH001@Z */
1715 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAPEA_W0PEAH001@Z */
1716 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAPAG0PAH001@Z */
1717 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAPEAG0PEAH001@Z */
1718 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Init, 28)
1719 void __thiscall basic_streambuf_wchar__Init(basic_streambuf_wchar *this, wchar_t **gf, wchar_t **gn, int *gc, wchar_t **pf, wchar_t **pn, int *pc)
1721 TRACE("(%p %p %p %p %p %p %p)\n", this, gf, gn, gc, pf, pn, pc);
1731 /* ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
1732 /* ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
1733 /* ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
1734 /* ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
1735 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Lock, 4)
1736 void __thiscall basic_streambuf_wchar__Lock(basic_streambuf_wchar *this)
1738 TRACE("(%p)\n", this);
1739 mutex_lock(&this->lock);
1742 /* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
1743 /* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ */
1744 /* ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEHXZ */
1745 /* ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ */
1746 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Pnavail, 4)
1747 streamsize __thiscall basic_streambuf_wchar__Pnavail(const basic_streambuf_wchar *this)
1749 TRACE("(%p)\n", this);
1750 return *this->pwpos ? *this->pwsize : 0;
1753 /* ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1754 /* ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1755 /* ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1756 /* ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1757 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Pninc, 4)
1758 wchar_t* __thiscall basic_streambuf_wchar__Pninc(basic_streambuf_wchar *this)
1760 TRACE("(%p)\n", this);
1762 return (*this->pwpos)++;
1765 /* ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
1766 /* ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
1767 /* ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
1768 /* ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
1769 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_underflow, 4)
1770 #define call_basic_streambuf_wchar_underflow(this) CALL_VTBL_FUNC(this, 16, \
1771 unsigned short, (basic_streambuf_wchar*), (this))
1772 unsigned short __thiscall basic_streambuf_wchar_underflow(basic_streambuf_wchar *this)
1774 TRACE("(%p)\n", this);
1778 /* ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
1779 /* ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
1780 /* ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
1781 /* ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
1782 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_uflow, 4)
1783 #define call_basic_streambuf_wchar_uflow(this) CALL_VTBL_FUNC(this, 20, \
1784 unsigned short, (basic_streambuf_wchar*), (this))
1785 unsigned short __thiscall basic_streambuf_wchar_uflow(basic_streambuf_wchar *this)
1789 TRACE("(%p)\n", this);
1791 if(call_basic_streambuf_wchar_underflow(this)==WEOF)
1794 ret = **this->prpos;
1800 /* ?_Xsgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPA_WIH@Z */
1801 /* ?_Xsgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_K_J@Z */
1802 /* ?_Xsgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPAGIH@Z */
1803 /* ?_Xsgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_K_J@Z */
1804 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Xsgetn_s, 16)
1805 #define call_basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count) CALL_VTBL_FUNC(this, 28, \
1806 streamsize, (basic_streambuf_wchar*, wchar_t*, MSVCP_size_t, streamsize), (this, ptr, size, count))
1807 streamsize __thiscall basic_streambuf_wchar__Xsgetn_s(basic_streambuf_wchar *this, wchar_t *ptr, MSVCP_size_t size, streamsize count)
1809 streamsize copied, chunk;
1812 TRACE("(%p %p %lu %ld)\n", this, ptr, size, count);
1814 for(copied=0; copied<count && size;) {
1815 chunk = basic_streambuf_wchar__Gnavail(this);
1816 if(chunk > count-copied)
1817 chunk = count-copied;
1820 memcpy_s(ptr+copied, size, *this->prpos, chunk*sizeof(wchar_t));
1821 *this->prpos += chunk;
1822 *this->prsize -= chunk;
1824 size -= chunk*sizeof(wchar_t);
1825 }else if((c = call_basic_streambuf_wchar_uflow(this)) != WEOF) {
1837 /* ?_Sgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPA_WIH@Z */
1838 /* ?_Sgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_K_J@Z */
1839 /* ?_Sgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPAGIH@Z */
1840 /* ?_Sgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_K_J@Z */
1841 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Sgetn_s, 16)
1842 streamsize __thiscall basic_streambuf_wchar__Sgetn_s(basic_streambuf_wchar *this, wchar_t *ptr, MSVCP_size_t size, streamsize count)
1844 TRACE("(%p %p %lu %ld)\n", this, ptr, size, count);
1845 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count);
1848 /* ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
1849 /* ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
1850 /* ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
1851 /* ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
1852 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Unlock, 4)
1853 void __thiscall basic_streambuf_wchar__Unlock(basic_streambuf_wchar *this)
1855 TRACE("(%p)\n", this);
1856 mutex_unlock(&this->lock);
1859 /* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
1860 /* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
1861 /* ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
1862 /* ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
1863 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_eback, 4)
1864 wchar_t* __thiscall basic_streambuf_wchar_eback(const basic_streambuf_wchar *this)
1866 TRACE("(%p)\n", this);
1867 return *this->prbuf;
1870 /* ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
1871 /* ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
1872 /* ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
1873 /* ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
1874 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_gptr, 4)
1875 wchar_t* __thiscall basic_streambuf_wchar_gptr(const basic_streambuf_wchar *this)
1877 TRACE("(%p)\n", this);
1878 return *this->prpos;
1881 /* ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
1882 /* ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
1883 /* ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
1884 /* ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
1885 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_egptr, 4)
1886 wchar_t* __thiscall basic_streambuf_wchar_egptr(const basic_streambuf_wchar *this)
1888 TRACE("(%p)\n", this);
1889 return *this->prpos+*this->prsize;
1892 /* ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
1893 /* ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
1894 /* ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
1895 /* ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
1896 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_epptr, 4)
1897 wchar_t* __thiscall basic_streambuf_wchar_epptr(const basic_streambuf_wchar *this)
1899 TRACE("(%p)\n", this);
1900 return *this->pwpos+*this->pwsize;
1903 /* ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z */
1904 /* ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z */
1905 /* ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z */
1906 /* ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z */
1907 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_gbump, 8)
1908 void __thiscall basic_streambuf_wchar_gbump(basic_streambuf_wchar *this, int off)
1910 TRACE("(%p %d)\n", this, off);
1911 *this->prpos += off;
1912 *this->prsize -= off;
1915 /* ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QBE?AVlocale@2@XZ */
1916 /* ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEBA?AVlocale@2@XZ */
1917 /* ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QBE?AVlocale@2@XZ */
1918 /* ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEBA?AVlocale@2@XZ */
1919 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_getloc, 8)
1920 locale* __thiscall basic_streambuf_wchar_getloc(const basic_streambuf_wchar *this, locale *ret)
1922 TRACE("(%p)\n", this);
1923 return locale_copy_ctor(ret, this->loc);
1926 /* ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z */
1927 /* ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z */
1928 /* ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z */
1929 /* ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z */
1930 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_imbue, 8)
1931 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 52, \
1932 void, (basic_streambuf_wchar*, const locale*), (this, loc))
1933 void __thiscall basic_streambuf_wchar_imbue(basic_streambuf_wchar *this, const locale *loc)
1935 TRACE("(%p %p)\n", this, loc);
1938 /* ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
1939 /* ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
1940 /* ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
1941 /* ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
1942 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_overflow, 8)
1943 #define call_basic_streambuf_wchar_overflow(this, ch) CALL_VTBL_FUNC(this, 4, \
1944 unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
1945 unsigned short __thiscall basic_streambuf_wchar_overflow(basic_streambuf_wchar *this, unsigned short ch)
1947 TRACE("(%p %d)\n", this, ch);
1951 /* ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
1952 /* ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
1953 /* ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
1954 /* ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
1955 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbackfail, 8)
1956 #define call_basic_streambuf_wchar_pbackfail(this, ch) CALL_VTBL_FUNC(this, 8, \
1957 unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
1958 unsigned short __thiscall basic_streambuf_wchar_pbackfail(basic_streambuf_wchar *this, unsigned short ch)
1960 TRACE("(%p %d)\n", this, ch);
1964 /* ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
1965 /* ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
1966 /* ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
1967 /* ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
1968 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbase, 4)
1969 wchar_t* __thiscall basic_streambuf_wchar_pbase(const basic_streambuf_wchar *this)
1971 TRACE("(%p)\n", this);
1972 return *this->pwbuf;
1975 /* ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z */
1976 /* ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z */
1977 /* ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z */
1978 /* ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z */
1979 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbump, 8)
1980 void __thiscall basic_streambuf_wchar_pbump(basic_streambuf_wchar *this, int off)
1982 TRACE("(%p %d)\n", this, off);
1983 *this->pwpos += off;
1984 *this->pwsize -= off;
1987 /* ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
1988 /* ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
1989 /* ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
1990 /* ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
1991 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pptr, 4)
1992 wchar_t* __thiscall basic_streambuf_wchar_pptr(const basic_streambuf_wchar *this)
1994 TRACE("(%p)\n", this);
1995 return *this->pwpos;
1998 /* ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
1999 /* ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
2000 /* ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
2001 /* ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
2002 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubimbue, 12)
2003 locale* __thiscall basic_streambuf_wchar_pubimbue(basic_streambuf_wchar *this, locale *ret, const locale *loc)
2005 TRACE("(%p %p)\n", this, loc);
2006 memcpy(ret, this->loc, sizeof(locale));
2007 call_basic_streambuf_wchar_imbue(this, loc);
2008 locale_copy_ctor(this->loc, loc);
2012 /* ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2013 /* ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2014 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2015 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2016 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekoff, 20)
2017 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 36, \
2018 fpos_int*, (basic_streambuf_wchar*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
2019 fpos_int* __thiscall basic_streambuf_wchar_seekoff(basic_streambuf_wchar *this,
2020 fpos_int *ret, streamoff off, int way, int mode)
2022 TRACE("(%p %ld %d %d)\n", this, off, way, mode);
2029 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
2030 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
2031 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
2032 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
2033 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff, 20)
2034 fpos_int* __thiscall basic_streambuf_wchar_pubseekoff(basic_streambuf_wchar *this,
2035 fpos_int *ret, streamoff off, int way, int mode)
2037 TRACE("(%p %ld %d %d)\n", this, off, way, mode);
2038 return call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode);
2041 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
2042 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
2043 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
2044 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
2045 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff_old, 20)
2046 fpos_int* __thiscall basic_streambuf_wchar_pubseekoff_old(basic_streambuf_wchar *this,
2047 fpos_int *ret, streamoff off, unsigned int way, unsigned int mode)
2049 TRACE("(%p %ld %d %d)\n", this, off, way, mode);
2050 return basic_streambuf_wchar_pubseekoff(this, ret, off, way, mode);
2053 /* ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2054 /* ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2055 /* ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2056 /* ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2057 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekpos, 36)
2058 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 40, \
2059 fpos_int*, (basic_streambuf_wchar*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
2060 fpos_int* __thiscall basic_streambuf_wchar_seekpos(basic_streambuf_wchar *this,
2061 fpos_int *ret, fpos_int pos, int mode)
2063 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos), mode);
2070 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
2071 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
2072 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
2073 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
2074 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekpos, 36)
2075 fpos_int* __thiscall basic_streambuf_wchar_pubseekpos(basic_streambuf_wchar *this,
2076 fpos_int *ret, fpos_int pos, int mode)
2078 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos), mode);
2079 return call_basic_streambuf_wchar_seekpos(this, ret, pos, mode);
2082 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
2083 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
2084 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
2085 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
2086 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekpos_old, 36)
2087 fpos_int* __thiscall basic_streambuf_wchar_pubseekpos_old(basic_streambuf_wchar *this,
2088 fpos_int *ret, fpos_int pos, unsigned int mode)
2090 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos), mode);
2091 return basic_streambuf_wchar_pubseekpos(this, ret, pos, mode);
2094 /* ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEPAV12@PA_WH@Z */
2095 /* ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV12@PEA_W_J@Z */
2096 /* ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEPAV12@PAGH@Z */
2097 /* ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAPEAV12@PEAG_J@Z */
2098 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setbuf, 12)
2099 #define call_basic_streambuf_wchar_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 44, \
2100 basic_streambuf_wchar*, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, buf, count))
2101 basic_streambuf_wchar* __thiscall basic_streambuf_wchar_setbuf(basic_streambuf_wchar *this, wchar_t *buf, streamsize count)
2103 TRACE("(%p %p %ld)\n", this, buf, count);
2107 /* ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PA_WH@Z */
2108 /* ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEA_W_J@Z */
2109 /* ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PAGH@Z */
2110 /* ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEAG_J@Z */
2111 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsetbuf, 12)
2112 basic_streambuf_wchar* __thiscall basic_streambuf_wchar_pubsetbuf(basic_streambuf_wchar *this, wchar_t *buf, streamsize count)
2114 TRACE("(%p %p %ld)\n", this, buf, count);
2115 return call_basic_streambuf_wchar_setbuf(this, buf, count);
2118 /* ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
2119 /* ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ */
2120 /* ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
2121 /* ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAHXZ */
2122 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sync, 4)
2123 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 48, \
2124 int, (basic_streambuf_wchar*), (this))
2125 int __thiscall basic_streambuf_wchar_sync(basic_streambuf_wchar *this)
2127 TRACE("(%p)\n", this);
2131 /* ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
2132 /* ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAHXZ */
2133 /* ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ */
2134 /* ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHXZ */
2135 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsync, 4)
2136 int __thiscall basic_streambuf_wchar_pubsync(basic_streambuf_wchar *this)
2138 TRACE("(%p)\n", this);
2139 return call_basic_streambuf_wchar_sync(this);
2142 /* ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPA_WH@Z */
2143 /* ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z */
2144 /* ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPAGH@Z */
2145 /* ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z */
2146 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetn, 12)
2147 streamsize __thiscall basic_streambuf_wchar_sgetn(basic_streambuf_wchar *this, wchar_t *ptr, streamsize count)
2149 TRACE("(%p %p %ld)\n", this, ptr, count);
2150 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr, -1, count);
2153 /* ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
2154 /* ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JXZ */
2155 /* ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
2156 /* ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JXZ */
2157 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_showmanyc, 4)
2158 #define call_basic_streambuf_wchar_showmanyc(this) CALL_VTBL_FUNC(this, 12, \
2159 streamsize, (basic_streambuf_wchar*), (this))
2160 streamsize __thiscall basic_streambuf_wchar_showmanyc(basic_streambuf_wchar *this)
2162 TRACE("(%p)\n", this);
2166 /* ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
2167 /* ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JXZ */
2168 /* ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ */
2169 /* ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JXZ */
2170 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_in_avail, 4)
2171 streamsize __thiscall basic_streambuf_wchar_in_avail(basic_streambuf_wchar *this)
2175 TRACE("(%p)\n", this);
2177 ret = basic_streambuf_wchar__Gnavail(this);
2178 return ret ? ret : call_basic_streambuf_wchar_showmanyc(this);
2181 /* ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z */
2182 /* ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z */
2183 /* ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z */
2184 /* ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGG@Z */
2185 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputbackc, 8)
2186 unsigned short __thiscall basic_streambuf_wchar_sputbackc(basic_streambuf_wchar *this, wchar_t ch)
2188 TRACE("(%p %d)\n", this, ch);
2189 if(*this->prpos && *this->prpos>*this->prbuf && (*this->prpos)[-1]==ch) {
2195 return call_basic_streambuf_wchar_pbackfail(this, ch);
2198 /* ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z */
2199 /* ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z */
2200 /* ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z */
2201 /* ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHG@Z */
2202 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputc, 8)
2203 unsigned short __thiscall basic_streambuf_wchar_sputc(basic_streambuf_wchar *this, wchar_t ch)
2205 TRACE("(%p %d)\n", this, ch);
2206 return basic_streambuf_wchar__Pnavail(this) ?
2207 (*basic_streambuf_wchar__Pninc(this) = ch) :
2208 call_basic_streambuf_wchar_overflow(this, ch);
2211 /* ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2212 /* ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2213 /* ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2214 /* ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2215 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sungetc, 4)
2216 unsigned short __thiscall basic_streambuf_wchar_sungetc(basic_streambuf_wchar *this)
2218 TRACE("(%p)\n", this);
2219 if(*this->prpos && *this->prpos>*this->prbuf) {
2222 return **this->prpos;
2225 return call_basic_streambuf_wchar_pbackfail(this, WEOF);
2228 /* ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2229 /* ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2230 /* ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2231 /* ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2232 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_stossc, 4)
2233 void __thiscall basic_streambuf_wchar_stossc(basic_streambuf_wchar *this)
2235 TRACE("(%p)\n", this);
2236 if(basic_streambuf_wchar__Gnavail(this))
2237 basic_streambuf_wchar__Gninc(this);
2239 call_basic_streambuf_wchar_uflow(this);
2242 /* ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2243 /* ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2244 /* ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2245 /* ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2246 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sbumpc, 4)
2247 unsigned short __thiscall basic_streambuf_wchar_sbumpc(basic_streambuf_wchar *this)
2249 TRACE("(%p)\n", this);
2250 return basic_streambuf_wchar__Gnavail(this) ?
2251 *basic_streambuf_wchar__Gninc(this) : call_basic_streambuf_wchar_uflow(this);
2254 /* ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2255 /* ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2256 /* ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2257 /* ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2258 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetc, 4)
2259 unsigned short __thiscall basic_streambuf_wchar_sgetc(basic_streambuf_wchar *this)
2261 TRACE("(%p)\n", this);
2262 return basic_streambuf_wchar__Gnavail(this) ?
2263 *basic_streambuf_wchar_gptr(this) : call_basic_streambuf_wchar_underflow(this);
2266 /* ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2267 /* ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2268 /* ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2269 /* ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2270 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_snextc, 4)
2271 unsigned short __thiscall basic_streambuf_wchar_snextc(basic_streambuf_wchar *this)
2273 TRACE("(%p)\n", this);
2275 if(basic_streambuf_wchar__Gnavail(this) > 1)
2276 return *basic_streambuf_wchar__Gnpreinc(this);
2277 return basic_streambuf_wchar_sbumpc(this)==WEOF ?
2278 WEOF : basic_streambuf_wchar_sgetc(this);
2281 /* ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPA_WH@Z */
2282 /* ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_J@Z */
2283 /* ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPAGH@Z */
2284 /* ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_J@Z */
2285 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsgetn, 12)
2286 #define call_basic_streambuf_wchar_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 24, \
2287 streamsize, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, ptr, count))
2288 streamsize __thiscall basic_streambuf_wchar_xsgetn(basic_streambuf_wchar *this, wchar_t *ptr, streamsize count)
2290 TRACE("(%p %p %ld)\n", this, ptr, count);
2291 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr, -1, count);
2294 /* ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPB_WH@Z */
2295 /* ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEB_W_J@Z */
2296 /* ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPBGH@Z */
2297 /* ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEBG_J@Z */
2298 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsputn, 12)
2299 #define call_basic_streambuf_wchar_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 32, \
2300 streamsize, (basic_streambuf_wchar*, const wchar_t*, streamsize), (this, ptr, count))
2301 streamsize __thiscall basic_streambuf_wchar_xsputn(basic_streambuf_wchar *this, const wchar_t *ptr, streamsize count)
2303 streamsize copied, chunk;
2305 TRACE("(%p %p %ld)\n", this, ptr, count);
2307 for(copied=0; copied<count;) {
2308 chunk = basic_streambuf_wchar__Pnavail(this);
2309 if(chunk > count-copied)
2310 chunk = count-copied;
2313 memcpy(*this->pwpos, ptr+copied, chunk*sizeof(wchar_t));
2314 *this->pwpos += chunk;
2315 *this->pwsize -= chunk;
2317 }else if(call_basic_streambuf_wchar_overflow(this, ptr[copied]) != WEOF) {
2327 /* ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPB_WH@Z */
2328 /* ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEB_W_J@Z */
2329 /* ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPBGH@Z */
2330 /* ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEBG_J@Z */
2331 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputn, 12)
2332 streamsize __thiscall basic_streambuf_wchar_sputn(basic_streambuf_wchar *this, const wchar_t *ptr, streamsize count)
2334 TRACE("(%p %p %ld)\n", this, ptr, count);
2335 return call_basic_streambuf_wchar_xsputn(this, ptr, count);
2338 /* ?_Stinit@?1??_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
2339 /* ?_Stinit@?1??_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
2340 int basic_filebuf_char__Init__Stinit = 0;
2342 /* ?_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
2343 /* ?_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
2344 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Init, 12)
2345 void __thiscall basic_filebuf_char__Init(basic_filebuf_char *this, FILE *file, basic_filebuf__Initfl which)
2347 TRACE("(%p %p %d)\n", this, file, which);
2350 this->wrotesome = FALSE;
2351 this->state = basic_filebuf_char__Init__Stinit;
2352 this->close = (which == INITFL_open);
2355 basic_streambuf_char__Init_empty(&this->base);
2357 basic_streambuf_char__Init(&this->base, &file->_base, &file->_ptr,
2358 &file->_cnt, &file->_base, &file->_ptr, &file->_cnt);
2361 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAV?$codecvt@DDH@2@@Z */
2362 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$codecvt@DDH@2@@Z */
2363 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Initcvt, 8)
2364 void __thiscall basic_filebuf_char__Initcvt(basic_filebuf_char *this, codecvt_char *cvt)
2366 TRACE("(%p %p)\n", this, cvt);
2368 if(codecvt_base_always_noconv(&cvt->base)) {
2371 basic_streambuf_char__Init_empty(&this->base);
2376 /* ?_Endwrite@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAE_NXZ */
2377 /* ?_Endwrite@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAA_NXZ */
2378 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Endwrite, 4)
2379 MSVCP_bool __thiscall basic_filebuf_char__Endwrite(basic_filebuf_char *this)
2381 TRACE("(%p)\n", this);
2383 if(!this->wrotesome || !this->cvt)
2387 if(call_basic_streambuf_char_overflow(&this->base, EOF) == EOF)
2391 /* TODO: check if we need a dynamic buffer here */
2396 ret = codecvt_char_unshift(this->cvt, &this->state, buf, buf+sizeof(buf), &next);
2399 this->wrotesome = FALSE;
2401 case CODECVT_partial:
2402 if(!fwrite(buf, next-buf, 1, this->file))
2407 case CODECVT_noconv:
2408 if(call_basic_streambuf_char_overflow(&this->base, EOF) == EOF)
2417 /* ?close@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@XZ */
2418 /* ?close@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@XZ */
2419 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_close, 4)
2420 basic_filebuf_char* __thiscall basic_filebuf_char_close(basic_filebuf_char *this)
2422 basic_filebuf_char *ret = this;
2424 TRACE("(%p)\n", this);
2429 /* TODO: handle exceptions */
2430 if(!basic_filebuf_char__Endwrite(this))
2432 if(fclose(this->file))
2435 basic_filebuf_char__Init(this, NULL, INITFL_close);
2439 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
2440 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
2441 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor_file, 8)
2442 basic_filebuf_char* __thiscall basic_filebuf_char_ctor_file(basic_filebuf_char *this, FILE *file)
2444 TRACE("(%p %p)\n", this, file);
2446 basic_streambuf_char_ctor(&this->base);
2447 this->base.vtable = &MSVCP_basic_filebuf_char_vtable;
2449 basic_filebuf_char__Init(this, file, INITFL_new);
2453 /* ??_F?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
2454 /* ??_F?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
2455 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor, 4)
2456 basic_filebuf_char* __thiscall basic_filebuf_char_ctor(basic_filebuf_char *this)
2458 return basic_filebuf_char_ctor_file(this, NULL);
2461 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z */
2462 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
2463 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor_uninitialized, 8)
2464 basic_filebuf_char* __thiscall basic_filebuf_char_ctor_uninitialized(basic_filebuf_char *this, int uninitialized)
2466 TRACE("(%p %d)\n", this, uninitialized);
2468 basic_streambuf_char_ctor(&this->base);
2469 this->base.vtable = &MSVCP_basic_filebuf_char_vtable;
2473 /* ??1?$basic_filebuf@DU?$char_traits@D@std@@@std@@UAE@XZ */
2474 /* ??1?$basic_filebuf@DU?$char_traits@D@std@@@std@@UEAA@XZ */
2475 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_dtor, 4)
2476 void __thiscall basic_filebuf_char_dtor(basic_filebuf_char *this)
2478 TRACE("(%p)\n", this);
2481 basic_filebuf_char_close(this);
2482 basic_streambuf_char_dtor(&this->base);
2485 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_vector_dtor, 8)
2486 basic_filebuf_char* __thiscall basic_filebuf_char_vector_dtor(basic_filebuf_char *this, unsigned int flags)
2488 TRACE("(%p %x)\n", this, flags);
2490 /* we have an array, with the number of elements stored before the first object */
2491 INT_PTR i, *ptr = (INT_PTR *)this-1;
2493 for(i=*ptr-1; i>=0; i--)
2494 basic_filebuf_char_dtor(this+i);
2495 MSVCRT_operator_delete(ptr);
2497 basic_filebuf_char_dtor(this);
2499 MSVCRT_operator_delete(this);
2505 /* ?is_open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QBE_NXZ */
2506 /* ?is_open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
2507 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_is_open, 4)
2508 MSVCP_bool __thiscall basic_filebuf_char_is_open(const basic_filebuf_char *this)
2510 TRACE("(%p)\n", this);
2511 return this->file != NULL;
2514 /* ?_Fiopen@std@@YAPAU_iobuf@@PB_WHH@Z */
2515 /* ?_Fiopen@std@@YAPEAU_iobuf@@PEB_WHH@Z */
2516 FILE* __cdecl _Fiopen_wchar(const wchar_t *name, int mode, int prot)
2518 static const wchar_t rW[] = {'r',0};
2519 static const struct {
2521 const wchar_t str[4];
2522 const wchar_t str_bin[4];
2524 {OPENMODE_out, {'w',0}, {'w','b',0}},
2525 {OPENMODE_out|OPENMODE_app, {'a',0}, {'a','b',0}},
2526 {OPENMODE_app, {'a',0}, {'a','b',0}},
2527 {OPENMODE_out|OPENMODE_trunc, {'w',0}, {'w','b',0}},
2528 {OPENMODE_in, {'r',0}, {'r','b',0}},
2529 {OPENMODE_in|OPENMODE_out, {'r','+',0}, {'r','+','b',0}},
2530 {OPENMODE_in|OPENMODE_out|OPENMODE_trunc, {'w','+',0}, {'w','+','b',0}},
2531 {OPENMODE_in|OPENMODE_out|OPENMODE_app, {'a','+',0}, {'a','+','b',0}},
2532 {OPENMODE_in|OPENMODE_app, {'a','+',0}, {'a','+','b',0}}
2535 int real_mode = mode & ~(OPENMODE_ate|OPENMODE__Nocreate|OPENMODE__Noreplace|OPENMODE_binary);
2539 TRACE("(%s %d %d)\n", debugstr_w(name), mode, prot);
2541 for(mode_idx=0; mode_idx<sizeof(str_mode)/sizeof(str_mode[0]); mode_idx++)
2542 if(str_mode[mode_idx].mode == real_mode)
2544 if(mode_idx == sizeof(str_mode)/sizeof(str_mode[0]))
2547 if((mode & OPENMODE__Nocreate) && !(f = _wfopen(name, rW)))
2552 if((mode & OPENMODE__Noreplace) && (mode & (OPENMODE_out|OPENMODE_app))
2553 && (f = _wfopen(name, rW))) {
2558 f = _wfsopen(name, (mode & OPENMODE_binary) ? str_mode[mode_idx].str_bin
2559 : str_mode[mode_idx].str, prot);
2563 if((mode & OPENMODE_ate) && fseek(f, 0, SEEK_END)) {
2571 /* ?_Fiopen@std@@YAPAU_iobuf@@PBDHH@Z */
2572 /* ?_Fiopen@std@@YAPEAU_iobuf@@PEBDHH@Z */
2573 FILE* __cdecl _Fiopen(const char *name, int mode, int prot)
2575 wchar_t nameW[FILENAME_MAX];
2577 TRACE("(%s %d %d)\n", name, mode, prot);
2579 if(mbstowcs_s(NULL, nameW, FILENAME_MAX, name, FILENAME_MAX-1) != 0)
2581 return _Fiopen_wchar(nameW, mode, prot);
2584 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PB_WHH@Z */
2585 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
2586 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBGHH@Z */
2587 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBGHH@Z */
2588 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_wchar, 16)
2589 basic_filebuf_char* __thiscall basic_filebuf_char_open_wchar(basic_filebuf_char *this, const wchar_t *name, int mode, int prot)
2593 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
2595 if(basic_filebuf_char_is_open(this))
2598 if(!(f = _Fiopen_wchar(name, mode, prot)))
2601 basic_filebuf_char__Init(this, f, INITFL_open);
2602 basic_filebuf_char__Initcvt(this, codecvt_char_use_facet(this->base.loc));
2606 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PB_WI@Z */
2607 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEB_WI@Z */
2608 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBGI@Z */
2609 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBGI@Z */
2610 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_wchar_mode, 12)
2611 basic_filebuf_char* __thiscall basic_filebuf_char_open_wchar_mode(basic_filebuf_char *this, const wchar_t *name, unsigned int mode)
2613 return basic_filebuf_char_open_wchar(this, name, mode, SH_DENYNO);
2616 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDHH@Z */
2617 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDHH@Z */
2618 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open, 16)
2619 basic_filebuf_char* __thiscall basic_filebuf_char_open(basic_filebuf_char *this, const char *name, int mode, int prot)
2621 wchar_t nameW[FILENAME_MAX];
2623 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
2625 if(mbstowcs_s(NULL, nameW, FILENAME_MAX, name, FILENAME_MAX-1) != 0)
2627 return basic_filebuf_char_open_wchar(this, nameW, mode, prot);
2630 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDI@Z */
2631 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDI@Z */
2632 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_mode, 12)
2633 basic_filebuf_char* __thiscall basic_filebuf_char_open_mode(basic_filebuf_char *this, const char *name, unsigned int mode)
2635 return basic_filebuf_char_open(this, name, mode, SH_DENYNO);
2638 /* ?overflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
2639 /* ?overflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
2640 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_overflow, 8)
2641 int __thiscall basic_filebuf_char_overflow(basic_filebuf_char *this, int c)
2643 char buf[8], *dyn_buf;
2644 char ch = c, *to_next;
2645 const char *from_next;
2649 TRACE("(%p %d)\n", this, c);
2651 if(!basic_filebuf_char_is_open(this))
2657 return fwrite(&ch, sizeof(char), 1, this->file) ? c : EOF;
2661 ret = codecvt_char_out(this->cvt, &this->state, from_next, &ch+1,
2662 &from_next, buf, buf+sizeof(buf), &to_next);
2665 case CODECVT_partial:
2670 if(!fwrite(buf, to_next-buf, 1, this->file))
2672 if(ret == CODECVT_partial)
2675 case CODECVT_noconv:
2676 return fwrite(&ch, sizeof(char), 1, this->file) ? c : EOF;
2684 max_size = codecvt_base_max_length(&this->cvt->base);
2685 dyn_buf = malloc(max_size);
2689 ret = codecvt_char_out(this->cvt, &this->state, from_next, &ch+1,
2690 &from_next, dyn_buf, dyn_buf+max_size, &to_next);
2694 ret = fwrite(dyn_buf, to_next-dyn_buf, 1, this->file);
2696 return ret ? c : EOF;
2697 case CODECVT_partial:
2698 ERR("buffer should be big enough to store all output\n");
2706 /* ?pbackfail@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
2707 /* ?pbackfail@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
2708 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_pbackfail, 8)
2709 int __thiscall basic_filebuf_char_pbackfail(basic_filebuf_char *this, int c)
2711 TRACE("(%p %d)\n", this, c);
2713 if(!basic_filebuf_char_is_open(this))
2716 if(basic_streambuf_char_gptr(&this->base)>basic_streambuf_char_eback(&this->base)
2717 && (c==EOF || basic_streambuf_char_gptr(&this->base)[-1]==(char)c)) {
2718 basic_streambuf_char__Gndec(&this->base);
2719 return c==EOF ? !c : c;
2720 }else if(c!=EOF && !this->cvt) {
2721 return ungetc(c, this->file);
2727 /* ?uflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
2728 /* ?uflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
2729 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_uflow, 4)
2730 int __thiscall basic_filebuf_char_uflow(basic_filebuf_char *this)
2732 char ch, buf[128], *to_next;
2733 const char *buf_next;
2736 TRACE("(%p)\n", this);
2738 if(!basic_filebuf_char_is_open(this))
2741 if(basic_streambuf_char_gptr(&this->base) < basic_streambuf_char_egptr(&this->base))
2742 return *basic_streambuf_char__Gninc(&this->base);
2744 c = fgetc(this->file);
2745 if(!this->cvt || c==EOF)
2749 for(i=0; i < sizeof(buf)/sizeof(buf[0]); i++) {
2752 switch(codecvt_char_in(this->cvt, &this->state, buf_next,
2753 buf+i+1, &buf_next, &ch, &ch+1, &to_next)) {
2754 case CODECVT_partial:
2756 if(to_next == &ch) {
2757 c = fgetc(this->file);
2763 for(i--; i>=buf_next-buf; i--)
2764 ungetc(buf[i], this->file);
2766 case CODECVT_noconv:
2773 FIXME("buffer is too small\n");
2777 /* ?underflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
2778 /* ?underflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
2779 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_underflow, 4)
2780 int __thiscall basic_filebuf_char_underflow(basic_filebuf_char *this)
2784 TRACE("(%p)\n", this);
2786 if(basic_streambuf_char_gptr(&this->base) < basic_streambuf_char_egptr(&this->base))
2787 return *basic_streambuf_char_gptr(&this->base);
2789 ret = call_basic_streambuf_char_uflow(&this->base);
2791 ret = call_basic_streambuf_char_pbackfail(&this->base, ret);
2795 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2796 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2797 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekoff, 20)
2798 fpos_int* __thiscall basic_filebuf_char_seekoff(basic_filebuf_char *this,
2799 fpos_int *ret, streamoff off, int way, int mode)
2803 TRACE("(%p %p %ld %d %d)\n", this, ret, off, way, mode);
2805 if(!basic_filebuf_char_is_open(this) || !basic_filebuf_char__Endwrite(this)
2806 || fseek(this->file, off, way)) {
2813 fgetpos(this->file, &pos);
2816 ret->state = this->state;
2820 /* ?seekpos@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2821 /* ?seekpos@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2822 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekpos, 36)
2823 fpos_int* __thiscall basic_filebuf_char_seekpos(basic_filebuf_char *this,
2824 fpos_int *ret, fpos_int pos, int mode)
2828 TRACE("(%p %p %s %d)\n", this, ret, debugstr_fpos_int(&pos), mode);
2830 if(!basic_filebuf_char_is_open(this) || !basic_filebuf_char__Endwrite(this)
2831 || fseek(this->file, (LONG)pos.pos, SEEK_SET)
2832 || (pos.off && fseek(this->file, pos.off, SEEK_CUR))) {
2839 fgetpos(this->file, &fpos);
2842 ret->state = this->state;
2846 /* ?setbuf@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PADH@Z */
2847 /* ?setbuf@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAD_J@Z */
2848 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_setbuf, 12)
2849 basic_streambuf_char* __thiscall basic_filebuf_char_setbuf(basic_filebuf_char *this, char *buf, streamsize count)
2851 TRACE("(%p %p %ld)\n", this, buf, count);
2853 if(!basic_filebuf_char_is_open(this))
2856 if(setvbuf(this->file, buf, (buf==NULL && count==0) ? _IONBF : _IOFBF, count))
2859 basic_filebuf_char__Init(this, this->file, INITFL_open);
2863 /* ?sync@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
2864 /* ?sync@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
2865 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_sync, 4)
2866 int __thiscall basic_filebuf_char_sync(basic_filebuf_char *this)
2868 TRACE("(%p)\n", this);
2870 if(!basic_filebuf_char_is_open(this))
2873 if(call_basic_streambuf_char_overflow(&this->base, EOF) == EOF)
2875 return fflush(this->file);
2878 /* ?imbue@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z */
2879 /* ?imbue@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z */
2880 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_imbue, 8)
2881 void __thiscall basic_filebuf_char_imbue(basic_filebuf_char *this, const locale *loc)
2883 TRACE("(%p %p)\n", this, loc);
2884 basic_filebuf_char__Initcvt(this, codecvt_char_use_facet(loc));
2887 /* ?_Stinit@?1??_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
2888 /* ?_Stinit@?1??_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
2889 int basic_filebuf_wchar__Init__Stinit = 0;
2891 /* ?_Stinit@?1??_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
2892 /* ?_Stinit@?1??_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
2893 int basic_filebuf_short__Init__Stinit = 0;
2895 /* ?_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
2896 /* ?_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
2897 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Init, 12)
2898 void __thiscall basic_filebuf_wchar__Init(basic_filebuf_wchar *this, FILE *file, basic_filebuf__Initfl which)
2900 TRACE("(%p %p %d)\n", this, file, which);
2903 this->wrotesome = FALSE;
2904 this->state = basic_filebuf_wchar__Init__Stinit;
2905 this->close = (which == INITFL_open);
2908 basic_streambuf_wchar__Init_empty(&this->base);
2911 /* ?_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
2912 /* ?_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
2913 DEFINE_THISCALL_WRAPPER(basic_filebuf_short__Init, 12)
2914 void __thiscall basic_filebuf_short__Init(basic_filebuf_wchar *this, FILE *file, basic_filebuf__Initfl which)
2916 TRACE("(%p %p %d)\n", this, file, which);
2919 this->wrotesome = FALSE;
2920 this->state = basic_filebuf_short__Init__Stinit;
2921 this->close = (which == INITFL_open);
2924 basic_streambuf_wchar__Init_empty(&this->base);
2927 /* ?_Initcvt@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$codecvt@_WDH@2@@Z */
2928 /* ?_Initcvt@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$codecvt@_WDH@2@@Z */
2929 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAV?$codecvt@GDH@2@@Z */
2930 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$codecvt@GDH@2@@Z */
2931 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Initcvt, 8)
2932 void __thiscall basic_filebuf_wchar__Initcvt(basic_filebuf_wchar *this, codecvt_wchar *cvt)
2934 TRACE("(%p %p)\n", this, cvt);
2936 if(codecvt_base_always_noconv(&cvt->base)) {
2939 basic_streambuf_wchar__Init_empty(&this->base);
2944 /* ?_Endwrite@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAE_NXZ */
2945 /* ?_Endwrite@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAA_NXZ */
2946 /* ?_Endwrite@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAE_NXZ */
2947 /* ?_Endwrite@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAA_NXZ */
2948 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Endwrite, 4)
2949 MSVCP_bool __thiscall basic_filebuf_wchar__Endwrite(basic_filebuf_wchar *this)
2951 TRACE("(%p)\n", this);
2953 if(!this->wrotesome || !this->cvt)
2956 if(call_basic_streambuf_wchar_overflow(&this->base, WEOF) == WEOF)
2960 /* TODO: check if we need a dynamic buffer here */
2965 ret = codecvt_wchar_unshift(this->cvt, &this->state, buf, buf+sizeof(buf), &next);
2968 this->wrotesome = FALSE;
2970 case CODECVT_partial:
2971 if(!fwrite(buf, next-buf, 1, this->file))
2976 case CODECVT_noconv:
2977 if(call_basic_streambuf_wchar_overflow(&this->base, WEOF) == WEOF)
2986 /* ?close@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@XZ */
2987 /* ?close@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@XZ */
2988 /* ?close@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@XZ */
2989 /* ?close@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@XZ */
2990 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_close, 4)
2991 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_close(basic_filebuf_wchar *this)
2993 basic_filebuf_wchar *ret = this;
2995 TRACE("(%p)\n", this);
3000 /* TODO: handle exceptions */
3001 if(!basic_filebuf_wchar__Endwrite(this))
3003 if(fclose(this->file))
3006 basic_filebuf_wchar__Init(this, NULL, INITFL_close);
3010 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
3011 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3012 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor_file, 8)
3013 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_ctor_file(basic_filebuf_wchar *this, FILE *file)
3015 TRACE("(%p %p)\n", this, file);
3017 basic_streambuf_wchar_ctor(&this->base);
3018 this->base.vtable = &MSVCP_basic_filebuf_wchar_vtable;
3020 basic_filebuf_wchar__Init(this, file, INITFL_new);
3024 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
3025 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3026 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor_file, 8)
3027 basic_filebuf_wchar* __thiscall basic_filebuf_short_ctor_file(basic_filebuf_wchar *this, FILE *file)
3029 TRACE("(%p %p)\n", this, file);
3031 basic_streambuf_short_ctor(&this->base);
3032 this->base.vtable = &MSVCP_basic_filebuf_short_vtable;
3034 basic_filebuf_short__Init(this, file, INITFL_new);
3038 /* ??_F?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
3039 /* ??_F?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
3040 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor, 4)
3041 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_ctor(basic_filebuf_wchar *this)
3043 return basic_filebuf_wchar_ctor_file(this, NULL);
3046 /* ??_F?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
3047 /* ??_F?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
3048 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor, 4)
3049 basic_filebuf_wchar* __thiscall basic_filebuf_short_ctor(basic_filebuf_wchar *this)
3051 return basic_filebuf_short_ctor_file(this, NULL);
3054 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3055 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3056 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor_uninitialized, 8)
3057 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_ctor_uninitialized(basic_filebuf_wchar *this, int uninitialized)
3059 TRACE("(%p %d)\n", this, uninitialized);
3061 basic_streambuf_wchar_ctor(&this->base);
3062 this->base.vtable = &MSVCP_basic_filebuf_wchar_vtable;
3066 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3067 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3068 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor_uninitialized, 8)
3069 basic_filebuf_wchar* __thiscall basic_filebuf_short_ctor_uninitialized(basic_filebuf_wchar *this, int uninitialized)
3071 TRACE("(%p %d)\n", this, uninitialized);
3073 basic_streambuf_short_ctor(&this->base);
3074 this->base.vtable = &MSVCP_basic_filebuf_short_vtable;
3078 /* ??1?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
3079 /* ??1?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
3080 /* ??1?$basic_filebuf@GU?$char_traits@G@std@@@std@@UAE@XZ */
3081 /* ??1?$basic_filebuf@GU?$char_traits@G@std@@@std@@UEAA@XZ */
3082 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_dtor, 4)
3083 void __thiscall basic_filebuf_wchar_dtor(basic_filebuf_wchar *this)
3085 TRACE("(%p)\n", this);
3088 basic_filebuf_wchar_close(this);
3089 basic_streambuf_wchar_dtor(&this->base);
3092 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_vector_dtor, 8)
3093 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_vector_dtor(basic_filebuf_wchar *this, unsigned int flags)
3095 TRACE("(%p %x)\n", this, flags);
3097 /* we have an array, with the number of elements stored before the first object */
3098 INT_PTR i, *ptr = (INT_PTR *)this-1;
3100 for(i=*ptr-1; i>=0; i--)
3101 basic_filebuf_wchar_dtor(this+i);
3102 MSVCRT_operator_delete(ptr);
3104 basic_filebuf_wchar_dtor(this);
3106 MSVCRT_operator_delete(this);
3112 /* ?is_open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
3113 /* ?is_open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
3114 /* ?is_open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QBE_NXZ */
3115 /* ?is_open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
3116 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_is_open, 4)
3117 MSVCP_bool __thiscall basic_filebuf_wchar_is_open(const basic_filebuf_wchar *this)
3119 TRACE("(%p)\n", this);
3120 return this->file != NULL;
3123 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PB_WHH@Z */
3124 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3125 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBGHH@Z */
3126 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3127 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_wchar, 16)
3128 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_open_wchar(basic_filebuf_wchar *this, const wchar_t *name, int mode, int prot)
3132 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
3134 if(basic_filebuf_wchar_is_open(this))
3137 if(!(f = _Fiopen_wchar(name, mode, prot)))
3140 basic_filebuf_wchar__Init(this, f, INITFL_open);
3141 basic_filebuf_wchar__Initcvt(this, codecvt_wchar_use_facet(this->base.loc));
3145 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PB_WHH@Z */
3146 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3147 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBGHH@Z */
3148 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3149 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_wchar, 16)
3150 basic_filebuf_wchar* __thiscall basic_filebuf_short_open_wchar(basic_filebuf_wchar *this, const wchar_t *name, int mode, int prot)
3154 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
3156 if(basic_filebuf_wchar_is_open(this))
3159 if(!(f = _Fiopen_wchar(name, mode, prot)))
3162 basic_filebuf_short__Init(this, f, INITFL_open);
3163 basic_filebuf_wchar__Initcvt(this, codecvt_short_use_facet(this->base.loc));
3167 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PB_WI@Z */
3168 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3169 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBGI@Z */
3170 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBGI@Z */
3171 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_wchar_mode, 12)
3172 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_open_wchar_mode(basic_filebuf_wchar *this, const wchar_t *name, unsigned int mode)
3174 return basic_filebuf_wchar_open_wchar(this, name, mode, SH_DENYNO);
3177 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PB_WI@Z */
3178 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3179 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBGI@Z */
3180 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBGI@Z */
3181 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_wchar_mode, 12)
3182 basic_filebuf_wchar* __thiscall basic_filebuf_short_open_wchar_mode(basic_filebuf_wchar *this, const wchar_t *name, unsigned int mode)
3184 return basic_filebuf_short_open_wchar(this, name, mode, SH_DENYNO);
3187 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBDHH@Z */
3188 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3189 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open, 16)
3190 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_open(basic_filebuf_wchar *this, const char *name, int mode, int prot)
3192 wchar_t nameW[FILENAME_MAX];
3194 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
3196 if(mbstowcs_s(NULL, nameW, FILENAME_MAX, name, FILENAME_MAX-1) != 0)
3198 return basic_filebuf_wchar_open_wchar(this, nameW, mode, prot);
3201 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDHH@Z */
3202 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3203 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open, 16)
3204 basic_filebuf_wchar* __thiscall basic_filebuf_short_open(basic_filebuf_wchar *this, const char *name, int mode, int prot)
3206 wchar_t nameW[FILENAME_MAX];
3208 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
3210 if(mbstowcs_s(NULL, nameW, FILENAME_MAX, name, FILENAME_MAX-1) != 0)
3212 return basic_filebuf_short_open_wchar(this, nameW, mode, prot);
3215 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBDI@Z */
3216 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBDI@Z */
3217 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_mode, 12)
3218 basic_filebuf_wchar* __thiscall basic_filebuf_wchar_open_mode(basic_filebuf_wchar *this, const char *name, unsigned int mode)
3220 return basic_filebuf_wchar_open(this, name, mode, SH_DENYNO);
3223 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDI@Z */
3224 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDI@Z */
3225 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_mode, 12)
3226 basic_filebuf_wchar* __thiscall basic_filebuf_short_open_mode(basic_filebuf_wchar *this, const char *name, unsigned int mode)
3228 return basic_filebuf_short_open(this, name, mode, SH_DENYNO);
3231 /* ?overflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
3232 /* ?overflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
3233 /* ?overflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
3234 /* ?overflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
3235 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_overflow, 8)
3236 unsigned short __thiscall basic_filebuf_wchar_overflow(basic_filebuf_wchar *this, unsigned short c)
3238 char buf[8], *dyn_buf, *to_next;
3240 const wchar_t *from_next;
3245 TRACE("(%p %d)\n", this, c);
3247 if(!basic_filebuf_wchar_is_open(this))
3253 return fwrite(&ch, sizeof(wchar_t), 1, this->file) ? c : WEOF;
3257 ret = codecvt_wchar_out(this->cvt, &this->state, from_next, &ch+1,
3258 &from_next, buf, buf+sizeof(buf), &to_next);
3261 case CODECVT_partial:
3266 if(!fwrite(buf, to_next-buf, 1, this->file))
3268 if(ret == CODECVT_partial)
3271 case CODECVT_noconv:
3272 return fwrite(&ch, sizeof(wchar_t), 1, this->file) ? c : WEOF;
3280 max_size = codecvt_base_max_length(&this->cvt->base);
3281 dyn_buf = malloc(max_size);
3285 ret = codecvt_wchar_out(this->cvt, &this->state, from_next, &ch+1,
3286 &from_next, dyn_buf, dyn_buf+max_size, &to_next);
3290 ret = fwrite(dyn_buf, to_next-dyn_buf, 1, this->file);
3292 return ret ? c : WEOF;
3293 case CODECVT_partial:
3294 ERR("buffer should be big enough to store all output\n");
3302 /* ?pbackfail@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
3303 /* ?pbackfail@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
3304 /* ?pbackfail@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
3305 /* ?pbackfail@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
3306 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_pbackfail, 8)
3307 unsigned short __thiscall basic_filebuf_wchar_pbackfail(basic_filebuf_wchar *this, unsigned short c)
3309 TRACE("(%p %d)\n", this, c);
3311 if(!basic_filebuf_wchar_is_open(this))
3314 if(basic_streambuf_wchar_gptr(&this->base)>basic_streambuf_wchar_eback(&this->base)
3315 && (c==WEOF || basic_streambuf_wchar_gptr(&this->base)[-1]==(wchar_t)c)) {
3316 basic_streambuf_wchar__Gndec(&this->base);
3317 return c==WEOF ? !c : c;
3318 }else if(c!=WEOF && !this->cvt) {
3319 return ungetwc(c, this->file);
3320 }else if(c!=WEOF && basic_streambuf_wchar_gptr(&this->base)!=&this->putback) {
3322 basic_streambuf_wchar_setg(&this->base, &this->putback, &this->putback, &this->putback+1);
3329 /* ?uflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
3330 /* ?uflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
3331 /* ?uflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
3332 /* ?uflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
3333 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_uflow, 4)
3334 unsigned short __thiscall basic_filebuf_wchar_uflow(basic_filebuf_wchar *this)
3336 wchar_t ch, *to_next;
3338 const char *buf_next;
3341 TRACE("(%p)\n", this);
3343 if(!basic_filebuf_wchar_is_open(this))
3346 if(basic_streambuf_wchar_gptr(&this->base) < basic_streambuf_wchar_egptr(&this->base))
3347 return *basic_streambuf_wchar__Gninc(&this->base);
3350 return fgetwc(this->file);
3353 for(i=0; i < sizeof(buf)/sizeof(buf[0]); i++) {
3354 if((c = fgetc(this->file)) == EOF)
3358 switch(codecvt_wchar_in(this->cvt, &this->state, buf_next,
3359 buf+i+1, &buf_next, &ch, &ch+1, &to_next)) {
3360 case CODECVT_partial:
3365 for(i--; i>=buf_next-buf; i--)
3366 ungetc(buf[i], this->file);
3368 case CODECVT_noconv:
3369 if(i+1 < sizeof(wchar_t))
3372 memcpy(&ch, buf, sizeof(wchar_t));
3379 FIXME("buffer is too small\n");
3383 /* ?underflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
3384 /* ?underflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
3385 /* ?underflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
3386 /* ?underflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
3387 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_underflow, 4)
3388 unsigned short __thiscall basic_filebuf_wchar_underflow(basic_filebuf_wchar *this)
3392 TRACE("(%p)\n", this);
3394 if(basic_streambuf_wchar_gptr(&this->base) < basic_streambuf_wchar_egptr(&this->base))
3395 return *basic_streambuf_wchar_gptr(&this->base);
3397 ret = call_basic_streambuf_wchar_uflow(&this->base);
3399 ret = call_basic_streambuf_wchar_pbackfail(&this->base, ret);
3403 /* ?seekoff@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3404 /* ?seekoff@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3405 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3406 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3407 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekoff, 20)
3408 fpos_int* __thiscall basic_filebuf_wchar_seekoff(basic_filebuf_wchar *this,
3409 fpos_int *ret, streamoff off, int way, int mode)
3413 TRACE("(%p %p %ld %d %d)\n", this, ret, off, way, mode);
3415 if(basic_streambuf_wchar_gptr(&this->base) == &this->putback) {
3416 if(way == SEEKDIR_cur)
3417 off -= sizeof(wchar_t);
3419 basic_streambuf_wchar_setg(&this->base, &this->putback, &this->putback+1, &this->putback+1);
3422 if(!basic_filebuf_wchar_is_open(this) || !basic_filebuf_wchar__Endwrite(this)
3423 || fseek(this->file, off, way)) {
3430 fgetpos(this->file, &pos);
3433 ret->state = this->state;
3437 /* ?seekpos@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3438 /* ?seekpos@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3439 /* ?seekpos@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3440 /* ?seekpos@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3441 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekpos, 36)
3442 fpos_int* __thiscall basic_filebuf_wchar_seekpos(basic_filebuf_wchar *this,
3443 fpos_int *ret, fpos_int pos, int mode)
3447 TRACE("(%p %p %s %d)\n", this, ret, debugstr_fpos_int(&pos), mode);
3449 if(!basic_filebuf_wchar_is_open(this) || !basic_filebuf_wchar__Endwrite(this)
3450 || fseek(this->file, (LONG)pos.pos, SEEK_SET)
3451 || (pos.off && fseek(this->file, pos.off, SEEK_CUR))) {
3458 if(basic_streambuf_wchar_gptr(&this->base) == &this->putback)
3459 basic_streambuf_wchar_setg(&this->base, &this->putback, &this->putback+1, &this->putback+1);
3461 fgetpos(this->file, &fpos);
3464 ret->state = this->state;
3468 /* ?setbuf@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PA_WH@Z */
3469 /* ?setbuf@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEA_W_J@Z */
3470 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_setbuf, 12)
3471 basic_streambuf_wchar* __thiscall basic_filebuf_wchar_setbuf(basic_filebuf_wchar *this, wchar_t *buf, streamsize count)
3473 TRACE("(%p %p %ld)\n", this, buf, count);
3475 if(!basic_filebuf_wchar_is_open(this))
3478 if(setvbuf(this->file, (char*)buf, (buf==NULL && count==0) ? _IONBF : _IOFBF, count*sizeof(wchar_t)))
3481 basic_filebuf_wchar__Init(this, this->file, INITFL_open);
3485 /* ?setbuf@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAGH@Z */
3486 /* ?setbuf@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAG_J@Z */
3487 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_setbuf, 12)
3488 basic_streambuf_wchar* __thiscall basic_filebuf_short_setbuf(basic_filebuf_wchar *this, wchar_t *buf, streamsize count)
3490 TRACE("(%p %p %ld)\n", this, buf, count);
3492 if(!basic_filebuf_wchar_is_open(this))
3495 if(setvbuf(this->file, (char*)buf, (buf==NULL && count==0) ? _IONBF : _IOFBF, count*sizeof(wchar_t)))
3498 basic_filebuf_short__Init(this, this->file, INITFL_open);
3502 /* ?sync@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
3503 /* ?sync@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ */
3504 /* ?sync@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
3505 /* ?sync@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAHXZ */
3506 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_sync, 4)
3507 int __thiscall basic_filebuf_wchar_sync(basic_filebuf_wchar *this)
3509 TRACE("(%p)\n", this);
3511 if(!basic_filebuf_wchar_is_open(this))
3514 if(call_basic_streambuf_wchar_overflow(&this->base, WEOF) == WEOF)
3516 return fflush(this->file);
3519 /* ?imbue@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z */
3520 /* ?imbue@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z */
3521 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_imbue, 8)
3522 void __thiscall basic_filebuf_wchar_imbue(basic_filebuf_wchar *this, const locale *loc)
3524 TRACE("(%p %p)\n", this, loc);
3525 basic_filebuf_wchar__Initcvt(this, codecvt_wchar_use_facet(loc));
3528 /* ?imbue@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z */
3529 /* ?imbue@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z */
3530 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_imbue, 8)
3531 void __thiscall basic_filebuf_short_imbue(basic_filebuf_wchar *this, const locale *loc)
3533 TRACE("(%p %p)\n", this, loc);
3534 basic_filebuf_wchar__Initcvt(this, codecvt_short_use_facet(loc));
3537 /* ?_Getstate@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AAEHH@Z */
3538 /* ?_Getstate@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEAAHH@Z */
3539 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Getstate, 8)
3540 int __thiscall basic_stringbuf_char__Getstate(basic_stringbuf_char *this, IOSB_openmode mode)
3544 if(!(mode & OPENMODE_in))
3545 state |= STRINGBUF_no_read;
3547 if(!(mode & OPENMODE_out))
3548 state |= STRINGBUF_no_write;
3550 if(mode & OPENMODE_ate)
3551 state |= STRINGBUF_at_end;
3553 if(mode & OPENMODE_app)
3554 state |= STRINGBUF_append;
3559 /* ?_Init@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEXPBDIH@Z */
3560 /* ?_Init@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IEAAXPEBD_KH@Z */
3561 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Init, 16)
3562 void __thiscall basic_stringbuf_char__Init(basic_stringbuf_char *this, const char *str, MSVCP_size_t count, int state)
3564 TRACE("(%p, %p, %ld, %d)\n", this, str, count, state);
3566 basic_streambuf_char__Init_empty(&this->base);
3568 this->state = state;
3569 this->seekhigh = NULL;
3572 char *buf = MSVCRT_operator_new(count);
3574 ERR("Out of memory\n");
3575 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
3578 memcpy(buf, str, count);
3579 this->seekhigh = buf + count;
3581 this->state |= STRINGBUF_allocated;
3583 if(!(state & STRINGBUF_no_read))
3584 basic_streambuf_char_setg(&this->base, buf, buf, buf + count);
3586 if(!(state & STRINGBUF_no_write)) {
3587 basic_streambuf_char_setp_next(&this->base, buf, (state & STRINGBUF_at_end) ? buf + count : buf, buf + count);
3589 if(!basic_streambuf_char_gptr(&this->base))
3590 basic_streambuf_char_setg(&this->base, buf, 0, buf);
3595 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
3596 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
3597 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor_str, 12)
3598 basic_stringbuf_char* __thiscall basic_stringbuf_char_ctor_str(basic_stringbuf_char *this,
3599 const basic_string_char *str, IOSB_openmode mode)
3601 TRACE("(%p %p %d)\n", this, str, mode);
3603 basic_streambuf_char_ctor(&this->base);
3604 this->base.vtable = &MSVCP_basic_stringbuf_char_vtable;
3606 basic_stringbuf_char__Init(this, MSVCP_basic_string_char_c_str(str),
3607 str->size, basic_stringbuf_char__Getstate(this, mode));
3611 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
3612 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
3613 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor_mode, 8)
3614 basic_stringbuf_char* __thiscall basic_stringbuf_char_ctor_mode(
3615 basic_stringbuf_char *this, IOSB_openmode mode)
3617 TRACE("(%p %d)\n", this, mode);
3619 basic_streambuf_char_ctor(&this->base);
3620 this->base.vtable = &MSVCP_basic_stringbuf_char_vtable;
3622 basic_stringbuf_char__Init(this, NULL, 0, basic_stringbuf_char__Getstate(this, mode));
3626 /* ??_F?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
3627 /* ??_F?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
3628 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor, 4)
3629 basic_stringbuf_char* __thiscall basic_stringbuf_char_ctor(basic_stringbuf_char *this)
3631 return basic_stringbuf_char_ctor_mode(this, OPENMODE_in|OPENMODE_out);
3634 /* ?_Tidy@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEXXZ */
3635 /* ?_Tidy@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IEAAXXZ */
3636 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Tidy, 4)
3637 void __thiscall basic_stringbuf_char__Tidy(basic_stringbuf_char *this)
3639 TRACE("(%p)\n", this);
3641 if(this->state & STRINGBUF_allocated) {
3642 MSVCRT_operator_delete(basic_streambuf_char_eback(&this->base));
3643 this->seekhigh = NULL;
3644 this->state &= ~STRINGBUF_allocated;
3647 basic_streambuf_char__Init_empty(&this->base);
3650 /* ??1?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
3651 /* ??1?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
3652 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_dtor, 4)
3653 void __thiscall basic_stringbuf_char_dtor(basic_stringbuf_char *this)
3655 TRACE("(%p)\n", this);
3657 basic_stringbuf_char__Tidy(this);
3658 basic_streambuf_char_dtor(&this->base);
3661 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_vector_dtor, 8)
3662 basic_stringbuf_char* __thiscall basic_stringbuf_char_vector_dtor(basic_stringbuf_char *this, unsigned int flags)
3664 TRACE("(%p %x)\n", this, flags);
3667 /* we have an array, with the number of elements stored before the first object */
3668 INT_PTR i, *ptr = (INT_PTR *) this - 1;
3670 for (i = *ptr - 1; i >= 0; i--)
3671 basic_stringbuf_char_dtor(this+i);
3673 MSVCRT_operator_delete(ptr);
3675 basic_stringbuf_char_dtor(this);
3678 MSVCRT_operator_delete(this);
3684 /* ?overflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHH@Z */
3685 /* ?overflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z */
3686 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_overflow, 8)
3687 int __thiscall basic_stringbuf_char_overflow(basic_stringbuf_char *this, int meta)
3689 MSVCP_size_t oldsize, size;
3692 TRACE("(%p %x)\n", this, meta);
3696 if(this->state & STRINGBUF_no_write)
3699 ptr = basic_streambuf_char_pptr(&this->base);
3700 if((this->state&STRINGBUF_append) && ptr<this->seekhigh)
3701 basic_streambuf_char_setp_next(&this->base, basic_streambuf_char_pbase(&this->base),
3702 this->seekhigh, basic_streambuf_char_epptr(&this->base));
3704 if(ptr && ptr<basic_streambuf_char_epptr(&this->base))
3705 return (*basic_streambuf_char__Pninc(&this->base) = meta);
3707 oldsize = (ptr ? basic_streambuf_char_epptr(&this->base)-basic_streambuf_char_eback(&this->base): 0);
3710 buf = MSVCRT_operator_new(size);
3712 ERR("Out of memory\n");
3713 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
3717 this->seekhigh = buf;
3718 basic_streambuf_char_setp(&this->base, buf, buf+size);
3719 if(this->state & STRINGBUF_no_read)
3720 basic_streambuf_char_setg(&this->base, buf, NULL, buf);
3722 basic_streambuf_char_setg(&this->base, buf, buf, buf+1);
3724 this->state |= STRINGBUF_allocated;
3726 ptr = basic_streambuf_char_eback(&this->base);
3727 memcpy(buf, ptr, oldsize);
3729 this->seekhigh = buf+(this->seekhigh-ptr);
3730 basic_streambuf_char_setp_next(&this->base, buf,
3731 buf+(basic_streambuf_char_pptr(&this->base)-ptr), buf+size);
3732 if(this->state & STRINGBUF_no_read)
3733 basic_streambuf_char_setg(&this->base, buf, NULL, buf);
3735 basic_streambuf_char_setg(&this->base, buf,
3736 buf+(basic_streambuf_char_gptr(&this->base)-ptr),
3737 basic_streambuf_char_pptr(&this->base)+1);
3739 MSVCRT_operator_delete(ptr);
3742 return (*basic_streambuf_char__Pninc(&this->base) = meta);
3745 /* ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHH@Z */
3746 /* ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z */
3747 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_pbackfail, 8)
3748 int __thiscall basic_stringbuf_char_pbackfail(basic_stringbuf_char *this, int c)
3752 TRACE("(%p %x)\n", this, c);
3754 cur = basic_streambuf_char_gptr(&this->base);
3755 if(!cur || cur==basic_streambuf_char_eback(&this->base)
3756 || (c!=EOF && c!=cur[-1] && this->state&STRINGBUF_no_write))
3761 basic_streambuf_char_gbump(&this->base, -1);
3762 return c==EOF ? !EOF : c;
3765 /* ?underflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHXZ */
3766 /* ?underflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHXZ */
3767 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_underflow, 4)
3768 int __thiscall basic_stringbuf_char_underflow(basic_stringbuf_char *this)
3772 TRACE("(%p)\n", this);
3774 cur = basic_streambuf_char_gptr(&this->base);
3775 if(!cur || this->state&STRINGBUF_no_read)
3778 ptr = basic_streambuf_char_pptr(&this->base);
3779 if(this->seekhigh < ptr)
3780 this->seekhigh = ptr;
3782 ptr = basic_streambuf_char_egptr(&this->base);
3783 if(this->seekhigh > ptr)
3784 basic_streambuf_char_setg(&this->base, basic_streambuf_char_eback(&this->base), cur, this->seekhigh);
3786 if(cur < this->seekhigh)
3791 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3792 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3793 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekoff, 20)
3794 fpos_int* __thiscall basic_stringbuf_char_seekoff(basic_stringbuf_char *this,
3795 fpos_int *ret, streamoff off, int way, int mode)
3797 char *beg, *cur_r, *cur_w;
3799 TRACE("(%p %p %ld %d %d)\n", this, ret, off, way, mode);
3801 cur_w = basic_streambuf_char_pptr(&this->base);
3802 if(cur_w > this->seekhigh)
3803 this->seekhigh = cur_w;
3808 beg = basic_streambuf_char_eback(&this->base);
3809 cur_r = basic_streambuf_char_gptr(&this->base);
3810 if((mode & OPENMODE_in) && cur_r) {
3811 if(way==SEEKDIR_cur && !(mode & OPENMODE_out))
3813 else if(way == SEEKDIR_end)
3814 off += this->seekhigh-beg;
3815 else if(way != SEEKDIR_beg)
3818 if(off<0 || off>this->seekhigh-beg) {
3821 basic_streambuf_char_gbump(&this->base, beg-cur_r+off);
3822 if((mode & OPENMODE_out) && cur_w) {
3823 basic_streambuf_char_setp_next(&this->base, beg,
3824 basic_streambuf_char_gptr(&this->base),
3825 basic_streambuf_char_epptr(&this->base));
3828 }else if((mode & OPENMODE_out) && cur_w) {
3829 if(way == SEEKDIR_cur)
3831 else if(way == SEEKDIR_end)
3832 off += this->seekhigh-beg;
3833 else if(way != SEEKDIR_beg)
3836 if(off<0 || off>this->seekhigh-beg)
3839 basic_streambuf_char_pbump(&this->base, beg-cur_w+off);
3848 /* ?seekpos@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3849 /* ?seekpos@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3850 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekpos, 36)
3851 fpos_int* __thiscall basic_stringbuf_char_seekpos(basic_stringbuf_char *this,
3852 fpos_int *ret, fpos_int pos, int mode)
3854 TRACE("(%p %p %s %d)\n", this, ret, debugstr_fpos_int(&pos), mode);
3856 if(pos.off==0 && pos.pos==-1 && pos.state==0) {
3861 return basic_stringbuf_char_seekoff(this, ret, pos.off, SEEKDIR_beg, mode);
3864 /* ?str@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
3865 /* ?str@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
3866 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_str_set, 8)
3867 void __thiscall basic_stringbuf_char_str_set(basic_stringbuf_char *this, const basic_string_char *str)
3869 TRACE("(%p %p)\n", this, str);
3871 basic_stringbuf_char__Tidy(this);
3872 basic_stringbuf_char__Init(this, MSVCP_basic_string_char_c_str(str), str->size, this->state);
3875 /* ?str@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3876 /* ?str@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3877 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_str_get, 8)
3878 basic_string_char* __thiscall basic_stringbuf_char_str_get(const basic_stringbuf_char *this, basic_string_char *ret)
3882 TRACE("(%p)\n", this);
3884 if(!(this->state & STRINGBUF_no_write) && basic_streambuf_char_pptr(&this->base)) {
3887 ptr = basic_streambuf_char_pbase(&this->base);
3888 pptr = basic_streambuf_char_pptr(&this->base);
3890 return MSVCP_basic_string_char_ctor_cstr_len(ret, ptr, (this->seekhigh < pptr ? pptr : this->seekhigh) - ptr);
3893 if(!(this->state & STRINGBUF_no_read) && basic_streambuf_char_gptr(&this->base)) {
3894 ptr = basic_streambuf_char_eback(&this->base);
3895 return MSVCP_basic_string_char_ctor_cstr_len(ret, ptr, basic_streambuf_char_egptr(&this->base) - ptr);
3898 return MSVCP_basic_string_char_ctor(ret);
3901 /* ?_Getstate@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@AAEHH@Z */
3902 /* ?_Getstate@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@AEAAHH@Z */
3903 /* ?_Getstate@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AAEHH@Z */
3904 /* ?_Getstate@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AEAAHH@Z */
3905 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Getstate, 8)
3906 int __thiscall basic_stringbuf_wchar__Getstate(basic_stringbuf_wchar *this, IOSB_openmode mode)
3910 if(!(mode & OPENMODE_in))
3911 state |= STRINGBUF_no_read;
3913 if(!(mode & OPENMODE_out))
3914 state |= STRINGBUF_no_write;
3916 if(mode & OPENMODE_ate)
3917 state |= STRINGBUF_at_end;
3919 if(mode & OPENMODE_app)
3920 state |= STRINGBUF_append;
3925 /* ?_Init@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEXPB_WIH@Z */
3926 /* ?_Init@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IEAAXPEB_W_KH@Z */
3927 /* ?_Init@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IAEXPBGIH@Z */
3928 /* ?_Init@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IEAAXPEBG_KH@Z */
3929 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Init, 16)
3930 void __thiscall basic_stringbuf_wchar__Init(basic_stringbuf_wchar *this, const wchar_t *str, MSVCP_size_t count, int state)
3932 TRACE("(%p, %p, %lu, %d)\n", this, str, count, state);
3934 basic_streambuf_wchar__Init_empty(&this->base);
3936 this->state = state;
3937 this->seekhigh = NULL;
3940 wchar_t *buf = MSVCRT_operator_new(count*sizeof(wchar_t));
3942 ERR("Out of memory\n");
3943 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
3946 memcpy(buf, str, count*sizeof(wchar_t));
3947 this->seekhigh = buf + count;
3949 this->state |= STRINGBUF_allocated;
3951 if(!(state & STRINGBUF_no_read))
3952 basic_streambuf_wchar_setg(&this->base, buf, buf, buf + count);
3954 if(!(state & STRINGBUF_no_write)) {
3955 basic_streambuf_wchar_setp_next(&this->base, buf, (state & STRINGBUF_at_end) ? buf + count : buf, buf + count);
3957 if(!basic_streambuf_wchar_gptr(&this->base))
3958 basic_streambuf_wchar_setg(&this->base, buf, 0, buf);
3963 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
3964 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@AEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
3965 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor_str, 12)
3966 basic_stringbuf_wchar* __thiscall basic_stringbuf_wchar_ctor_str(basic_stringbuf_wchar *this,
3967 const basic_string_wchar *str, IOSB_openmode mode)
3969 TRACE("(%p %p %d)\n", this, str, mode);
3971 basic_streambuf_wchar_ctor(&this->base);
3972 this->base.vtable = &MSVCP_basic_stringbuf_wchar_vtable;
3974 basic_stringbuf_wchar__Init(this, MSVCP_basic_string_wchar_c_str(str),
3975 str->size, basic_stringbuf_wchar__Getstate(this, mode));
3979 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
3980 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
3981 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor_str, 12)
3982 basic_stringbuf_wchar* __thiscall basic_stringbuf_short_ctor_str(basic_stringbuf_wchar *this,
3983 const basic_string_wchar *str, IOSB_openmode mode)
3985 basic_stringbuf_wchar_ctor_str(this, str, mode);
3986 this->base.vtable = &MSVCP_basic_stringbuf_short_vtable;
3990 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
3991 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
3992 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor_mode, 8)
3993 basic_stringbuf_wchar* __thiscall basic_stringbuf_wchar_ctor_mode(
3994 basic_stringbuf_wchar *this, IOSB_openmode mode)
3996 TRACE("(%p %d)\n", this, mode);
3998 basic_streambuf_wchar_ctor(&this->base);
3999 this->base.vtable = &MSVCP_basic_stringbuf_wchar_vtable;
4001 basic_stringbuf_wchar__Init(this, NULL, 0, basic_stringbuf_wchar__Getstate(this, mode));
4005 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
4006 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
4007 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor_mode, 8)
4008 basic_stringbuf_wchar* __thiscall basic_stringbuf_short_ctor_mode(
4009 basic_stringbuf_wchar *this, IOSB_openmode mode)
4011 basic_stringbuf_wchar_ctor_mode(this, mode);
4012 this->base.vtable = &MSVCP_basic_stringbuf_short_vtable;
4016 /* ??_F?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
4017 /* ??_F?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
4018 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor, 4)
4019 basic_stringbuf_wchar* __thiscall basic_stringbuf_wchar_ctor(basic_stringbuf_wchar *this)
4021 return basic_stringbuf_wchar_ctor_mode(this, OPENMODE_in|OPENMODE_out);
4024 /* ??_F?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
4025 /* ??_F?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
4026 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor, 4)
4027 basic_stringbuf_wchar* __thiscall basic_stringbuf_short_ctor(basic_stringbuf_wchar *this)
4029 return basic_stringbuf_short_ctor_mode(this, OPENMODE_in|OPENMODE_out);
4032 /* ?_Tidy@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEXXZ */
4033 /* ?_Tidy@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IEAAXXZ */
4034 /* ?_Tidy@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IAEXXZ */
4035 /* ?_Tidy@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IEAAXXZ */
4036 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Tidy, 4)
4037 void __thiscall basic_stringbuf_wchar__Tidy(basic_stringbuf_wchar *this)
4039 TRACE("(%p)\n", this);
4041 if(this->state & STRINGBUF_allocated) {
4042 MSVCRT_operator_delete(basic_streambuf_wchar_eback(&this->base));
4043 this->seekhigh = NULL;
4044 this->state &= ~STRINGBUF_allocated;
4047 basic_streambuf_wchar__Init_empty(&this->base);
4050 /* ??1?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
4051 /* ??1?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
4052 /* ??1?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
4053 /* ??1?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
4054 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_dtor, 4)
4055 void __thiscall basic_stringbuf_wchar_dtor(basic_stringbuf_wchar *this)
4057 TRACE("(%p)\n", this);
4059 basic_stringbuf_wchar__Tidy(this);
4060 basic_streambuf_wchar_dtor(&this->base);
4063 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_vector_dtor, 8)
4064 basic_stringbuf_wchar* __thiscall basic_stringbuf_wchar_vector_dtor(basic_stringbuf_wchar *this, unsigned int flags)
4066 TRACE("(%p %x)\n", this, flags);
4069 /* we have an array, with the number of elements stored before the first object */
4070 INT_PTR i, *ptr = (INT_PTR *) this - 1;
4072 for (i = *ptr - 1; i >= 0; i--)
4073 basic_stringbuf_wchar_dtor(this+i);
4075 MSVCRT_operator_delete(ptr);
4077 basic_stringbuf_wchar_dtor(this);
4080 MSVCRT_operator_delete(this);
4086 /* ?overflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGG@Z */
4087 /* ?overflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGG@Z */
4088 /* ?overflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGG@Z */
4089 /* ?overflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGG@Z */
4090 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_overflow, 8)
4091 unsigned short __thiscall basic_stringbuf_wchar_overflow(basic_stringbuf_wchar *this, unsigned short meta)
4093 MSVCP_size_t oldsize, size;
4096 TRACE("(%p %x)\n", this, meta);
4100 if(this->state & STRINGBUF_no_write)
4103 ptr = basic_streambuf_wchar_pptr(&this->base);
4104 if((this->state&STRINGBUF_append) && ptr<this->seekhigh)
4105 basic_streambuf_wchar_setp_next(&this->base, basic_streambuf_wchar_pbase(&this->base),
4106 this->seekhigh, basic_streambuf_wchar_epptr(&this->base));
4108 if(ptr && ptr<basic_streambuf_wchar_epptr(&this->base))
4109 return (*basic_streambuf_wchar__Pninc(&this->base) = meta);
4111 oldsize = (ptr ? basic_streambuf_wchar_epptr(&this->base)-basic_streambuf_wchar_eback(&this->base): 0);
4114 buf = MSVCRT_operator_new(size*sizeof(wchar_t));
4116 ERR("Out of memory\n");
4117 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
4121 this->seekhigh = buf;
4122 basic_streambuf_wchar_setp(&this->base, buf, buf+size);
4123 if(this->state & STRINGBUF_no_read)
4124 basic_streambuf_wchar_setg(&this->base, buf, NULL, buf);
4126 basic_streambuf_wchar_setg(&this->base, buf, buf, buf+1);
4128 this->state |= STRINGBUF_allocated;
4130 ptr = basic_streambuf_wchar_eback(&this->base);
4131 memcpy(buf, ptr, oldsize*sizeof(wchar_t));
4133 this->seekhigh = buf+(this->seekhigh-ptr);
4134 basic_streambuf_wchar_setp_next(&this->base, buf,
4135 buf+(basic_streambuf_wchar_pptr(&this->base)-ptr), buf+size);
4136 if(this->state & STRINGBUF_no_read)
4137 basic_streambuf_wchar_setg(&this->base, buf, NULL, buf);
4139 basic_streambuf_wchar_setg(&this->base, buf,
4140 buf+(basic_streambuf_wchar_gptr(&this->base)-ptr),
4141 basic_streambuf_wchar_pptr(&this->base)+1);
4143 MSVCRT_operator_delete(ptr);
4146 return (*basic_streambuf_wchar__Pninc(&this->base) = meta);
4149 /* ?pbackfail@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGG@Z */
4150 /* ?pbackfail@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGG@Z */
4151 /* ?pbackfail@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGG@Z */
4152 /* ?pbackfail@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGG@Z */
4153 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_pbackfail, 8)
4154 unsigned short __thiscall basic_stringbuf_wchar_pbackfail(basic_stringbuf_wchar *this, unsigned short c)
4158 TRACE("(%p %x)\n", this, c);
4160 cur = basic_streambuf_wchar_gptr(&this->base);
4161 if(!cur || cur==basic_streambuf_wchar_eback(&this->base)
4162 || (c!=WEOF && c!=cur[-1] && this->state&STRINGBUF_no_write))
4167 basic_streambuf_wchar_gbump(&this->base, -1);
4168 return c==WEOF ? !WEOF : c;
4171 /* ?underflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGXZ */
4172 /* ?underflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGXZ */
4173 /* ?underflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGXZ */
4174 /* ?underflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGXZ */
4175 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_underflow, 4)
4176 unsigned short __thiscall basic_stringbuf_wchar_underflow(basic_stringbuf_wchar *this)
4180 TRACE("(%p)\n", this);
4182 cur = basic_streambuf_wchar_gptr(&this->base);
4183 if(!cur || this->state&STRINGBUF_no_read)
4186 ptr = basic_streambuf_wchar_pptr(&this->base);
4187 if(this->seekhigh < ptr)
4188 this->seekhigh = ptr;
4190 ptr = basic_streambuf_wchar_egptr(&this->base);
4191 if(this->seekhigh > ptr)
4192 basic_streambuf_wchar_setg(&this->base, basic_streambuf_wchar_eback(&this->base), cur, this->seekhigh);
4194 if(cur < this->seekhigh)
4199 /* ?seekoff@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4200 /* ?seekoff@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4201 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4202 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4203 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekoff, 20)
4204 fpos_int* __thiscall basic_stringbuf_wchar_seekoff(basic_stringbuf_wchar *this,
4205 fpos_int *ret, streamoff off, int way, int mode)
4207 wchar_t *beg, *cur_r, *cur_w;
4209 TRACE("(%p %p %ld %d %d)\n", this, ret, off, way, mode);
4211 cur_w = basic_streambuf_wchar_pptr(&this->base);
4212 if(cur_w > this->seekhigh)
4213 this->seekhigh = cur_w;
4218 beg = basic_streambuf_wchar_eback(&this->base);
4219 cur_r = basic_streambuf_wchar_gptr(&this->base);
4220 if((mode & OPENMODE_in) && cur_r) {
4221 if(way==SEEKDIR_cur && !(mode & OPENMODE_out))
4223 else if(way == SEEKDIR_end)
4224 off += this->seekhigh-beg;
4225 else if(way != SEEKDIR_beg)
4228 if(off<0 || off>this->seekhigh-beg) {
4231 basic_streambuf_wchar_gbump(&this->base, beg-cur_r+off);
4232 if((mode & OPENMODE_out) && cur_w) {
4233 basic_streambuf_wchar_setp_next(&this->base, beg,
4234 basic_streambuf_wchar_gptr(&this->base),
4235 basic_streambuf_wchar_epptr(&this->base));
4238 }else if((mode & OPENMODE_out) && cur_w) {
4239 if(way == SEEKDIR_cur)
4241 else if(way == SEEKDIR_end)
4242 off += this->seekhigh-beg;
4243 else if(way != SEEKDIR_beg)
4246 if(off<0 || off>this->seekhigh-beg)
4249 basic_streambuf_wchar_pbump(&this->base, beg-cur_w+off);
4258 /* ?seekpos@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4259 /* ?seekpos@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4260 /* ?seekpos@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4261 /* ?seekpos@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4262 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekpos, 36)
4263 fpos_int* __thiscall basic_stringbuf_wchar_seekpos(basic_stringbuf_wchar *this,
4264 fpos_int *ret, fpos_int pos, int mode)
4266 TRACE("(%p %p %s %d)\n", this, ret, debugstr_fpos_int(&pos), mode);
4268 if(pos.off==0 && pos.pos==-1 && pos.state==0) {
4273 return basic_stringbuf_wchar_seekoff(this, ret, pos.off, SEEKDIR_beg, mode);
4276 /* ?str@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
4277 /* ?str@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXAEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
4278 /* ?str@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
4279 /* ?str@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXAEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
4280 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_str_set, 8)
4281 void __thiscall basic_stringbuf_wchar_str_set(basic_stringbuf_wchar *this, const basic_string_wchar *str)
4283 TRACE("(%p %p)\n", this, str);
4285 basic_stringbuf_wchar__Tidy(this);
4286 basic_stringbuf_wchar__Init(this, MSVCP_basic_string_wchar_c_str(str), str->size, this->state);
4289 /* ?str@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
4290 /* ?str@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
4291 /* ?str@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
4292 /* ?str@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
4293 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_str_get, 8)
4294 basic_string_wchar* __thiscall basic_stringbuf_wchar_str_get(const basic_stringbuf_wchar *this, basic_string_wchar *ret)
4298 TRACE("(%p)\n", this);
4300 if(!(this->state & STRINGBUF_no_write) && basic_streambuf_wchar_pptr(&this->base)) {
4303 ptr = basic_streambuf_wchar_pbase(&this->base);
4304 pptr = basic_streambuf_wchar_pptr(&this->base);
4306 return MSVCP_basic_string_wchar_ctor_cstr_len(ret, ptr, (this->seekhigh < pptr ? pptr : this->seekhigh) - ptr);
4309 if(!(this->state & STRINGBUF_no_read) && basic_streambuf_wchar_gptr(&this->base)) {
4310 ptr = basic_streambuf_wchar_eback(&this->base);
4311 return MSVCP_basic_string_wchar_ctor_cstr_len(ret, ptr, basic_streambuf_wchar_egptr(&this->base) - ptr);
4314 return MSVCP_basic_string_wchar_ctor(ret);
4317 /* ??0ios_base@std@@IAE@XZ */
4318 /* ??0ios_base@std@@IEAA@XZ */
4319 DEFINE_THISCALL_WRAPPER(ios_base_ctor, 4)
4320 ios_base* __thiscall ios_base_ctor(ios_base *this)
4322 TRACE("(%p)\n", this);
4323 this->vtable = &MSVCP_ios_base_vtable;
4327 /* ??0ios_base@std@@QAE@ABV01@@Z */
4328 /* ??0ios_base@std@@QEAA@AEBV01@@Z */
4329 DEFINE_THISCALL_WRAPPER(ios_base_copy_ctor, 8)
4330 ios_base* __thiscall ios_base_copy_ctor(ios_base *this, const ios_base *copy)
4332 TRACE("(%p %p)\n", this, copy);
4334 this->vtable = &MSVCP_ios_base_vtable;
4338 /* ?_Callfns@ios_base@std@@AAEXW4event@12@@Z */
4339 /* ?_Callfns@ios_base@std@@AEAAXW4event@12@@Z */
4340 DEFINE_THISCALL_WRAPPER(ios_base_Callfns, 8)
4341 void __thiscall ios_base_Callfns(ios_base *this, IOS_BASE_event event)
4343 IOS_BASE_fnarray *cur;
4345 TRACE("(%p %x)\n", this, event);
4347 for(cur=this->calls; cur; cur=cur->next)
4348 cur->event_handler(event, this, cur->index);
4351 /* ?_Tidy@ios_base@std@@AAAXXZ */
4352 /* ?_Tidy@ios_base@std@@AEAAXXZ */
4353 void CDECL ios_base_Tidy(ios_base *this)
4355 IOS_BASE_iosarray *arr_cur, *arr_next;
4356 IOS_BASE_fnarray *event_cur, *event_next;
4358 TRACE("(%p)\n", this);
4360 ios_base_Callfns(this, EVENT_erase_event);
4362 for(arr_cur=this->arr; arr_cur; arr_cur=arr_next) {
4363 arr_next = arr_cur->next;
4364 MSVCRT_operator_delete(arr_cur);
4368 for(event_cur=this->calls; event_cur; event_cur=event_next) {
4369 event_next = event_cur->next;
4370 MSVCRT_operator_delete(event_cur);
4375 /* ?_Ios_base_dtor@ios_base@std@@CAXPAV12@@Z */
4376 /* ?_Ios_base_dtor@ios_base@std@@CAXPEAV12@@Z */
4377 void CDECL ios_base_Ios_base_dtor(ios_base *obj)
4379 TRACE("(%p)\n", obj);
4381 locale_dtor(obj->loc);
4382 MSVCRT_operator_delete(obj->loc);
4387 /* ??1ios_base@std@@UAE@XZ */
4388 /* ??1ios_base@std@@UEAA@XZ */
4389 DEFINE_THISCALL_WRAPPER(ios_base_dtor, 4)
4390 void __thiscall ios_base_dtor(ios_base *this)
4392 ios_base_Ios_base_dtor(this);
4395 DEFINE_THISCALL_WRAPPER(ios_base_vector_dtor, 8)
4396 ios_base* __thiscall ios_base_vector_dtor(ios_base *this, unsigned int flags)
4398 TRACE("(%p %x)\n", this, flags);
4400 /* we have an array, with the number of elements stored before the first object */
4401 INT_PTR i, *ptr = (INT_PTR *)this-1;
4403 for(i=*ptr-1; i>=0; i--)
4404 ios_base_dtor(this+i);
4405 MSVCRT_operator_delete(ptr);
4407 ios_base_dtor(this);
4409 MSVCRT_operator_delete(this);
4415 DEFINE_THISCALL_WRAPPER(iosb_vector_dtor, 8)
4416 void* __thiscall iosb_vector_dtor(void *this, unsigned int flags)
4418 TRACE("(%p %x)\n", this, flags);
4420 INT_PTR *ptr = (INT_PTR *)this-1;
4421 MSVCRT_operator_delete(ptr);
4424 MSVCRT_operator_delete(this);
4430 /* ?_Findarr@ios_base@std@@AAEAAU_Iosarray@12@H@Z */
4431 /* ?_Findarr@ios_base@std@@AEAAAEAU_Iosarray@12@H@Z */
4432 DEFINE_THISCALL_WRAPPER(ios_base_Findarr, 8)
4433 IOS_BASE_iosarray* __thiscall ios_base_Findarr(ios_base *this, int index)
4435 IOS_BASE_iosarray *p;
4437 TRACE("(%p %d)\n", this, index);
4439 for(p=this->arr; p; p=p->next) {
4440 if(p->index == index)
4444 for(p=this->arr; p; p=p->next) {
4445 if(!p->long_val && !p->ptr_val) {
4451 p = MSVCRT_operator_new(sizeof(IOS_BASE_iosarray));
4452 p->next = this->arr;
4460 /* ?iword@ios_base@std@@QAEAAJH@Z */
4461 /* ?iword@ios_base@std@@QEAAAEAJH@Z */
4462 DEFINE_THISCALL_WRAPPER(ios_base_iword, 8)
4463 LONG* __thiscall ios_base_iword(ios_base *this, int index)
4465 TRACE("(%p %d)\n", this, index);
4466 return &ios_base_Findarr(this, index)->long_val;
4469 /* ?pword@ios_base@std@@QAEAAPAXH@Z */
4470 /* ?pword@ios_base@std@@QEAAAEAPEAXH@Z */
4471 DEFINE_THISCALL_WRAPPER(ios_base_pword, 8)
4472 void** __thiscall ios_base_pword(ios_base *this, int index)
4474 TRACE("(%p %d)\n", this, index);
4475 return &ios_base_Findarr(this, index)->ptr_val;
4478 /* ?register_callback@ios_base@std@@QAEXP6AXW4event@12@AAV12@H@ZH@Z */
4479 /* ?register_callback@ios_base@std@@QEAAXP6AXW4event@12@AEAV12@H@ZH@Z */
4480 DEFINE_THISCALL_WRAPPER(ios_base_register_callback, 12)
4481 void __thiscall ios_base_register_callback(ios_base *this, IOS_BASE_event_callback callback, int index)
4483 IOS_BASE_fnarray *event;
4485 TRACE("(%p %p %d)\n", this, callback, index);
4487 event = MSVCRT_operator_new(sizeof(IOS_BASE_fnarray));
4488 event->next = this->calls;
4489 event->index = index;
4490 event->event_handler = callback;
4491 this->calls = event;
4494 /* ?clear@ios_base@std@@QAEXH_N@Z */
4495 /* ?clear@ios_base@std@@QEAAXH_N@Z */
4496 DEFINE_THISCALL_WRAPPER(ios_base_clear_reraise, 12)
4497 void __thiscall ios_base_clear_reraise(ios_base *this, IOSB_iostate state, MSVCP_bool reraise)
4499 TRACE("(%p %x %x)\n", this, state, reraise);
4501 this->state = state & IOSTATE_mask;
4502 if(!(this->state & this->except))
4506 throw_exception(EXCEPTION_RERAISE, NULL);
4507 else if(this->state & this->except & IOSTATE_eofbit)
4508 throw_exception(EXCEPTION_FAILURE, "eofbit is set");
4509 else if(this->state & this->except & IOSTATE_failbit)
4510 throw_exception(EXCEPTION_FAILURE, "failbit is set");
4511 else if(this->state & this->except & IOSTATE_badbit)
4512 throw_exception(EXCEPTION_FAILURE, "badbit is set");
4513 else if(this->state & this->except & IOSTATE__Hardfail)
4514 throw_exception(EXCEPTION_FAILURE, "_Hardfail is set");
4517 /* ?clear@ios_base@std@@QAEXH@Z */
4518 /* ?clear@ios_base@std@@QEAAXH@Z */
4519 DEFINE_THISCALL_WRAPPER(ios_base_clear, 8)
4520 void __thiscall ios_base_clear(ios_base *this, IOSB_iostate state)
4522 ios_base_clear_reraise(this, state, FALSE);
4525 /* ?clear@ios_base@std@@QAEXI@Z */
4526 /* ?clear@ios_base@std@@QEAAXI@Z */
4527 DEFINE_THISCALL_WRAPPER(ios_base_clear_unsigned, 8)
4528 void __thiscall ios_base_clear_unsigned(ios_base *this, unsigned int state)
4530 ios_base_clear_reraise(this, (IOSB_iostate)state, FALSE);
4533 /* ?exceptions@ios_base@std@@QAEXH@Z */
4534 /* ?exceptions@ios_base@std@@QEAAXH@Z */
4535 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_set, 8)
4536 void __thiscall ios_base_exceptions_set(ios_base *this, IOSB_iostate state)
4538 TRACE("(%p %x)\n", this, state);
4539 this->except = state & IOSTATE_mask;
4540 ios_base_clear(this, this->state);
4543 /* ?exceptions@ios_base@std@@QAEXI@Z */
4544 /* ?exceptions@ios_base@std@@QEAAXI@Z */
4545 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_set_unsigned, 8)
4546 void __thiscall ios_base_exceptions_set_unsigned(ios_base *this, unsigned int state)
4548 TRACE("(%p %x)\n", this, state);
4549 ios_base_exceptions_set(this, state);
4552 /* ?exceptions@ios_base@std@@QBEHXZ */
4553 /* ?exceptions@ios_base@std@@QEBAHXZ */
4554 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_get, 4)
4555 IOSB_iostate __thiscall ios_base_exceptions_get(ios_base *this)
4557 TRACE("(%p)\n", this);
4558 return this->except;
4561 /* ?copyfmt@ios_base@std@@QAEAAV12@ABV12@@Z */
4562 /* ?copyfmt@ios_base@std@@QEAAAEAV12@AEBV12@@Z */
4563 DEFINE_THISCALL_WRAPPER(ios_base_copyfmt, 8)
4564 ios_base* __thiscall ios_base_copyfmt(ios_base *this, const ios_base *rhs)
4566 TRACE("(%p %p)\n", this, rhs);
4569 IOS_BASE_iosarray *arr_cur;
4570 IOS_BASE_fnarray *event_cur;
4572 ios_base_Tidy(this);
4574 for(arr_cur=rhs->arr; arr_cur; arr_cur=arr_cur->next) {
4575 if(arr_cur->long_val)
4576 *ios_base_iword(this, arr_cur->index) = arr_cur->long_val;
4577 if(arr_cur->ptr_val)
4578 *ios_base_pword(this, arr_cur->index) = arr_cur->ptr_val;
4580 this->stdstr = rhs->stdstr;
4581 this->fmtfl = rhs->fmtfl;
4582 this->prec = rhs->prec;
4583 this->wide = rhs->wide;
4584 locale_operator_assign(this->loc, rhs->loc);
4586 for(event_cur=rhs->calls; event_cur; event_cur=event_cur->next)
4587 ios_base_register_callback(this, event_cur->event_handler, event_cur->index);
4589 ios_base_Callfns(this, EVENT_copyfmt_event);
4590 ios_base_exceptions_set(this, rhs->except);
4596 /* ??4ios_base@std@@QAEAAV01@ABV01@@Z */
4597 /* ??4ios_base@std@@QEAAAEAV01@AEBV01@@Z */
4598 DEFINE_THISCALL_WRAPPER(ios_base_assign, 8)
4599 ios_base* __thiscall ios_base_assign(ios_base *this, const ios_base *right)
4601 TRACE("(%p %p)\n", this, right);
4604 this->state = right->state;
4605 ios_base_copyfmt(this, right);
4611 /* ?fail@ios_base@std@@QBE_NXZ */
4612 /* ?fail@ios_base@std@@QEBA_NXZ */
4613 DEFINE_THISCALL_WRAPPER(ios_base_fail, 4)
4614 MSVCP_bool __thiscall ios_base_fail(const ios_base *this)
4616 TRACE("(%p)\n", this);
4617 return (this->state & (IOSTATE_failbit|IOSTATE_badbit)) != 0;
4620 /* ??7ios_base@std@@QBE_NXZ */
4621 /* ??7ios_base@std@@QEBA_NXZ */
4622 DEFINE_THISCALL_WRAPPER(ios_base_op_succ, 4)
4623 MSVCP_bool __thiscall ios_base_op_succ(const ios_base *this)
4625 TRACE("(%p)\n", this);
4626 return ios_base_fail(this);
4629 /* ??Bios_base@std@@QBEPAXXZ */
4630 /* ??Bios_base@std@@QEBAPEAXXZ */
4631 DEFINE_THISCALL_WRAPPER(ios_base_op_fail, 4)
4632 void* __thiscall ios_base_op_fail(const ios_base *this)
4634 TRACE("(%p)\n", this);
4635 return ios_base_fail(this) ? NULL : (void*)this;
4638 /* ?_Addstd@ios_base@std@@SAXPAV12@@Z */
4639 /* ?_Addstd@ios_base@std@@SAXPEAV12@@Z */
4640 void CDECL ios_base_Addstd(ios_base *add)
4642 FIXME("(%p) stub\n", add);
4645 /* ?_Index_func@ios_base@std@@CAAAHXZ */
4646 /* ?_Index_func@ios_base@std@@CAAEAHXZ */
4647 int* CDECL ios_base_Index_func(void)
4650 return &ios_base_Index;
4653 /* ?_Init@ios_base@std@@IAEXXZ */
4654 /* ?_Init@ios_base@std@@IEAAXXZ */
4655 DEFINE_THISCALL_WRAPPER(ios_base__Init, 4)
4656 void __thiscall ios_base__Init(ios_base *this)
4658 TRACE("(%p)\n", this);
4661 this->state = this->except = IOSTATE_goodbit;
4662 this->fmtfl = FMTFLAG_skipws | FMTFLAG_dec;
4667 this->loc = MSVCRT_operator_new(sizeof(locale));
4668 locale_ctor(this->loc);
4671 /* ?_Sync_func@ios_base@std@@CAAA_NXZ */
4672 /* ?_Sync_func@ios_base@std@@CAAEA_NXZ */
4673 MSVCP_bool* CDECL ios_base_Sync_func(void)
4676 return &ios_base_Sync;
4679 /* ?bad@ios_base@std@@QBE_NXZ */
4680 /* ?bad@ios_base@std@@QEBA_NXZ */
4681 DEFINE_THISCALL_WRAPPER(ios_base_bad, 4)
4682 MSVCP_bool __thiscall ios_base_bad(const ios_base *this)
4684 TRACE("(%p)\n", this);
4685 return (this->state & IOSTATE_badbit) != 0;
4688 /* ?eof@ios_base@std@@QBE_NXZ */
4689 /* ?eof@ios_base@std@@QEBA_NXZ */
4690 DEFINE_THISCALL_WRAPPER(ios_base_eof, 4)
4691 MSVCP_bool __thiscall ios_base_eof(const ios_base *this)
4693 TRACE("(%p)\n", this);
4694 return (this->state & IOSTATE_eofbit) != 0;
4697 /* ?flags@ios_base@std@@QAEHH@Z */
4698 /* ?flags@ios_base@std@@QEAAHH@Z */
4699 DEFINE_THISCALL_WRAPPER(ios_base_flags_set, 8)
4700 IOSB_fmtflags __thiscall ios_base_flags_set(ios_base *this, IOSB_fmtflags flags)
4702 IOSB_fmtflags ret = this->fmtfl;
4704 TRACE("(%p %x)\n", this, flags);
4706 this->fmtfl = flags & FMTFLAG_mask;
4710 /* ?flags@ios_base@std@@QBEHXZ */
4711 /* ?flags@ios_base@std@@QEBAHXZ */
4712 DEFINE_THISCALL_WRAPPER(ios_base_flags_get, 4)
4713 IOSB_fmtflags __thiscall ios_base_flags_get(const ios_base *this)
4715 TRACE("(%p)\n", this);
4719 /* ?getloc@ios_base@std@@QBE?AVlocale@2@XZ */
4720 /* ?getloc@ios_base@std@@QEBA?AVlocale@2@XZ */
4721 DEFINE_THISCALL_WRAPPER(ios_base_getloc, 8)
4722 locale* __thiscall ios_base_getloc(const ios_base *this, locale *ret)
4724 TRACE("(%p)\n", this);
4725 return locale_copy_ctor(ret, this->loc);
4728 /* ?good@ios_base@std@@QBE_NXZ */
4729 /* ?good@ios_base@std@@QEBA_NXZ */
4730 DEFINE_THISCALL_WRAPPER(ios_base_good, 4)
4731 MSVCP_bool __thiscall ios_base_good(const ios_base *this)
4733 TRACE("(%p)\n", this);
4734 return this->state == IOSTATE_goodbit;
4737 /* ?imbue@ios_base@std@@QAE?AVlocale@2@ABV32@@Z */
4738 /* ?imbue@ios_base@std@@QEAA?AVlocale@2@AEBV32@@Z */
4739 DEFINE_THISCALL_WRAPPER(ios_base_imbue, 12)
4740 locale* __thiscall ios_base_imbue(ios_base *this, locale *ret, const locale *loc)
4742 TRACE("(%p %p)\n", this, loc);
4744 locale_copy_ctor(this->loc, loc);
4748 /* ?precision@ios_base@std@@QAEHH@Z */
4749 /* ?precision@ios_base@std@@QEAA_J_J@Z */
4750 DEFINE_THISCALL_WRAPPER(ios_base_precision_set, 8)
4751 streamsize __thiscall ios_base_precision_set(ios_base *this, streamsize precision)
4753 streamsize ret = this->prec;
4755 TRACE("(%p %ld)\n", this, precision);
4757 this->prec = precision;
4761 /* ?precision@ios_base@std@@QBEHXZ */
4762 /* ?precision@ios_base@std@@QEBA_JXZ */
4763 DEFINE_THISCALL_WRAPPER(ios_base_precision_get, 4)
4764 streamsize __thiscall ios_base_precision_get(const ios_base *this)
4766 TRACE("(%p)\n", this);
4770 /* ?rdstate@ios_base@std@@QBEHXZ */
4771 /* ?rdstate@ios_base@std@@QEBAHXZ */
4772 DEFINE_THISCALL_WRAPPER(ios_base_rdstate, 4)
4773 IOSB_iostate __thiscall ios_base_rdstate(const ios_base *this)
4775 TRACE("(%p)\n", this);
4779 /* ?setf@ios_base@std@@QAEHHH@Z */
4780 /* ?setf@ios_base@std@@QEAAHHH@Z */
4781 DEFINE_THISCALL_WRAPPER(ios_base_setf_mask, 12)
4782 IOSB_fmtflags __thiscall ios_base_setf_mask(ios_base *this, IOSB_fmtflags flags, IOSB_fmtflags mask)
4784 IOSB_fmtflags ret = this->fmtfl;
4786 TRACE("(%p %x %x)\n", this, flags, mask);
4788 this->fmtfl = (this->fmtfl & (~mask)) | (flags & mask & FMTFLAG_mask);
4792 /* ?setf@ios_base@std@@QAEHH@Z */
4793 /* ?setf@ios_base@std@@QEAAHH@Z */
4794 DEFINE_THISCALL_WRAPPER(ios_base_setf, 8)
4795 IOSB_fmtflags __thiscall ios_base_setf(ios_base *this, IOSB_fmtflags flags)
4797 return ios_base_setf_mask(this, flags, ~0);
4800 /* ?setstate@ios_base@std@@QAEXH_N@Z */
4801 /* ?setstate@ios_base@std@@QEAAXH_N@Z */
4802 DEFINE_THISCALL_WRAPPER(ios_base_setstate_reraise, 12)
4803 void __thiscall ios_base_setstate_reraise(ios_base *this, IOSB_iostate state, MSVCP_bool reraise)
4805 TRACE("(%p %x %x)\n", this, state, reraise);
4807 if(state != IOSTATE_goodbit)
4808 ios_base_clear_reraise(this, this->state | state, reraise);
4811 /* ?setstate@ios_base@std@@QAEXH@Z */
4812 /* ?setstate@ios_base@std@@QEAAXH@Z */
4813 DEFINE_THISCALL_WRAPPER(ios_base_setstate, 8)
4814 void __thiscall ios_base_setstate(ios_base *this, IOSB_iostate state)
4816 ios_base_setstate_reraise(this, state, FALSE);
4819 /* ?setstate@ios_base@std@@QAEXI@Z */
4820 /* ?setstate@ios_base@std@@QEAAXI@Z */
4821 DEFINE_THISCALL_WRAPPER(ios_base_setstate_unsigned, 8)
4822 void __thiscall ios_base_setstate_unsigned(ios_base *this, unsigned int state)
4824 ios_base_setstate_reraise(this, (IOSB_iostate)state, FALSE);
4827 /* ?sync_with_stdio@ios_base@std@@SA_N_N@Z */
4828 MSVCP_bool CDECL ios_base_sync_with_stdio(MSVCP_bool sync)
4833 TRACE("(%x)\n", sync);
4835 _Lockit_ctor_locktype(&lock, _LOCK_STREAM);
4836 ret = ios_base_Sync;
4837 ios_base_Sync = sync;
4838 _Lockit_dtor(&lock);
4842 /* ?unsetf@ios_base@std@@QAEXH@Z */
4843 /* ?unsetf@ios_base@std@@QEAAXH@Z */
4844 DEFINE_THISCALL_WRAPPER(ios_base_unsetf, 8)
4845 void __thiscall ios_base_unsetf(ios_base *this, IOSB_fmtflags flags)
4847 TRACE("(%p %x)\n", this, flags);
4848 this->fmtfl &= ~flags;
4851 /* ?width@ios_base@std@@QAEHH@Z */
4852 /* ?width@ios_base@std@@QEAA_J_J@Z */
4853 DEFINE_THISCALL_WRAPPER(ios_base_width_set, 8)
4854 streamsize __thiscall ios_base_width_set(ios_base *this, streamsize width)
4856 streamsize ret = this->wide;
4858 TRACE("(%p %ld)\n", this, width);
4864 /* ?width@ios_base@std@@QBEHXZ */
4865 /* ?width@ios_base@std@@QEBA_JXZ */
4866 DEFINE_THISCALL_WRAPPER(ios_base_width_get, 4)
4867 streamsize __thiscall ios_base_width_get(ios_base *this)
4869 TRACE("(%p)\n", this);
4873 /* ?xalloc@ios_base@std@@SAHXZ */
4874 int CDECL ios_base_xalloc(void)
4881 _Lockit_ctor_locktype(&lock, _LOCK_STREAM);
4882 ret = ios_base_Index++;
4883 _Lockit_dtor(&lock);
4887 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IAE@XZ */
4888 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IEAA@XZ */
4889 DEFINE_THISCALL_WRAPPER(basic_ios_char_ctor, 4)
4890 basic_ios_char* __thiscall basic_ios_char_ctor(basic_ios_char *this)
4892 TRACE("(%p)\n", this);
4894 ios_base_ctor(&this->base);
4895 this->base.vtable = &MSVCP_basic_ios_char_vtable;
4899 /* ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IAEXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z */
4900 /* ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z */
4901 DEFINE_THISCALL_WRAPPER(basic_ios_char_init, 12)
4902 void __thiscall basic_ios_char_init(basic_ios_char *this, basic_streambuf_char *streambuf, MSVCP_bool isstd)
4904 TRACE("(%p %p %x)\n", this, streambuf, isstd);
4905 ios_base__Init(&this->base);
4906 this->strbuf = streambuf;
4907 this->stream = NULL;
4911 ios_base_setstate(&this->base, IOSTATE_badbit);
4914 FIXME("standard streams not handled yet\n");
4917 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
4918 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
4919 DEFINE_THISCALL_WRAPPER(basic_ios_char_ctor_streambuf, 8)
4920 basic_ios_char* __thiscall basic_ios_char_ctor_streambuf(basic_ios_char *this, basic_streambuf_char *strbuf)
4922 TRACE("(%p %p)\n", this, strbuf);
4924 basic_ios_char_ctor(this);
4925 basic_ios_char_init(this, strbuf, FALSE);
4929 /* ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UAE@XZ */
4930 /* ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UEAA@XZ */
4931 DEFINE_THISCALL_WRAPPER(basic_ios_char_dtor, 4)
4932 void __thiscall basic_ios_char_dtor(basic_ios_char *this)
4934 TRACE("(%p)\n", this);
4935 ios_base_dtor(&this->base);
4938 DEFINE_THISCALL_WRAPPER(basic_ios_char_vector_dtor, 8)
4939 basic_ios_char* __thiscall basic_ios_char_vector_dtor(basic_ios_char *this, unsigned int flags)
4941 TRACE("(%p %x)\n", this, flags);
4943 /* we have an array, with the number of elements stored before the first object */
4944 INT_PTR i, *ptr = (INT_PTR *)this-1;
4946 for(i=*ptr-1; i>=0; i--)
4947 basic_ios_char_dtor(this+i);
4948 MSVCRT_operator_delete(ptr);
4950 basic_ios_char_dtor(this);
4952 MSVCRT_operator_delete(this);
4958 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z */
4959 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z */
4960 DEFINE_THISCALL_WRAPPER(basic_ios_char_clear_reraise, 12)
4961 void __thiscall basic_ios_char_clear_reraise(basic_ios_char *this, IOSB_iostate state, MSVCP_bool reraise)
4963 TRACE("(%p %x %x)\n", this, state, reraise);
4964 ios_base_clear_reraise(&this->base, state | (this->strbuf ? IOSTATE_goodbit : IOSTATE_badbit), reraise);
4967 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z */
4968 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z */
4969 DEFINE_THISCALL_WRAPPER(basic_ios_char_clear, 8)
4970 void __thiscall basic_ios_char_clear(basic_ios_char *this, unsigned int state)
4972 basic_ios_char_clear_reraise(this, (IOSB_iostate)state, FALSE);
4975 /* ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEAAV12@ABV12@@Z */
4976 /* ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEBV12@@Z */
4977 DEFINE_THISCALL_WRAPPER(basic_ios_char_copyfmt, 8)
4978 basic_ios_char* __thiscall basic_ios_char_copyfmt(basic_ios_char *this, basic_ios_char *copy)
4980 TRACE("(%p %p)\n", this, copy);
4984 this->stream = copy->stream;
4985 this->fillch = copy->fillch;
4986 ios_base_copyfmt(&this->base, ©->base);
4990 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEDD@Z */
4991 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAADD@Z */
4992 DEFINE_THISCALL_WRAPPER(basic_ios_char_fill_set, 8)
4993 char __thiscall basic_ios_char_fill_set(basic_ios_char *this, char fill)
4995 char ret = this->fillch;
4997 TRACE("(%p %c)\n", this, fill);
4999 this->fillch = fill;
5003 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDXZ */
5004 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADXZ */
5005 DEFINE_THISCALL_WRAPPER(basic_ios_char_fill_get, 4)
5006 char __thiscall basic_ios_char_fill_get(basic_ios_char *this)
5008 TRACE("(%p)\n", this);
5009 return this->fillch;
5012 /* ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5013 /* ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5014 DEFINE_THISCALL_WRAPPER(basic_ios_char_imbue, 12)
5015 locale *__thiscall basic_ios_char_imbue(basic_ios_char *this, locale *ret, const locale *loc)
5017 TRACE("(%p %p %p)\n", this, ret, loc);
5020 basic_streambuf_char_pubimbue(this->strbuf, ret, loc);
5024 return ios_base_imbue(&this->base, ret, loc);
5027 /* ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDDD@Z */
5028 /* ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADDD@Z */
5029 DEFINE_THISCALL_WRAPPER(basic_ios_char_narrow, 12)
5030 char __thiscall basic_ios_char_narrow(basic_ios_char *this, char ch, char def)
5032 TRACE("(%p %c %c)\n", this, ch, def);
5033 return ctype_char_narrow_ch(ctype_char_use_facet(this->strbuf->loc), ch, def);
5036 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PAV32@@Z */
5037 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAV32@@Z */
5038 DEFINE_THISCALL_WRAPPER(basic_ios_char_rdbuf_set, 8)
5039 basic_streambuf_char* __thiscall basic_ios_char_rdbuf_set(basic_ios_char *this, basic_streambuf_char *streambuf)
5041 basic_streambuf_char *ret = this->strbuf;
5043 TRACE("(%p %p)\n", this, streambuf);
5045 this->strbuf = streambuf;
5046 basic_ios_char_clear(this, IOSTATE_goodbit);
5050 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ */
5051 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ */
5052 DEFINE_THISCALL_WRAPPER(basic_ios_char_rdbuf_get, 4)
5053 basic_streambuf_char* __thiscall basic_ios_char_rdbuf_get(const basic_ios_char *this)
5055 TRACE("(%p)\n", this);
5056 return this->strbuf;
5059 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z */
5060 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z */
5061 DEFINE_THISCALL_WRAPPER(basic_ios_char_setstate_reraise, 12)
5062 void __thiscall basic_ios_char_setstate_reraise(basic_ios_char *this, IOSB_iostate state, MSVCP_bool reraise)
5064 TRACE("(%p %x %x)\n", this, state, reraise);
5066 if(state != IOSTATE_goodbit)
5067 basic_ios_char_clear_reraise(this, this->base.state | state, reraise);
5070 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z */
5071 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z */
5072 DEFINE_THISCALL_WRAPPER(basic_ios_char_setstate, 8)
5073 void __thiscall basic_ios_char_setstate(basic_ios_char *this, unsigned int state)
5075 basic_ios_char_setstate_reraise(this, (IOSB_iostate)state, FALSE);
5078 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@PAV32@@Z */
5079 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@PEAV32@@Z */
5080 DEFINE_THISCALL_WRAPPER(basic_ios_char_tie_set, 8)
5081 basic_ostream_char* __thiscall basic_ios_char_tie_set(basic_ios_char *this, basic_ostream_char *ostream)
5083 basic_ostream_char *ret = this->stream;
5085 TRACE("(%p %p)\n", this, ostream);
5087 this->stream = ostream;
5091 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ */
5092 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ */
5093 DEFINE_THISCALL_WRAPPER(basic_ios_char_tie_get, 4)
5094 basic_ostream_char* __thiscall basic_ios_char_tie_get(const basic_ios_char *this)
5096 TRACE("(%p)\n", this);
5097 return this->stream;
5100 /* ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDD@Z */
5101 /* ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADD@Z */
5102 DEFINE_THISCALL_WRAPPER(basic_ios_char_widen, 8)
5103 char __thiscall basic_ios_char_widen(basic_ios_char *this, char ch)
5105 TRACE("(%p %c)\n", this, ch);
5106 return ctype_char_widen_ch(ctype_char_use_facet(this->strbuf->loc), ch);
5110 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAE@XZ */
5111 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAA@XZ */
5112 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_ctor, 4)
5113 basic_ios_wchar* __thiscall basic_ios_wchar_ctor(basic_ios_wchar *this)
5115 TRACE("(%p)\n", this);
5117 ios_base_ctor(&this->base);
5118 this->base.vtable = &MSVCP_basic_ios_wchar_vtable;
5122 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IAE@XZ */
5123 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IEAA@XZ */
5124 DEFINE_THISCALL_WRAPPER(basic_ios_short_ctor, 4)
5125 basic_ios_wchar* __thiscall basic_ios_short_ctor(basic_ios_wchar *this)
5127 basic_ios_wchar_ctor(this);
5128 this->base.vtable = &MSVCP_basic_ios_short_vtable;
5132 /* ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z */
5133 /* ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z */
5134 /* ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IAEXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z */
5135 /* ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z */
5136 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_init, 12)
5137 void __thiscall basic_ios_wchar_init(basic_ios_wchar *this, basic_streambuf_wchar *streambuf, MSVCP_bool isstd)
5139 TRACE("(%p %p %x)\n", this, streambuf, isstd);
5140 ios_base__Init(&this->base);
5141 this->strbuf = streambuf;
5142 this->stream = NULL;
5146 ios_base_setstate(&this->base, IOSTATE_badbit);
5149 FIXME("standard streams not handled yet\n");
5152 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
5153 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
5154 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_ctor_streambuf, 8)
5155 basic_ios_wchar* __thiscall basic_ios_wchar_ctor_streambuf(basic_ios_wchar *this, basic_streambuf_wchar *strbuf)
5157 TRACE("(%p %p)\n", this, strbuf);
5159 basic_ios_wchar_ctor(this);
5160 basic_ios_wchar_init(this, strbuf, FALSE);
5164 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
5165 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
5166 DEFINE_THISCALL_WRAPPER(basic_ios_short_ctor_streambuf, 8)
5167 basic_ios_wchar* __thiscall basic_ios_short_ctor_streambuf(basic_ios_wchar *this, basic_streambuf_wchar *strbuf)
5169 basic_ios_wchar_ctor_streambuf(this, strbuf);
5170 this->base.vtable = &MSVCP_basic_ios_short_vtable;
5174 /* ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
5175 /* ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
5176 /* ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UAE@XZ */
5177 /* ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UEAA@XZ */
5178 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_dtor, 4)
5179 void __thiscall basic_ios_wchar_dtor(basic_ios_wchar *this)
5181 TRACE("(%p)\n", this);
5182 ios_base_dtor(&this->base);
5185 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_vector_dtor, 8)
5186 basic_ios_wchar* __thiscall basic_ios_wchar_vector_dtor(basic_ios_wchar *this, unsigned int flags)
5188 TRACE("(%p %x)\n", this, flags);
5190 /* we have an array, with the number of elements stored before the first object */
5191 INT_PTR i, *ptr = (INT_PTR *)this-1;
5193 for(i=*ptr-1; i>=0; i--)
5194 basic_ios_wchar_dtor(this+i);
5195 MSVCRT_operator_delete(ptr);
5197 basic_ios_wchar_dtor(this);
5199 MSVCRT_operator_delete(this);
5205 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z */
5206 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z */
5207 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z */
5208 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z */
5209 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_clear_reraise, 12)
5210 void __thiscall basic_ios_wchar_clear_reraise(basic_ios_wchar *this, IOSB_iostate state, MSVCP_bool reraise)
5212 TRACE("(%p %x %x)\n", this, state, reraise);
5213 ios_base_clear_reraise(&this->base, state | (this->strbuf ? IOSTATE_goodbit : IOSTATE_badbit), reraise);
5216 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z */
5217 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z */
5218 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z */
5219 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z */
5220 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_clear, 8)
5221 void __thiscall basic_ios_wchar_clear(basic_ios_wchar *this, unsigned int state)
5223 basic_ios_wchar_clear_reraise(this, (IOSB_iostate)state, FALSE);
5226 /* ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEAAV12@ABV12@@Z */
5227 /* ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEBV12@@Z */
5228 /* ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEAAV12@ABV12@@Z */
5229 /* ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEBV12@@Z */
5230 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_copyfmt, 8)
5231 basic_ios_wchar* __thiscall basic_ios_wchar_copyfmt(basic_ios_wchar *this, basic_ios_wchar *copy)
5233 TRACE("(%p %p)\n", this, copy);
5237 this->stream = copy->stream;
5238 this->fillch = copy->fillch;
5239 ios_base_copyfmt(&this->base, ©->base);
5243 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE_W_W@Z */
5244 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA_W_W@Z */
5245 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEGG@Z */
5246 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAGG@Z */
5247 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_fill_set, 8)
5248 wchar_t __thiscall basic_ios_wchar_fill_set(basic_ios_wchar *this, wchar_t fill)
5250 wchar_t ret = this->fillch;
5252 TRACE("(%p %c)\n", this, fill);
5254 this->fillch = fill;
5258 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WXZ */
5259 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WXZ */
5260 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGXZ */
5261 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGXZ */
5262 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_fill_get, 4)
5263 wchar_t __thiscall basic_ios_wchar_fill_get(basic_ios_wchar *this)
5265 TRACE("(%p)\n", this);
5266 return this->fillch;
5269 /* ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5270 /* ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5271 /* ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5272 /* ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5273 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_imbue, 12)
5274 locale *__thiscall basic_ios_wchar_imbue(basic_ios_wchar *this, locale *ret, const locale *loc)
5276 TRACE("(%p %p %p)\n", this, ret, loc);
5279 basic_streambuf_wchar_pubimbue(this->strbuf, ret, loc);
5283 return ios_base_imbue(&this->base, ret, loc);
5286 /* ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBED_WD@Z */
5287 /* ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAD_WD@Z */
5288 /* ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEDGD@Z */
5289 /* ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBADGD@Z */
5290 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_narrow, 12)
5291 char __thiscall basic_ios_wchar_narrow(basic_ios_wchar *this, wchar_t ch, char def)
5293 TRACE("(%p %c %c)\n", this, ch, def);
5294 return ctype_wchar_narrow_ch(ctype_wchar_use_facet(this->strbuf->loc), ch, def);
5297 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PAV32@@Z */
5298 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEAV32@@Z */
5299 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAV32@@Z */
5300 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAV32@@Z */
5301 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_rdbuf_set, 8)
5302 basic_streambuf_wchar* __thiscall basic_ios_wchar_rdbuf_set(basic_ios_wchar *this, basic_streambuf_wchar *streambuf)
5304 basic_streambuf_wchar *ret = this->strbuf;
5306 TRACE("(%p %p)\n", this, streambuf);
5308 this->strbuf = streambuf;
5309 basic_ios_wchar_clear(this, IOSTATE_goodbit);
5313 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ */
5314 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ */
5315 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ */
5316 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ */
5317 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_rdbuf_get, 4)
5318 basic_streambuf_wchar* __thiscall basic_ios_wchar_rdbuf_get(const basic_ios_wchar *this)
5320 TRACE("(%p)\n", this);
5321 return this->strbuf;
5324 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z */
5325 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z */
5326 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z */
5327 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z */
5328 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_setstate_reraise, 12)
5329 void __thiscall basic_ios_wchar_setstate_reraise(basic_ios_wchar *this, IOSB_iostate state, MSVCP_bool reraise)
5331 TRACE("(%p %x %x)\n", this, state, reraise);
5333 if(state != IOSTATE_goodbit)
5334 basic_ios_wchar_clear_reraise(this, this->base.state | state, reraise);
5337 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z */
5338 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z */
5339 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z */
5340 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z */
5341 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_setstate, 8)
5342 void __thiscall basic_ios_wchar_setstate(basic_ios_wchar *this, IOSB_iostate state)
5344 basic_ios_wchar_setstate_reraise(this, state, FALSE);
5347 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PAV32@@Z */
5348 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PEAV32@@Z */
5349 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@PAV32@@Z */
5350 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@PEAV32@@Z */
5351 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_tie_set, 8)
5352 basic_ostream_wchar* __thiscall basic_ios_wchar_tie_set(basic_ios_wchar *this, basic_ostream_wchar *ostream)
5354 basic_ostream_wchar *ret = this->stream;
5356 TRACE("(%p %p)\n", this, ostream);
5358 this->stream = ostream;
5362 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ */
5363 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ */
5364 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ */
5365 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ */
5366 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_tie_get, 4)
5367 basic_ostream_wchar* __thiscall basic_ios_wchar_tie_get(const basic_ios_wchar *this)
5369 TRACE("(%p)\n", this);
5370 return this->stream;
5373 /* ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WD@Z */
5374 /* ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WD@Z */
5375 /* ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGD@Z */
5376 /* ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGD@Z */
5377 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_widen, 8)
5378 wchar_t __thiscall basic_ios_wchar_widen(basic_ios_wchar *this, char ch)
5380 TRACE("(%p %c)\n", this, ch);
5381 return ctype_wchar_widen_ch(ctype_wchar_use_facet(this->strbuf->loc), ch);
5384 /* Caution: basic_ostream uses virtual inheritance.
5385 * All constructors have additional parameter that says if base class should be initialized.
5386 * Base class needs to be accessed using vbtable.
5388 static inline basic_ios_char* basic_ostream_char_get_basic_ios(basic_ostream_char *this)
5390 return (basic_ios_char*)((char*)this+this->vbtable[1]);
5393 static inline basic_ios_char* basic_ostream_char_to_basic_ios(basic_ostream_char *ptr)
5395 return (basic_ios_char*)((char*)ptr+basic_ostream_char_vbtable[1]);
5398 static inline basic_ostream_char* basic_ostream_char_from_basic_ios(basic_ios_char *ptr)
5400 return (basic_ostream_char*)((char*)ptr-basic_ostream_char_vbtable[1]);
5403 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
5404 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
5405 DEFINE_THISCALL_WRAPPER(basic_ostream_char_ctor, 16)
5406 basic_ostream_char* __thiscall basic_ostream_char_ctor(basic_ostream_char *this,
5407 basic_streambuf_char *strbuf, MSVCP_bool isstd, MSVCP_bool virt_init)
5409 basic_ios_char *base;
5411 TRACE("(%p %p %d %d)\n", this, strbuf, isstd, virt_init);
5414 this->vbtable = basic_ostream_char_vbtable;
5415 base = basic_ostream_char_get_basic_ios(this);
5416 basic_ios_char_ctor(base);
5418 base = basic_ostream_char_get_basic_ios(this);
5421 base->base.vtable = &MSVCP_basic_ostream_char_vtable;
5422 basic_ios_char_init(base, strbuf, isstd);
5426 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
5427 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
5428 DEFINE_THISCALL_WRAPPER(basic_ostream_char_ctor_uninitialized, 16)
5429 basic_ostream_char* __thiscall basic_ostream_char_ctor_uninitialized(basic_ostream_char *this,
5430 int uninitialized, MSVCP_bool addstd, MSVCP_bool virt_init)
5432 basic_ios_char *base;
5434 TRACE("(%p %d %x)\n", this, uninitialized, addstd);
5437 this->vbtable = basic_ostream_char_vbtable;
5438 base = basic_ostream_char_get_basic_ios(this);
5439 basic_ios_char_ctor(base);
5441 base = basic_ostream_char_get_basic_ios(this);
5444 base->base.vtable = &MSVCP_basic_ostream_char_vtable;
5446 ios_base_Addstd(&base->base);
5450 /* ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UAE@XZ */
5451 /* ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
5452 DEFINE_THISCALL_WRAPPER(basic_ostream_char_dtor, 4)
5453 void __thiscall basic_ostream_char_dtor(basic_ios_char *base)
5455 basic_ostream_char *this = basic_ostream_char_from_basic_ios(base);
5457 /* don't destroy virtual base here */
5458 TRACE("(%p)\n", this);
5461 /* ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
5462 /* ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
5463 DEFINE_THISCALL_WRAPPER(basic_ostream_char_vbase_dtor, 4)
5464 void __thiscall basic_ostream_char_vbase_dtor(basic_ostream_char *this)
5466 TRACE("(%p)\n", this);
5467 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(this));
5468 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(this));
5471 DEFINE_THISCALL_WRAPPER(basic_ostream_char_vector_dtor, 8)
5472 basic_ostream_char* __thiscall basic_ostream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
5474 basic_ostream_char *this = basic_ostream_char_from_basic_ios(base);
5476 TRACE("(%p %x)\n", this, flags);
5479 /* we have an array, with the number of elements stored before the first object */
5480 INT_PTR i, *ptr = (INT_PTR *)this-1;
5482 for(i=*ptr-1; i>=0; i--)
5483 basic_ostream_char_vbase_dtor(this+i);
5484 MSVCRT_operator_delete(ptr);
5486 basic_ostream_char_vbase_dtor(this);
5488 MSVCRT_operator_delete(this);
5494 /* ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ */
5495 /* ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ */
5496 DEFINE_THISCALL_WRAPPER(basic_ostream_char_flush, 4)
5497 basic_ostream_char* __thiscall basic_ostream_char_flush(basic_ostream_char *this)
5499 /* this function is not matching C++ specification */
5500 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5502 TRACE("(%p)\n", this);
5504 if(basic_ios_char_rdbuf_get(base) && ios_base_good(&base->base)
5505 && basic_streambuf_char_pubsync(basic_ios_char_rdbuf_get(base))==-1)
5506 basic_ios_char_setstate(base, IOSTATE_badbit);
5510 /* ?flush@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
5511 /* ?flush@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
5512 basic_ostream_char* __cdecl flush_ostream_char(basic_ostream_char *ostream)
5514 return basic_ostream_char_flush(ostream);
5517 /* ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
5518 /* ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
5519 DEFINE_THISCALL_WRAPPER(basic_ostream_char__Osfx, 4)
5520 void __thiscall basic_ostream_char__Osfx(basic_ostream_char *this)
5522 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5524 TRACE("(%p)\n", this);
5526 if(base->base.fmtfl & FMTFLAG_unitbuf)
5527 basic_ostream_char_flush(this);
5530 /* ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
5531 /* ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
5532 DEFINE_THISCALL_WRAPPER(basic_ostream_char_osfx, 4)
5533 void __thiscall basic_ostream_char_osfx(basic_ostream_char *this)
5535 TRACE("(%p)\n", this);
5536 basic_ostream_char__Osfx(this);
5539 static BOOL basic_ostream_char_sentry_create(basic_ostream_char *ostr)
5541 basic_ios_char *base = basic_ostream_char_get_basic_ios(ostr);
5543 if(basic_ios_char_rdbuf_get(base))
5544 basic_streambuf_char__Lock(base->strbuf);
5546 if(ios_base_good(&base->base) && base->stream)
5547 basic_ostream_char_flush(base->stream);
5549 return ios_base_good(&base->base);
5552 static void basic_ostream_char_sentry_destroy(basic_ostream_char *ostr)
5554 basic_ios_char *base = basic_ostream_char_get_basic_ios(ostr);
5556 if(ios_base_good(&base->base) && !__uncaught_exception())
5557 basic_ostream_char_osfx(ostr);
5559 if(basic_ios_char_rdbuf_get(base))
5560 basic_streambuf_char__Unlock(base->strbuf);
5563 /* ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE_NXZ */
5564 /* ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA_NXZ */
5565 DEFINE_THISCALL_WRAPPER(basic_ostream_char_opfx, 4)
5566 MSVCP_bool __thiscall basic_ostream_char_opfx(basic_ostream_char *this)
5568 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5570 TRACE("(%p)\n", this);
5572 if(ios_base_good(&base->base) && base->stream)
5573 basic_ostream_char_flush(base->stream);
5574 return ios_base_good(&base->base);
5577 /* ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z */
5578 /* ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z */
5579 DEFINE_THISCALL_WRAPPER(basic_ostream_char_put, 8)
5580 basic_ostream_char* __thiscall basic_ostream_char_put(basic_ostream_char *this, char ch)
5582 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5584 TRACE("(%p %c)\n", this, ch);
5586 if(!basic_ostream_char_sentry_create(this)
5587 || basic_streambuf_char_sputc(base->strbuf, ch)==EOF) {
5588 basic_ostream_char_sentry_destroy(this);
5589 basic_ios_char_setstate(base, IOSTATE_badbit);
5593 basic_ostream_char_sentry_destroy(this);
5597 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@JH@Z */
5598 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
5599 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp, 12)
5600 basic_ostream_char* __thiscall basic_ostream_char_seekp(basic_ostream_char *this, streamoff off, int way)
5602 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5604 TRACE("(%p %ld %d)\n", this, off, way);
5606 if(!ios_base_fail(&base->base)) {
5609 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base),
5610 &seek, off, way, OPENMODE_out);
5611 if(seek.off==0 && seek.pos==-1 && seek.state==0)
5612 basic_ios_char_setstate(base, IOSTATE_failbit);
5617 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
5618 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
5619 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp_fpos, 28)
5620 basic_ostream_char* __thiscall basic_ostream_char_seekp_fpos(basic_ostream_char *this, fpos_int pos)
5622 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5624 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos));
5626 if(!ios_base_fail(&base->base)) {
5629 basic_streambuf_char_pubseekpos(basic_ios_char_rdbuf_get(base),
5630 &seek, pos, OPENMODE_out);
5631 if(seek.off==0 && seek.pos==-1 && seek.state==0)
5632 basic_ios_char_setstate(base, IOSTATE_failbit);
5637 /* ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ */
5638 /* ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
5639 DEFINE_THISCALL_WRAPPER(basic_ostream_char_tellp, 8)
5640 fpos_int* __thiscall basic_ostream_char_tellp(basic_ostream_char *this, fpos_int *ret)
5642 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5644 TRACE("(%p)\n", this);
5646 if(!ios_base_fail(&base->base)) {
5647 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base),
5648 ret, 0, SEEKDIR_cur, OPENMODE_out);
5657 /* ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@PBDH@Z */
5658 /* ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEBD_J@Z */
5659 DEFINE_THISCALL_WRAPPER(basic_ostream_char_write, 12)
5660 basic_ostream_char* __thiscall basic_ostream_char_write(basic_ostream_char *this, const char *str, streamsize count)
5662 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5664 TRACE("(%p %s %ld)\n", this, debugstr_a(str), count);
5666 if(!basic_ostream_char_sentry_create(this)
5667 || basic_streambuf_char_sputn(base->strbuf, str, count)!=count) {
5668 basic_ostream_char_sentry_destroy(this);
5669 basic_ios_char_setstate(base, IOSTATE_badbit);
5673 basic_ostream_char_sentry_destroy(this);
5677 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@F@Z */
5678 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@F@Z */
5679 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_short, 8)
5680 basic_ostream_char* __thiscall basic_ostream_char_print_short(basic_ostream_char *this, short val)
5682 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5683 int state = IOSTATE_goodbit;
5685 TRACE("(%p %d)\n", this, val);
5687 if(basic_ostream_char_sentry_create(this)) {
5688 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5689 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5690 ostreambuf_iterator_char dest = {0, strbuf};
5692 num_put_char_put_long(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base),
5693 (ios_base_flags_get(&base->base) & FMTFLAG_basefield & (FMTFLAG_oct | FMTFLAG_hex))
5694 ? (LONG)((unsigned short)val) : (LONG)val);
5696 basic_ostream_char_sentry_destroy(this);
5698 basic_ios_char_setstate(base, state);
5702 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@G@Z */
5703 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@G@Z */
5704 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ushort, 8)
5705 basic_ostream_char* __thiscall basic_ostream_char_print_ushort(basic_ostream_char *this, unsigned short val)
5707 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5708 int state = IOSTATE_goodbit;
5710 TRACE("(%p %u)\n", this, val);
5712 if(basic_ostream_char_sentry_create(this)) {
5713 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5714 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5715 ostreambuf_iterator_char dest = {0, strbuf};
5717 num_put_char_put_ulong(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5719 basic_ostream_char_sentry_destroy(this);
5721 basic_ios_char_setstate(base, state);
5725 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@H@Z */
5726 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@H@Z */
5727 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@J@Z */
5728 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@J@Z */
5729 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_int, 8)
5730 basic_ostream_char* __thiscall basic_ostream_char_print_int(basic_ostream_char *this, int val)
5732 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5733 int state = IOSTATE_goodbit;
5735 TRACE("(%p %d)\n", this, val);
5737 if(basic_ostream_char_sentry_create(this)) {
5738 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5739 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5740 ostreambuf_iterator_char dest = {0, strbuf};
5742 num_put_char_put_long(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5744 basic_ostream_char_sentry_destroy(this);
5746 basic_ios_char_setstate(base, state);
5750 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@I@Z */
5751 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@I@Z */
5752 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@K@Z */
5753 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@K@Z */
5754 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_uint, 8)
5755 basic_ostream_char* __thiscall basic_ostream_char_print_uint(basic_ostream_char *this, unsigned int val)
5757 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5758 int state = IOSTATE_goodbit;
5760 TRACE("(%p %u)\n", this, val);
5762 if(basic_ostream_char_sentry_create(this)) {
5763 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5764 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5765 ostreambuf_iterator_char dest = {0, strbuf};
5767 num_put_char_put_ulong(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5769 basic_ostream_char_sentry_destroy(this);
5771 basic_ios_char_setstate(base, state);
5775 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@M@Z */
5776 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@M@Z */
5777 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_float, 8)
5778 basic_ostream_char* __thiscall basic_ostream_char_print_float(basic_ostream_char *this, float val)
5780 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5781 int state = IOSTATE_goodbit;
5783 TRACE("(%p %f)\n", this, val);
5785 if(basic_ostream_char_sentry_create(this)) {
5786 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5787 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5788 ostreambuf_iterator_char dest = {0, strbuf};
5790 num_put_char_put_double(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5792 basic_ostream_char_sentry_destroy(this);
5794 basic_ios_char_setstate(base, state);
5798 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@N@Z */
5799 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@N@Z */
5800 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_double, 12)
5801 basic_ostream_char* __thiscall basic_ostream_char_print_double(basic_ostream_char *this, double val)
5803 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5804 int state = IOSTATE_goodbit;
5806 TRACE("(%p %lf)\n", this, val);
5808 if(basic_ostream_char_sentry_create(this)) {
5809 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5810 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5811 ostreambuf_iterator_char dest = {0, strbuf};
5813 num_put_char_put_double(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5815 basic_ostream_char_sentry_destroy(this);
5817 basic_ios_char_setstate(base, state);
5821 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@O@Z */
5822 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@O@Z */
5823 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ldouble, 12)
5824 basic_ostream_char* __thiscall basic_ostream_char_print_ldouble(basic_ostream_char *this, double val)
5826 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5827 int state = IOSTATE_goodbit;
5829 TRACE("(%p %lf)\n", this, val);
5831 if(basic_ostream_char_sentry_create(this)) {
5832 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5833 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5834 ostreambuf_iterator_char dest = {0, strbuf};
5836 num_put_char_put_ldouble(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5838 basic_ostream_char_sentry_destroy(this);
5840 basic_ios_char_setstate(base, state);
5844 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
5845 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
5846 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_streambuf, 8)
5847 basic_ostream_char* __thiscall basic_ostream_char_print_streambuf(basic_ostream_char *this, basic_streambuf_char *val)
5849 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5850 IOSB_iostate state = IOSTATE_badbit;
5853 TRACE("(%p %p)\n", this, val);
5855 if(basic_ostream_char_sentry_create(this)) {
5856 for(c = basic_streambuf_char_sgetc(val); c!=EOF;
5857 c = basic_streambuf_char_snextc(val)) {
5858 state = IOSTATE_goodbit;
5860 if(basic_streambuf_char_sputc(base->strbuf, c) == EOF) {
5861 state = IOSTATE_badbit;
5866 state = IOSTATE_badbit;
5868 basic_ostream_char_sentry_destroy(this);
5870 ios_base_width_set(&base->base, 0);
5871 basic_ios_char_setstate(base, state);
5875 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PBX@Z */
5876 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEBX@Z */
5877 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ptr, 8)
5878 basic_ostream_char* __thiscall basic_ostream_char_print_ptr(basic_ostream_char *this, const void *val)
5880 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5881 int state = IOSTATE_goodbit;
5883 TRACE("(%p %p)\n", this, val);
5885 if(basic_ostream_char_sentry_create(this)) {
5886 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5887 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5888 ostreambuf_iterator_char dest = {0, strbuf};
5890 num_put_char_put_ptr(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5892 basic_ostream_char_sentry_destroy(this);
5894 basic_ios_char_setstate(base, state);
5898 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_J@Z */
5899 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_J@Z */
5900 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_int64, 12)
5901 basic_ostream_char* __thiscall basic_ostream_char_print_int64(basic_ostream_char *this, __int64 val)
5903 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5904 int state = IOSTATE_goodbit;
5906 TRACE("(%p)\n", this);
5908 if(basic_ostream_char_sentry_create(this)) {
5909 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5910 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5911 ostreambuf_iterator_char dest = {0, strbuf};
5913 num_put_char_put_int64(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5915 basic_ostream_char_sentry_destroy(this);
5917 basic_ios_char_setstate(base, state);
5921 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_K@Z */
5922 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_K@Z */
5923 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_uint64, 12)
5924 basic_ostream_char* __thiscall basic_ostream_char_print_uint64(basic_ostream_char *this, unsigned __int64 val)
5926 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5927 int state = IOSTATE_goodbit;
5929 TRACE("(%p)\n", this);
5931 if(basic_ostream_char_sentry_create(this)) {
5932 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5933 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5934 ostreambuf_iterator_char dest = {0, strbuf};
5936 num_put_char_put_uint64(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5938 basic_ostream_char_sentry_destroy(this);
5940 basic_ios_char_setstate(base, state);
5944 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_N@Z */
5945 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_N@Z */
5946 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_bool, 8)
5947 basic_ostream_char* __thiscall basic_ostream_char_print_bool(basic_ostream_char *this, MSVCP_bool val)
5949 basic_ios_char *base = basic_ostream_char_get_basic_ios(this);
5950 int state = IOSTATE_goodbit;
5952 TRACE("(%p %x)\n", this, val);
5954 if(basic_ostream_char_sentry_create(this)) {
5955 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
5956 const num_put *numput = num_put_char_use_facet(strbuf->loc);
5957 ostreambuf_iterator_char dest = {0, strbuf};
5959 num_put_char_put_bool(numput, &dest, dest, &base->base, basic_ios_char_fill_get(base), val);
5961 basic_ostream_char_sentry_destroy(this);
5963 basic_ios_char_setstate(base, state);
5967 /* ?endl@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
5968 /* ?endl@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
5969 basic_ostream_char* __cdecl basic_ostream_char_endl(basic_ostream_char *ostr)
5971 TRACE("(%p)\n", ostr);
5973 basic_ostream_char_put(ostr, '\n');
5974 basic_ostream_char_flush(ostr);
5978 /* $?6DU?$char_traits@D@std@@V?$allocator@D@1@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@@Z */
5979 /* ??$?6DU?$char_traits@D@std@@V?$allocator@D@1@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@@Z */
5980 basic_ostream_char* __cdecl basic_ostream_char_print_bstr(basic_ostream_char *ostr, const basic_string_char *str)
5982 basic_ios_char *base = basic_ostream_char_get_basic_ios(ostr);
5983 IOSB_iostate state = IOSTATE_goodbit;
5985 TRACE("(%p %p)\n", ostr, str);
5987 if(basic_ostream_char_sentry_create(ostr)) {
5988 MSVCP_size_t len = MSVCP_basic_string_char_length(str);
5989 streamsize pad = (base->base.wide>len ? base->base.wide-len : 0);
5991 if((base->base.fmtfl & FMTFLAG_adjustfield) != FMTFLAG_left) {
5992 for(; pad!=0; pad--) {
5993 if(basic_streambuf_char_sputc(base->strbuf, base->fillch) == EOF) {
5994 state = IOSTATE_badbit;
6000 if(state == IOSTATE_goodbit) {
6001 if(basic_streambuf_char_sputn(base->strbuf, MSVCP_basic_string_char_c_str(str), len) != len)
6002 state = IOSTATE_badbit;
6005 if(state == IOSTATE_goodbit) {
6006 for(; pad!=0; pad--) {
6007 if(basic_streambuf_char_sputc(base->strbuf, base->fillch) == EOF) {
6008 state = IOSTATE_badbit;
6014 base->base.wide = 0;
6016 state = IOSTATE_badbit;
6018 basic_ostream_char_sentry_destroy(ostr);
6020 basic_ios_char_setstate(base, state);
6024 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@C@Z */
6025 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@C@Z */
6026 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@D@Z */
6027 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@D@Z */
6028 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@E@Z */
6029 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@E@Z */
6030 basic_ostream_char* __cdecl basic_ostream_char_print_ch(basic_ostream_char *ostr, char ch)
6032 basic_ios_char *base = basic_ostream_char_get_basic_ios(ostr);
6033 IOSB_iostate state = IOSTATE_goodbit;
6035 TRACE("(%p %d)\n", ostr, ch);
6037 if(basic_ostream_char_sentry_create(ostr)) {
6038 streamsize pad = (base->base.wide>1 ? base->base.wide-1 : 0);
6040 if((base->base.fmtfl & FMTFLAG_adjustfield) != FMTFLAG_left) {
6041 for(; pad!=0; pad--) {
6042 if(basic_streambuf_char_sputc(base->strbuf, base->fillch) == EOF) {
6043 state = IOSTATE_badbit;
6049 if(state == IOSTATE_goodbit) {
6050 if(basic_streambuf_char_sputc(base->strbuf, ch) == EOF)
6051 state = IOSTATE_badbit;
6054 if(state == IOSTATE_goodbit) {
6055 for(; pad!=0; pad--) {
6056 if(basic_streambuf_char_sputc(base->strbuf, base->fillch) == EOF) {
6057 state = IOSTATE_badbit;
6063 base->base.wide = 0;
6065 state = IOSTATE_badbit;
6067 basic_ostream_char_sentry_destroy(ostr);
6069 basic_ios_char_setstate(base, state);
6073 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBC@Z */
6074 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBC@Z */
6075 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBD@Z */
6076 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBD@Z */
6077 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBE@Z */
6078 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBE@Z */
6079 basic_ostream_char* __cdecl basic_ostream_char_print_str(basic_ostream_char *ostr, const char *str)
6081 basic_ios_char *base = basic_ostream_char_get_basic_ios(ostr);
6082 IOSB_iostate state = IOSTATE_goodbit;
6084 TRACE("(%p %s)\n", ostr, str);
6086 if(basic_ostream_char_sentry_create(ostr)) {
6087 MSVCP_size_t len = strlen(str);
6088 streamsize pad = (base->base.wide>len ? base->base.wide-len : 0);
6090 if((base->base.fmtfl & FMTFLAG_adjustfield) != FMTFLAG_left) {
6091 for(; pad!=0; pad--) {
6092 if(basic_streambuf_char_sputc(base->strbuf, base->fillch) == EOF) {
6093 state = IOSTATE_badbit;
6099 if(state == IOSTATE_goodbit) {
6100 if(basic_streambuf_char_sputn(base->strbuf, str, len) != len)
6101 state = IOSTATE_badbit;
6104 if(state == IOSTATE_goodbit) {
6105 for(; pad!=0; pad--) {
6106 if(basic_streambuf_char_sputc(base->strbuf, base->fillch) == EOF) {
6107 state = IOSTATE_badbit;
6113 base->base.wide = 0;
6115 state = IOSTATE_badbit;
6117 basic_ostream_char_sentry_destroy(ostr);
6119 basic_ios_char_setstate(base, state);
6123 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
6124 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
6125 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func, 8)
6126 basic_ostream_char* __thiscall basic_ostream_char_print_func(basic_ostream_char *this,
6127 basic_ostream_char* (__cdecl *pfunc)(basic_ostream_char*))
6129 TRACE("(%p %p)\n", this, pfunc);
6134 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z */
6135 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z */
6136 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func_basic_ios, 8)
6137 basic_ostream_char* __thiscall basic_ostream_char_print_func_basic_ios(basic_ostream_char *this,
6138 basic_ios_char* (__cdecl *pfunc)(basic_ios_char*))
6140 TRACE("(%p %p)\n", this, pfunc);
6141 pfunc(basic_ostream_char_get_basic_ios(this));
6145 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
6146 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
6147 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func_ios_base, 8)
6148 basic_ostream_char* __thiscall basic_ostream_char_print_func_ios_base(
6149 basic_ostream_char *this, ios_base* (__cdecl *pfunc)(ios_base*))
6151 TRACE("(%p %p)\n", this, pfunc);
6152 pfunc(&basic_ostream_char_get_basic_ios(this)->base);
6156 /* Caution: basic_ostream uses virtual inheritance. */
6157 static inline basic_ios_wchar* basic_ostream_wchar_get_basic_ios(basic_ostream_wchar *this)
6159 return (basic_ios_wchar*)((char*)this+this->vbtable[1]);
6162 static inline basic_ios_wchar* basic_ostream_wchar_to_basic_ios(basic_ostream_wchar *ptr)
6164 return (basic_ios_wchar*)((char*)ptr+basic_ostream_wchar_vbtable[1]);
6167 static inline basic_ostream_wchar* basic_ostream_wchar_from_basic_ios(basic_ios_wchar *ptr)
6169 return (basic_ostream_wchar*)((char*)ptr-basic_ostream_wchar_vbtable[1]);
6172 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
6173 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
6174 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_ctor, 16)
6175 basic_ostream_wchar* __thiscall basic_ostream_wchar_ctor(basic_ostream_wchar *this,
6176 basic_streambuf_wchar *strbuf, MSVCP_bool isstd, MSVCP_bool virt_init)
6178 basic_ios_wchar *base;
6180 TRACE("(%p %p %d %d)\n", this, strbuf, isstd, virt_init);
6183 this->vbtable = basic_ostream_wchar_vbtable;
6184 base = basic_ostream_wchar_get_basic_ios(this);
6185 basic_ios_wchar_ctor(base);
6187 base = basic_ostream_wchar_get_basic_ios(this);
6190 base->base.vtable = &MSVCP_basic_ostream_wchar_vtable;
6191 basic_ios_wchar_init(base, strbuf, isstd);
6195 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
6196 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
6197 DEFINE_THISCALL_WRAPPER(basic_ostream_short_ctor, 16)
6198 basic_ostream_wchar* __thiscall basic_ostream_short_ctor(basic_ostream_wchar *this,
6199 basic_streambuf_wchar *strbuf, MSVCP_bool isstd, MSVCP_bool virt_init)
6201 basic_ostream_wchar_ctor(this, strbuf, isstd, virt_init);
6202 basic_ostream_wchar_get_basic_ios(this)->base.vtable = &MSVCP_basic_ostream_short_vtable;
6206 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
6207 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
6208 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_ctor_uninitialized, 16)
6209 basic_ostream_wchar* __thiscall basic_ostream_wchar_ctor_uninitialized(basic_ostream_wchar *this,
6210 int uninitialized, MSVCP_bool addstd, MSVCP_bool virt_init)
6212 basic_ios_wchar *base;
6214 TRACE("(%p %d %x)\n", this, uninitialized, addstd);
6217 this->vbtable = basic_ostream_wchar_vbtable;
6218 base = basic_ostream_wchar_get_basic_ios(this);
6219 basic_ios_wchar_ctor(base);
6221 base = basic_ostream_wchar_get_basic_ios(this);
6224 base->base.vtable = &MSVCP_basic_ostream_wchar_vtable;
6226 ios_base_Addstd(&base->base);
6230 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
6231 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
6232 DEFINE_THISCALL_WRAPPER(basic_ostream_short_ctor_uninitialized, 16)
6233 basic_ostream_wchar* __thiscall basic_ostream_short_ctor_uninitialized(basic_ostream_wchar *this,
6234 int uninitialized, MSVCP_bool addstd, MSVCP_bool virt_init)
6236 basic_ostream_wchar_ctor_uninitialized(this, uninitialized, addstd, virt_init);
6237 basic_ostream_wchar_get_basic_ios(this)->base.vtable = &MSVCP_basic_ostream_short_vtable;
6241 /* ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
6242 /* ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
6243 /* ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UAE@XZ */
6244 /* ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
6245 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_dtor, 4)
6246 void __thiscall basic_ostream_wchar_dtor(basic_ios_wchar *base)
6248 basic_ostream_wchar *this = basic_ostream_wchar_from_basic_ios(base);
6250 /* don't destroy virtual base here */
6251 TRACE("(%p)\n", this);
6254 /* ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
6255 /* ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
6256 /* ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
6257 /* ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
6258 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_vbase_dtor, 4)
6259 void __thiscall basic_ostream_wchar_vbase_dtor(basic_ostream_wchar *this)
6261 TRACE("(%p)\n", this);
6262 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(this));
6263 basic_ios_wchar_dtor(basic_ostream_wchar_get_basic_ios(this));
6266 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_vector_dtor, 8)
6267 basic_ostream_wchar* __thiscall basic_ostream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
6269 basic_ostream_wchar *this = basic_ostream_wchar_from_basic_ios(base);
6271 TRACE("(%p %x)\n", this, flags);
6274 /* we have an array, with the number of elements stored before the first object */
6275 INT_PTR i, *ptr = (INT_PTR *)this-1;
6277 for(i=*ptr-1; i>=0; i--)
6278 basic_ostream_wchar_vbase_dtor(this+i);
6279 MSVCRT_operator_delete(ptr);
6281 basic_ostream_wchar_vbase_dtor(this);
6283 MSVCRT_operator_delete(this);
6289 /* ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ */
6290 /* ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ */
6291 /* ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ */
6292 /* ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ */
6293 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_flush, 4)
6294 basic_ostream_wchar* __thiscall basic_ostream_wchar_flush(basic_ostream_wchar *this)
6296 /* this function is not matching C++ specification */
6297 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6299 TRACE("(%p)\n", this);
6301 if(basic_ios_wchar_rdbuf_get(base) && ios_base_good(&base->base)
6302 && basic_streambuf_wchar_pubsync(basic_ios_wchar_rdbuf_get(base))==-1)
6303 basic_ios_wchar_setstate(base, IOSTATE_badbit);
6307 /* ?flush@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
6308 /* ?flush@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
6309 /* ?flush@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
6310 /* ?flush@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
6311 basic_ostream_wchar* __cdecl flush_ostream_wchar(basic_ostream_wchar *ostream)
6313 return basic_ostream_wchar_flush(ostream);
6316 /* ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
6317 /* ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
6318 /* ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
6319 /* ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
6320 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar__Osfx, 4)
6321 void __thiscall basic_ostream_wchar__Osfx(basic_ostream_wchar *this)
6323 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6325 TRACE("(%p)\n", this);
6327 if(base->base.fmtfl & FMTFLAG_unitbuf)
6328 basic_ostream_wchar_flush(this);
6331 /* ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
6332 /* ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
6333 /* ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
6334 /* ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
6335 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_osfx, 4)
6336 void __thiscall basic_ostream_wchar_osfx(basic_ostream_wchar *this)
6338 TRACE("(%p)\n", this);
6339 basic_ostream_wchar__Osfx(this);
6342 static BOOL basic_ostream_wchar_sentry_create(basic_ostream_wchar *ostr)
6344 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(ostr);
6346 if(basic_ios_wchar_rdbuf_get(base))
6347 basic_streambuf_wchar__Lock(base->strbuf);
6349 if(ios_base_good(&base->base) && base->stream)
6350 basic_ostream_wchar_flush(base->stream);
6352 return ios_base_good(&base->base);
6355 static void basic_ostream_wchar_sentry_destroy(basic_ostream_wchar *ostr)
6357 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(ostr);
6359 if(ios_base_good(&base->base) && !__uncaught_exception())
6360 basic_ostream_wchar_osfx(ostr);
6362 if(basic_ios_wchar_rdbuf_get(base))
6363 basic_streambuf_wchar__Unlock(base->strbuf);
6366 /* ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE_NXZ */
6367 /* ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA_NXZ */
6368 /* ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE_NXZ */
6369 /* ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA_NXZ */
6370 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_opfx, 4)
6371 MSVCP_bool __thiscall basic_ostream_wchar_opfx(basic_ostream_wchar *this)
6373 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6375 TRACE("(%p)\n", this);
6377 if(ios_base_good(&base->base) && base->stream)
6378 basic_ostream_wchar_flush(base->stream);
6379 return ios_base_good(&base->base);
6382 /* ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z */
6383 /* ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z */
6384 /* ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z */
6385 /* ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z */
6386 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_put, 8)
6387 basic_ostream_wchar* __thiscall basic_ostream_wchar_put(basic_ostream_wchar *this, wchar_t ch)
6389 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6391 TRACE("(%p %c)\n", this, ch);
6393 if(!basic_ostream_wchar_sentry_create(this)
6394 || basic_streambuf_wchar_sputc(base->strbuf, ch)==WEOF) {
6395 basic_ostream_wchar_sentry_destroy(this);
6396 basic_ios_wchar_setstate(base, IOSTATE_badbit);
6400 basic_ostream_wchar_sentry_destroy(this);
6404 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@JH@Z */
6405 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z */
6406 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@JH@Z */
6407 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z */
6408 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp, 12)
6409 basic_ostream_wchar* __thiscall basic_ostream_wchar_seekp(basic_ostream_wchar *this, streamoff off, int way)
6411 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6413 TRACE("(%p %ld %d)\n", this, off, way);
6415 if(!ios_base_fail(&base->base)) {
6418 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base),
6419 &seek, off, way, OPENMODE_out);
6420 if(seek.off==0 && seek.pos==-1 && seek.state==0)
6421 basic_ios_wchar_setstate(base, IOSTATE_failbit);
6426 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
6427 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
6428 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
6429 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
6430 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp_fpos, 28)
6431 basic_ostream_wchar* __thiscall basic_ostream_wchar_seekp_fpos(basic_ostream_wchar *this, fpos_int pos)
6433 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6435 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos));
6437 if(!ios_base_fail(&base->base)) {
6440 basic_streambuf_wchar_pubseekpos(basic_ios_wchar_rdbuf_get(base),
6441 &seek, pos, OPENMODE_out);
6442 if(seek.off==0 && seek.pos==-1 && seek.state==0)
6443 basic_ios_wchar_setstate(base, IOSTATE_failbit);
6448 /* ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ */
6449 /* ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
6450 /* ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ */
6451 /* ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
6452 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_tellp, 8)
6453 fpos_int* __thiscall basic_ostream_wchar_tellp(basic_ostream_wchar *this, fpos_int *ret)
6455 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6457 TRACE("(%p)\n", this);
6459 if(!ios_base_fail(&base->base)) {
6460 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base),
6461 ret, 0, SEEKDIR_cur, OPENMODE_out);
6470 /* ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PB_WH@Z */
6471 /* ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEB_W_J@Z */
6472 /* ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@PBGH@Z */
6473 /* ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEBG_J@Z */
6474 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_write, 12)
6475 basic_ostream_wchar* __thiscall basic_ostream_wchar_write(basic_ostream_wchar *this, const wchar_t *str, streamsize count)
6477 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6479 TRACE("(%p %s %ld)\n", this, debugstr_w(str), count);
6481 if(!basic_ostream_wchar_sentry_create(this)
6482 || basic_streambuf_wchar_sputn(base->strbuf, str, count)!=count) {
6483 basic_ostream_wchar_sentry_destroy(this);
6484 basic_ios_wchar_setstate(base, IOSTATE_badbit);
6488 basic_ostream_wchar_sentry_destroy(this);
6492 static basic_ostream_wchar* basic_ostream_print_short(basic_ostream_wchar *this, short val, const num_put *numput)
6494 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6495 int state = IOSTATE_goodbit;
6497 TRACE("(%p %d)\n", this, val);
6499 if(basic_ostream_wchar_sentry_create(this)) {
6500 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6501 ostreambuf_iterator_wchar dest = {0, strbuf};
6503 num_put_wchar_put_long(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base),
6504 (ios_base_flags_get(&base->base) & FMTFLAG_basefield & (FMTFLAG_oct | FMTFLAG_hex))
6505 ? (LONG)((unsigned short)val) : (LONG)val);
6507 basic_ostream_wchar_sentry_destroy(this);
6509 basic_ios_wchar_setstate(base, state);
6513 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@F@Z */
6514 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@F@Z */
6515 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_short, 8)
6516 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_short(basic_ostream_wchar *this, short val)
6518 return basic_ostream_print_short(this, val, num_put_wchar_use_facet(
6519 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6522 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@F@Z */
6523 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@F@Z */
6524 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_short, 8)
6525 basic_ostream_wchar* __thiscall basic_ostream_short_print_short(basic_ostream_wchar *this, short val)
6527 return basic_ostream_print_short(this, val, num_put_short_use_facet(
6528 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6531 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@G@Z */
6532 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@G@Z */
6533 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ushort, 8)
6534 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_ushort(basic_ostream_wchar *this, unsigned short val)
6536 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6537 int state = IOSTATE_goodbit;
6539 TRACE("(%p %u)\n", this, val);
6541 if(basic_ostream_wchar_sentry_create(this)) {
6542 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6543 const num_put *numput = num_put_wchar_use_facet(strbuf->loc);
6544 ostreambuf_iterator_wchar dest = {0, strbuf};
6546 num_put_wchar_put_ulong(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6548 basic_ostream_wchar_sentry_destroy(this);
6550 basic_ios_wchar_setstate(base, state);
6554 static basic_ostream_wchar* basic_ostream_print_int(basic_ostream_wchar *this, int val, const num_put *numput)
6556 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6557 int state = IOSTATE_goodbit;
6559 TRACE("(%p %d)\n", this, val);
6561 if(basic_ostream_wchar_sentry_create(this)) {
6562 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6563 ostreambuf_iterator_wchar dest = {0, strbuf};
6565 num_put_wchar_put_long(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6567 basic_ostream_wchar_sentry_destroy(this);
6569 basic_ios_wchar_setstate(base, state);
6573 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@H@Z */
6574 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@H@Z */
6575 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@J@Z */
6576 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@J@Z */
6577 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_int, 8)
6578 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_int(basic_ostream_wchar *this, int val)
6580 return basic_ostream_print_int(this, val, num_put_wchar_use_facet(
6581 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6584 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@H@Z */
6585 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@H@Z */
6586 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@J@Z */
6587 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@J@Z */
6588 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_int, 8)
6589 basic_ostream_wchar* __thiscall basic_ostream_short_print_int(basic_ostream_wchar *this, int val)
6591 return basic_ostream_print_int(this, val, num_put_short_use_facet(
6592 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6595 static basic_ostream_wchar* basic_ostream_print_uint(basic_ostream_wchar *this, unsigned int val, const num_put *numput)
6597 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6598 int state = IOSTATE_goodbit;
6600 TRACE("(%p %u)\n", this, val);
6602 if(basic_ostream_wchar_sentry_create(this)) {
6603 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6604 ostreambuf_iterator_wchar dest = {0, strbuf};
6606 num_put_wchar_put_ulong(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6608 basic_ostream_wchar_sentry_destroy(this);
6610 basic_ios_wchar_setstate(base, state);
6614 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@I@Z */
6615 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@I@Z */
6616 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@K@Z */
6617 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@K@Z */
6618 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_uint, 8)
6619 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_uint(basic_ostream_wchar *this, unsigned int val)
6621 return basic_ostream_print_uint(this, val, num_put_wchar_use_facet(
6622 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6625 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@I@Z */
6626 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@I@Z */
6627 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@K@Z */
6628 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@K@Z */
6629 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_uint, 8)
6630 basic_ostream_wchar* __thiscall basic_ostream_short_print_uint(basic_ostream_wchar *this, unsigned int val)
6632 return basic_ostream_print_uint(this, val, num_put_short_use_facet(
6633 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6636 static basic_ostream_wchar* basic_ostream_print_float(basic_ostream_wchar *this, float val, const num_put *numput)
6638 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6639 int state = IOSTATE_goodbit;
6641 TRACE("(%p %f)\n", this, val);
6643 if(basic_ostream_wchar_sentry_create(this)) {
6644 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6645 ostreambuf_iterator_wchar dest = {0, strbuf};
6647 num_put_wchar_put_double(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6649 basic_ostream_wchar_sentry_destroy(this);
6651 basic_ios_wchar_setstate(base, state);
6655 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@M@Z */
6656 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@M@Z */
6657 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_float, 8)
6658 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_float(basic_ostream_wchar *this, float val)
6660 return basic_ostream_print_float(this, val, num_put_wchar_use_facet(
6661 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6664 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@M@Z */
6665 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@M@Z */
6666 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_float, 8)
6667 basic_ostream_wchar* __thiscall basic_ostream_short_print_float(basic_ostream_wchar *this, float val)
6669 return basic_ostream_print_float(this, val, num_put_short_use_facet(
6670 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6673 static basic_ostream_wchar* basic_ostream_print_double(basic_ostream_wchar *this, double val, const num_put *numput)
6675 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6676 int state = IOSTATE_goodbit;
6678 TRACE("(%p %lf)\n", this, val);
6680 if(basic_ostream_wchar_sentry_create(this)) {
6681 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6682 ostreambuf_iterator_wchar dest = {0, strbuf};
6684 num_put_wchar_put_double(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6686 basic_ostream_wchar_sentry_destroy(this);
6688 basic_ios_wchar_setstate(base, state);
6692 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@N@Z */
6693 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@N@Z */
6694 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_double, 12)
6695 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_double(basic_ostream_wchar *this, double val)
6697 return basic_ostream_print_double(this, val, num_put_wchar_use_facet(
6698 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6701 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@N@Z */
6702 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@N@Z */
6703 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_double, 12)
6704 basic_ostream_wchar* __thiscall basic_ostream_short_print_double(basic_ostream_wchar *this, double val)
6706 return basic_ostream_print_double(this, val, num_put_short_use_facet(
6707 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6710 static basic_ostream_wchar* basic_ostream_print_ldouble(basic_ostream_wchar *this, double val, const num_put *numput)
6712 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6713 int state = IOSTATE_goodbit;
6715 TRACE("(%p %lf)\n", this, val);
6717 if(basic_ostream_wchar_sentry_create(this)) {
6718 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6719 ostreambuf_iterator_wchar dest = {0, strbuf};
6721 num_put_wchar_put_ldouble(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6723 basic_ostream_wchar_sentry_destroy(this);
6725 basic_ios_wchar_setstate(base, state);
6729 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@O@Z */
6730 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@O@Z */
6731 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ldouble, 12)
6732 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_ldouble(basic_ostream_wchar *this, double val)
6734 return basic_ostream_print_ldouble(this, val, num_put_wchar_use_facet(
6735 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6738 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@O@Z */
6739 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@O@Z */
6740 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ldouble, 12)
6741 basic_ostream_wchar* __thiscall basic_ostream_short_print_ldouble(basic_ostream_wchar *this, double val)
6743 return basic_ostream_print_ldouble(this, val, num_put_short_use_facet(
6744 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6747 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
6748 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
6749 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
6750 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
6751 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_streambuf, 8)
6752 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_streambuf(basic_ostream_wchar *this, basic_streambuf_wchar *val)
6754 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6755 IOSB_iostate state = IOSTATE_badbit;
6756 unsigned short c = '\n';
6758 TRACE("(%p %p)\n", this, val);
6760 if(basic_ostream_wchar_sentry_create(this)) {
6761 for(c = basic_streambuf_wchar_sgetc(val); c!=WEOF;
6762 c = basic_streambuf_wchar_snextc(val)) {
6763 state = IOSTATE_goodbit;
6765 if(basic_streambuf_wchar_sputc(base->strbuf, c) == WEOF) {
6766 state = IOSTATE_badbit;
6771 state = IOSTATE_badbit;
6773 basic_ostream_wchar_sentry_destroy(this);
6775 ios_base_width_set(&base->base, 0);
6776 basic_ios_wchar_setstate(base, state);
6780 static basic_ostream_wchar* basic_ostream_print_ptr(basic_ostream_wchar *this, const void *val, const num_put *numput)
6782 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6783 int state = IOSTATE_goodbit;
6785 TRACE("(%p %p)\n", this, val);
6787 if(basic_ostream_wchar_sentry_create(this)) {
6788 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6789 ostreambuf_iterator_wchar dest = {0, strbuf};
6791 num_put_wchar_put_ptr(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6793 basic_ostream_wchar_sentry_destroy(this);
6795 basic_ios_wchar_setstate(base, state);
6799 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PBX@Z */
6800 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEBX@Z */
6801 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ptr, 8)
6802 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_ptr(basic_ostream_wchar *this, const void *val)
6804 return basic_ostream_print_ptr(this, val, num_put_wchar_use_facet(
6805 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6808 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PBX@Z */
6809 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEBX@Z */
6810 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ptr, 8)
6811 basic_ostream_wchar* __thiscall basic_ostream_short_print_ptr(basic_ostream_wchar *this, const void *val)
6813 return basic_ostream_print_ptr(this, val, num_put_short_use_facet(
6814 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6817 static basic_ostream_wchar* basic_ostream_print_int64(basic_ostream_wchar *this, __int64 val, const num_put *numput)
6819 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6820 int state = IOSTATE_goodbit;
6822 TRACE("(%p)\n", this);
6824 if(basic_ostream_wchar_sentry_create(this)) {
6825 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6826 ostreambuf_iterator_wchar dest = {0, strbuf};
6828 num_put_wchar_put_int64(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6830 basic_ostream_wchar_sentry_destroy(this);
6832 basic_ios_wchar_setstate(base, state);
6836 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_J@Z */
6837 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_J@Z */
6838 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_int64, 12)
6839 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_int64(basic_ostream_wchar *this, __int64 val)
6841 return basic_ostream_print_int64(this, val, num_put_wchar_use_facet(
6842 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6845 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_J@Z */
6846 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_J@Z */
6847 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_int64, 12)
6848 basic_ostream_wchar* __thiscall basic_ostream_short_print_int64(basic_ostream_wchar *this, __int64 val)
6850 return basic_ostream_print_int64(this, val, num_put_short_use_facet(
6851 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6854 static basic_ostream_wchar* basic_ostream_print_uint64(basic_ostream_wchar *this, unsigned __int64 val, const num_put *numput)
6856 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6857 int state = IOSTATE_goodbit;
6859 TRACE("(%p)\n", this);
6861 if(basic_ostream_wchar_sentry_create(this)) {
6862 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6863 ostreambuf_iterator_wchar dest = {0, strbuf};
6865 num_put_wchar_put_uint64(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6867 basic_ostream_wchar_sentry_destroy(this);
6869 basic_ios_wchar_setstate(base, state);
6873 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_K@Z */
6874 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_K@Z */
6875 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_uint64, 12)
6876 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_uint64(basic_ostream_wchar *this, unsigned __int64 val)
6878 return basic_ostream_print_uint64(this, val, num_put_wchar_use_facet(
6879 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6882 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_K@Z */
6883 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_K@Z */
6884 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_uint64, 12)
6885 basic_ostream_wchar* __thiscall basic_ostream_short_print_uint64(basic_ostream_wchar *this, unsigned __int64 val)
6887 return basic_ostream_print_uint64(this, val, num_put_short_use_facet(
6888 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6891 static basic_ostream_wchar* basic_ostream_print_bool(basic_ostream_wchar *this, MSVCP_bool val, const num_put *numput)
6893 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(this);
6894 int state = IOSTATE_goodbit;
6896 TRACE("(%p %x)\n", this, val);
6898 if(basic_ostream_wchar_sentry_create(this)) {
6899 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
6900 ostreambuf_iterator_wchar dest = {0, strbuf};
6902 num_put_wchar_put_bool(numput, &dest, dest, &base->base, basic_ios_wchar_fill_get(base), val);
6904 basic_ostream_wchar_sentry_destroy(this);
6906 basic_ios_wchar_setstate(base, state);
6910 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_N@Z */
6911 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_N@Z */
6912 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_bool, 8)
6913 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_bool(basic_ostream_wchar *this, MSVCP_bool val)
6915 return basic_ostream_print_bool(this, val, num_put_wchar_use_facet(
6916 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6919 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_N@Z */
6920 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_N@Z */
6921 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_bool, 8)
6922 basic_ostream_wchar* __thiscall basic_ostream_short_print_bool(basic_ostream_wchar *this, MSVCP_bool val)
6924 return basic_ostream_print_bool(this, val, num_put_short_use_facet(
6925 basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this))->loc));
6928 /* ?endl@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
6929 /* ?endl@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
6930 /* ?endl@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
6931 /* ?endl@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
6932 basic_ostream_wchar* __cdecl basic_ostream_wchar_endl(basic_ostream_wchar *ostr)
6934 TRACE("(%p)\n", ostr);
6936 basic_ostream_wchar_put(ostr, '\n');
6937 basic_ostream_wchar_flush(ostr);
6941 /* ??$?6_WU?$char_traits@_W@std@@V?$allocator@_W@1@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@@Z */
6942 /* ??$?6_WU?$char_traits@_W@std@@V?$allocator@_W@1@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@AEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@@Z */
6943 /* ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z */
6944 /* ??$?6GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z */
6945 basic_ostream_wchar* __cdecl basic_ostream_wchar_print_bstr(basic_ostream_wchar *ostr, const basic_string_wchar *str)
6947 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(ostr);
6948 IOSB_iostate state = IOSTATE_goodbit;
6950 TRACE("(%p %p)\n", ostr, str);
6952 if(basic_ostream_wchar_sentry_create(ostr)) {
6953 MSVCP_size_t len = MSVCP_basic_string_wchar_length(str);
6954 streamsize pad = (base->base.wide>len ? base->base.wide-len : 0);
6956 if((base->base.fmtfl & FMTFLAG_adjustfield) != FMTFLAG_left) {
6957 for(; pad!=0; pad--) {
6958 if(basic_streambuf_wchar_sputc(base->strbuf, base->fillch) == WEOF) {
6959 state = IOSTATE_badbit;
6965 if(state == IOSTATE_goodbit) {
6966 if(basic_streambuf_wchar_sputn(base->strbuf, MSVCP_basic_string_wchar_c_str(str), len) != len)
6967 state = IOSTATE_badbit;
6970 if(state == IOSTATE_goodbit) {
6971 for(; pad!=0; pad--) {
6972 if(basic_streambuf_wchar_sputc(base->strbuf, base->fillch) == WEOF) {
6973 state = IOSTATE_badbit;
6979 base->base.wide = 0;
6981 state = IOSTATE_badbit;
6983 basic_ostream_wchar_sentry_destroy(ostr);
6985 basic_ios_wchar_setstate(base, state);
6989 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@_W@Z */
6990 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@_W@Z */
6991 /* ??$?6GU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@G@Z */
6992 /* ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@G@Z */
6993 basic_ostream_wchar* __cdecl basic_ostream_wchar_print_ch(basic_ostream_wchar *ostr, wchar_t ch)
6995 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(ostr);
6996 IOSB_iostate state = IOSTATE_goodbit;
6998 TRACE("(%p %d)\n", ostr, ch);
7000 if(basic_ostream_wchar_sentry_create(ostr)) {
7001 streamsize pad = (base->base.wide>1 ? base->base.wide-1 : 0);
7003 if((base->base.fmtfl & FMTFLAG_adjustfield) != FMTFLAG_left) {
7004 for(; pad!=0; pad--) {
7005 if(basic_streambuf_wchar_sputc(base->strbuf, base->fillch) == WEOF) {
7006 state = IOSTATE_badbit;
7012 if(state == IOSTATE_goodbit) {
7013 if(basic_streambuf_wchar_sputc(base->strbuf, ch) == WEOF)
7014 state = IOSTATE_badbit;
7017 if(state == IOSTATE_goodbit) {
7018 for(; pad!=0; pad--) {
7019 if(basic_streambuf_wchar_sputc(base->strbuf, base->fillch) == WEOF) {
7020 state = IOSTATE_badbit;
7026 base->base.wide = 0;
7028 state = IOSTATE_badbit;
7030 basic_ostream_wchar_sentry_destroy(ostr);
7032 basic_ios_wchar_setstate(base, state);
7036 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@PB_W@Z */
7037 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@PEB_W@Z */
7038 /* ??$?6GU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@PBG@Z */
7039 /* ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@PEBG@Z */
7040 basic_ostream_wchar* __cdecl basic_ostream_wchar_print_str(basic_ostream_wchar *ostr, const wchar_t *str)
7042 basic_ios_wchar *base = basic_ostream_wchar_get_basic_ios(ostr);
7043 IOSB_iostate state = IOSTATE_goodbit;
7045 TRACE("(%p %s)\n", ostr, debugstr_w(str));
7047 if(basic_ostream_wchar_sentry_create(ostr)) {
7048 MSVCP_size_t len = wcslen(str);
7049 streamsize pad = (base->base.wide>len ? base->base.wide-len : 0);
7051 if((base->base.fmtfl & FMTFLAG_adjustfield) != FMTFLAG_left) {
7052 for(; pad!=0; pad--) {
7053 if(basic_streambuf_wchar_sputc(base->strbuf, base->fillch) == WEOF) {
7054 state = IOSTATE_badbit;
7060 if(state == IOSTATE_goodbit) {
7061 if(basic_streambuf_wchar_sputn(base->strbuf, str, len) != len)
7062 state = IOSTATE_badbit;
7065 if(state == IOSTATE_goodbit) {
7066 for(; pad!=0; pad--) {
7067 if(basic_streambuf_wchar_sputc(base->strbuf, base->fillch) == WEOF) {
7068 state = IOSTATE_badbit;
7074 base->base.wide = 0;
7076 state = IOSTATE_badbit;
7078 basic_ostream_wchar_sentry_destroy(ostr);
7080 basic_ios_wchar_setstate(base, state);
7084 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
7085 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
7086 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
7087 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
7088 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func, 8)
7089 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_func(basic_ostream_wchar *this,
7090 basic_ostream_wchar* (__cdecl *pfunc)(basic_ostream_wchar*))
7092 TRACE("(%p %p)\n", this, pfunc);
7097 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z */
7098 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z */
7099 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z */
7100 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z */
7101 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func_basic_ios, 8)
7102 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_func_basic_ios(basic_ostream_wchar *this,
7103 basic_ios_wchar* (__cdecl *pfunc)(basic_ios_wchar*))
7105 TRACE("(%p %p)\n", this, pfunc);
7106 pfunc(basic_ostream_wchar_get_basic_ios(this));
7110 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
7111 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
7112 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
7113 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
7114 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func_ios_base, 8)
7115 basic_ostream_wchar* __thiscall basic_ostream_wchar_print_func_ios_base(
7116 basic_ostream_wchar *this, ios_base* (__cdecl *pfunc)(ios_base*))
7118 TRACE("(%p %p)\n", this, pfunc);
7119 pfunc(&basic_ostream_wchar_get_basic_ios(this)->base);
7123 /* Caution: basic_istream uses virtual inheritance. */
7124 static inline basic_ios_char* basic_istream_char_get_basic_ios(basic_istream_char *this)
7126 return (basic_ios_char*)((char*)this+this->vbtable[1]);
7129 static inline basic_ios_char* basic_istream_char_to_basic_ios(basic_istream_char *ptr)
7131 return (basic_ios_char*)((char*)ptr+basic_istream_char_vbtable[1]);
7134 static inline basic_istream_char* basic_istream_char_from_basic_ios(basic_ios_char *ptr)
7136 return (basic_istream_char*)((char*)ptr-basic_istream_char_vbtable[1]);
7139 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z */
7140 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z */
7141 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor_init, 20)
7142 basic_istream_char* __thiscall basic_istream_char_ctor_init(basic_istream_char *this, basic_streambuf_char *strbuf, MSVCP_bool isstd, MSVCP_bool noinit, MSVCP_bool virt_init)
7144 basic_ios_char *base;
7146 TRACE("(%p %p %d %d %d)\n", this, strbuf, isstd, noinit, virt_init);
7149 this->vbtable = basic_istream_char_vbtable;
7150 base = basic_istream_char_get_basic_ios(this);
7151 basic_ios_char_ctor(base);
7153 base = basic_istream_char_get_basic_ios(this);
7156 base->base.vtable = &MSVCP_basic_istream_char_vtable;
7159 basic_ios_char_init(base, strbuf, isstd);
7163 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
7164 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
7165 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor, 16)
7166 basic_istream_char* __thiscall basic_istream_char_ctor(basic_istream_char *this, basic_streambuf_char *strbuf, MSVCP_bool isstd, MSVCP_bool virt_init)
7168 return basic_istream_char_ctor_init(this, strbuf, isstd, FALSE, virt_init);
7171 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z */
7172 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
7173 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor_uninitialized, 12)
7174 basic_istream_char* __thiscall basic_istream_char_ctor_uninitialized(basic_istream_char *this, int uninitialized, MSVCP_bool virt_init)
7176 basic_ios_char *base;
7178 TRACE("(%p %d %d)\n", this, uninitialized, virt_init);
7181 this->vbtable = basic_istream_char_vbtable;
7182 base = basic_istream_char_get_basic_ios(this);
7183 basic_ios_char_ctor(base);
7185 base = basic_istream_char_get_basic_ios(this);
7188 base->base.vtable = &MSVCP_basic_istream_char_vtable;
7189 ios_base_Addstd(&base->base);
7193 /* ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UAE@XZ */
7194 /* ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
7195 DEFINE_THISCALL_WRAPPER(basic_istream_char_dtor, 4)
7196 void __thiscall basic_istream_char_dtor(basic_ios_char *base)
7198 basic_istream_char *this = basic_istream_char_from_basic_ios(base);
7200 /* don't destroy virtual base here */
7201 TRACE("(%p)\n", this);
7204 /* ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ */
7205 /* ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
7206 DEFINE_THISCALL_WRAPPER(basic_istream_char_vbase_dtor, 4)
7207 void __thiscall basic_istream_char_vbase_dtor(basic_istream_char *this)
7209 TRACE("(%p)\n", this);
7210 basic_istream_char_dtor(basic_istream_char_to_basic_ios(this));
7211 basic_ios_char_dtor(basic_istream_char_get_basic_ios(this));
7214 DEFINE_THISCALL_WRAPPER(basic_istream_char_vector_dtor, 8)
7215 basic_istream_char* __thiscall basic_istream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
7217 basic_istream_char *this = basic_istream_char_from_basic_ios(base);
7219 TRACE("(%p %x)\n", this, flags);
7222 /* we have an array, with the number of elements stored before the first object */
7223 INT_PTR i, *ptr = (INT_PTR *)this-1;
7225 for(i=*ptr-1; i>=0; i--)
7226 basic_istream_char_vbase_dtor(this+i);
7227 MSVCRT_operator_delete(ptr);
7229 basic_istream_char_vbase_dtor(this);
7231 MSVCRT_operator_delete(this);
7237 /* ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z */
7238 /* ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z */
7239 DEFINE_THISCALL_WRAPPER(basic_istream_char__Ipfx, 8)
7240 MSVCP_bool __thiscall basic_istream_char__Ipfx(basic_istream_char *this, MSVCP_bool noskip)
7242 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7244 TRACE("(%p %d)\n", this, noskip);
7246 if(!ios_base_good(&base->base)) {
7247 basic_ios_char_setstate(base, IOSTATE_failbit);
7251 if(basic_ios_char_tie_get(base))
7252 basic_ostream_char_flush(basic_ios_char_tie_get(base));
7254 if(!noskip && (ios_base_flags_get(&base->base) & FMTFLAG_skipws)) {
7255 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7256 const ctype_char *ctype = ctype_char_use_facet(base->strbuf->loc);
7259 for(ch = basic_streambuf_char_sgetc(strbuf); ;
7260 ch = basic_streambuf_char_snextc(strbuf)) {
7262 basic_ios_char_setstate(base, IOSTATE_eofbit);
7266 if(!ctype_char_is_ch(ctype, _SPACE|_BLANK, ch))
7274 /* ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z */
7275 /* ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z */
7276 DEFINE_THISCALL_WRAPPER(basic_istream_char_ipfx, 8)
7277 MSVCP_bool __thiscall basic_istream_char_ipfx(basic_istream_char *this, MSVCP_bool noskip)
7279 return basic_istream_char__Ipfx(this, noskip);
7282 /* ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ */
7283 /* ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
7284 DEFINE_THISCALL_WRAPPER(basic_istream_char_isfx, 4)
7285 void __thiscall basic_istream_char_isfx(basic_istream_char *this)
7287 TRACE("(%p)\n", this);
7290 static BOOL basic_istream_char_sentry_create(basic_istream_char *istr, MSVCP_bool noskip)
7292 basic_ios_char *base = basic_istream_char_get_basic_ios(istr);
7294 if(basic_ios_char_rdbuf_get(base))
7295 basic_streambuf_char__Lock(base->strbuf);
7297 return basic_istream_char_ipfx(istr, noskip);
7300 static void basic_istream_char_sentry_destroy(basic_istream_char *istr)
7302 basic_ios_char *base = basic_istream_char_get_basic_ios(istr);
7304 if(basic_ios_char_rdbuf_get(base))
7305 basic_streambuf_char__Unlock(base->strbuf);
7308 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBEHXZ */
7309 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QEBA_JXZ */
7310 DEFINE_THISCALL_WRAPPER(basic_istream_char_gcount, 4)
7311 int __thiscall basic_istream_char_gcount(const basic_istream_char *this)
7313 TRACE("(%p)\n", this);
7317 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
7318 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
7319 DEFINE_THISCALL_WRAPPER(basic_istream_char_get, 4)
7320 int __thiscall basic_istream_char_get(basic_istream_char *this)
7322 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7325 TRACE("(%p)\n", this);
7329 if(!basic_istream_char_sentry_create(this, TRUE)) {
7330 basic_istream_char_sentry_destroy(this);
7334 ret = basic_streambuf_char_sbumpc(basic_ios_char_rdbuf_get(base));
7335 basic_istream_char_sentry_destroy(this);
7337 basic_ios_char_setstate(base, IOSTATE_eofbit|IOSTATE_failbit);
7344 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAD@Z */
7345 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAD@Z */
7346 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_ch, 8)
7347 basic_istream_char* __thiscall basic_istream_char_get_ch(basic_istream_char *this, char *ch)
7351 TRACE("(%p %p)\n", this, ch);
7353 ret = basic_istream_char_get(this);
7359 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADHD@Z */
7360 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z */
7361 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str_delim, 16)
7362 basic_istream_char* __thiscall basic_istream_char_get_str_delim(basic_istream_char *this, char *str, streamsize count, char delim)
7364 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7367 TRACE("(%p %p %ld %c)\n", this, str, count, delim);
7371 if(basic_istream_char_sentry_create(this, TRUE)) {
7372 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7374 for(ch = basic_streambuf_char_sgetc(strbuf); count>1;
7375 ch = basic_streambuf_char_snextc(strbuf)) {
7376 if(ch==EOF || ch==delim)
7384 basic_istream_char_sentry_destroy(this);
7386 basic_ios_char_setstate(base, (!this->count ? IOSTATE_failbit : IOSTATE_goodbit) |
7387 (ch==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
7393 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
7394 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
7395 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str, 12)
7396 basic_istream_char* __thiscall basic_istream_char_get_str(basic_istream_char *this, char *str, streamsize count)
7398 return basic_istream_char_get_str_delim(this, str, count, '\n');
7401 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z */
7402 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z */
7403 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_streambuf_delim, 12)
7404 basic_istream_char* __thiscall basic_istream_char_get_streambuf_delim(basic_istream_char *this, basic_streambuf_char *strbuf, char delim)
7406 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7409 TRACE("(%p %p %c)\n", this, strbuf, delim);
7413 if(basic_istream_char_sentry_create(this, TRUE)) {
7414 basic_streambuf_char *strbuf_read = basic_ios_char_rdbuf_get(base);
7416 for(ch = basic_streambuf_char_sgetc(strbuf_read); ;
7417 ch = basic_streambuf_char_snextc(strbuf_read)) {
7418 if(ch==EOF || ch==delim)
7421 if(basic_streambuf_char_sputc(strbuf, ch) == EOF)
7426 basic_istream_char_sentry_destroy(this);
7428 basic_ios_char_setstate(base, (!this->count ? IOSTATE_failbit : IOSTATE_goodbit) |
7429 (ch==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
7433 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z */
7434 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z */
7435 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_streambuf, 8)
7436 basic_istream_char* __thiscall basic_istream_char_get_streambuf(basic_istream_char *this, basic_streambuf_char *strbuf)
7438 return basic_istream_char_get_streambuf_delim(this, strbuf, '\n');
7441 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADHD@Z */
7442 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z */
7443 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline_delim, 16)
7444 basic_istream_char* __thiscall basic_istream_char_getline_delim(basic_istream_char *this, char *str, streamsize count, char delim)
7446 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7449 TRACE("(%p %p %ld %c)\n", this, str, count, delim);
7453 if(basic_istream_char_sentry_create(this, TRUE) && count>0) {
7454 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7457 ch = basic_streambuf_char_sbumpc(strbuf);
7459 if(ch==EOF || ch==delim)
7469 else if(ch != EOF) {
7470 ch = basic_streambuf_char_sgetc(strbuf);
7473 basic_streambuf_char__Gninc(strbuf);
7478 basic_istream_char_sentry_destroy(this);
7480 basic_ios_char_setstate(base, (ch==EOF ? IOSTATE_eofbit : IOSTATE_goodbit) |
7481 (!this->count || (ch!=delim && ch!=EOF) ? IOSTATE_failbit : IOSTATE_goodbit));
7487 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
7488 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
7489 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline, 12)
7490 basic_istream_char* __thiscall basic_istream_char_getline(basic_istream_char *this, char *str, streamsize count)
7492 return basic_istream_char_getline_delim(this, str, count, '\n');
7495 /* ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@HH@Z */
7496 /* ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
7497 DEFINE_THISCALL_WRAPPER(basic_istream_char_ignore, 12)
7498 basic_istream_char* __thiscall basic_istream_char_ignore(basic_istream_char *this, streamsize count, int delim)
7500 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7503 TRACE("(%p %ld %d)\n", this, count, delim);
7507 if(basic_istream_char_sentry_create(this, TRUE)) {
7508 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7511 ch = basic_streambuf_char_sbumpc(strbuf);
7513 if(ch==EOF || ch==delim)
7517 if(count != INT_MAX)
7521 basic_istream_char_sentry_destroy(this);
7524 basic_ios_char_setstate(base, IOSTATE_eofbit);
7528 /* ?ws@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@1@AAV21@@Z */
7529 /* ?ws@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
7530 basic_istream_char* __cdecl ws_basic_istream_char(basic_istream_char *istream)
7532 basic_ios_char *base = basic_istream_char_get_basic_ios(istream);
7535 TRACE("(%p)\n", istream);
7537 if(basic_istream_char_sentry_create(istream, TRUE)) {
7538 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7539 const ctype_char *ctype = ctype_char_use_facet(strbuf->loc);
7541 for(ch = basic_streambuf_char_sgetc(strbuf); ctype_char_is_ch(ctype, _SPACE, ch);
7542 ch = basic_streambuf_char_snextc(strbuf)) {
7547 basic_istream_char_sentry_destroy(istream);
7550 basic_ios_char_setstate(base, IOSTATE_eofbit);
7554 /* ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
7555 /* ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
7556 DEFINE_THISCALL_WRAPPER(basic_istream_char_peek, 4)
7557 int __thiscall basic_istream_char_peek(basic_istream_char *this)
7559 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7562 TRACE("(%p)\n", this);
7566 if(basic_istream_char_sentry_create(this, TRUE))
7567 ret = basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base));
7568 basic_istream_char_sentry_destroy(this);
7572 /* ?_Read_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADIH@Z */
7573 /* ?_Read_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_K_J@Z */
7574 DEFINE_THISCALL_WRAPPER(basic_istream_char__Read_s, 16)
7575 basic_istream_char* __thiscall basic_istream_char__Read_s(basic_istream_char *this, char *str, MSVCP_size_t size, streamsize count)
7577 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7578 IOSB_iostate state = IOSTATE_goodbit;
7580 TRACE("(%p %p %lu %ld)\n", this, str, size, count);
7582 if(basic_istream_char_sentry_create(this, TRUE)) {
7583 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7585 this->count = basic_streambuf_char__Sgetn_s(strbuf, str, size, count);
7586 if(this->count != count)
7587 state |= IOSTATE_failbit | IOSTATE_eofbit;
7591 basic_istream_char_sentry_destroy(this);
7593 basic_ios_char_setstate(base, state);
7597 /* ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
7598 /* ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
7599 DEFINE_THISCALL_WRAPPER(basic_istream_char_read, 12)
7600 basic_istream_char* __thiscall basic_istream_char_read(basic_istream_char *this, char *str, streamsize count)
7602 return basic_istream_char__Read_s(this, str, count, count);
7605 /* ?_Readsome_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHPADIH@Z */
7606 /* ?_Readsome_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_K_J@Z */
7607 DEFINE_THISCALL_WRAPPER(basic_istream_char__Readsome_s, 16)
7608 streamsize __thiscall basic_istream_char__Readsome_s(basic_istream_char *this, char *str, MSVCP_size_t size, streamsize count)
7610 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7611 IOSB_iostate state = IOSTATE_goodbit;
7613 TRACE("(%p %p %lu %ld)\n", this, str, size, count);
7617 if(basic_istream_char_sentry_create(this, TRUE)) {
7618 streamsize avail = basic_streambuf_char_in_avail(basic_ios_char_rdbuf_get(base));
7623 state |= IOSTATE_eofbit;
7625 basic_istream_char__Read_s(this, str, size, avail);
7627 state |= IOSTATE_failbit;
7629 basic_istream_char_sentry_destroy(this);
7631 basic_ios_char_setstate(base, state);
7635 /* ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHPADH@Z */
7636 /* ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z */
7637 DEFINE_THISCALL_WRAPPER(basic_istream_char_readsome, 12)
7638 streamsize __thiscall basic_istream_char_readsome(basic_istream_char *this, char *str, streamsize count)
7640 return basic_istream_char__Readsome_s(this, str, count, count);
7643 /* ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z */
7644 /* ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z */
7645 DEFINE_THISCALL_WRAPPER(basic_istream_char_putback, 8)
7646 basic_istream_char* __thiscall basic_istream_char_putback(basic_istream_char *this, char ch)
7648 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7649 IOSB_iostate state = IOSTATE_goodbit;
7651 TRACE("(%p %c)\n", this, ch);
7655 if(basic_istream_char_sentry_create(this, TRUE)) {
7656 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7658 if(!ios_base_good(&base->base))
7659 state |= IOSTATE_failbit;
7660 else if(!strbuf || basic_streambuf_char_sputbackc(strbuf, ch)==EOF)
7661 state |= IOSTATE_badbit;
7663 basic_istream_char_sentry_destroy(this);
7665 basic_ios_char_setstate(base, state);
7669 /* ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ */
7670 /* ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ */
7671 DEFINE_THISCALL_WRAPPER(basic_istream_char_unget, 4)
7672 basic_istream_char* __thiscall basic_istream_char_unget(basic_istream_char *this)
7674 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7675 IOSB_iostate state = IOSTATE_goodbit;
7677 TRACE("(%p)\n", this);
7681 if(basic_istream_char_sentry_create(this, TRUE)) {
7682 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7684 if(!ios_base_good(&base->base))
7685 state |= IOSTATE_failbit;
7686 else if(!strbuf || basic_streambuf_char_sungetc(strbuf)==EOF)
7687 state |= IOSTATE_badbit;
7689 basic_istream_char_sentry_destroy(this);
7691 basic_ios_char_setstate(base, state);
7695 /* ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
7696 /* ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
7697 DEFINE_THISCALL_WRAPPER(basic_istream_char_sync, 4)
7698 int __thiscall basic_istream_char_sync(basic_istream_char *this)
7700 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7701 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7703 TRACE("(%p)\n", this);
7708 if(basic_istream_char_sentry_create(this, TRUE)) {
7709 if(basic_streambuf_char_pubsync(strbuf) != -1) {
7710 basic_istream_char_sentry_destroy(this);
7714 basic_istream_char_sentry_destroy(this);
7716 basic_ios_char_setstate(base, IOSTATE_badbit);
7720 /* ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ */
7721 /* ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
7722 DEFINE_THISCALL_WRAPPER(basic_istream_char_tellg, 8)
7723 fpos_int* __thiscall basic_istream_char_tellg(basic_istream_char *this, fpos_int *ret)
7725 TRACE("(%p %p)\n", this, ret);
7727 if(basic_istream_char_sentry_create(this, TRUE)) {
7728 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7729 if(!ios_base_fail(&base->base)) {
7730 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base),
7731 ret, 0, SEEKDIR_cur, OPENMODE_in);
7732 basic_istream_char_sentry_destroy(this);
7734 if(ret->off==0 && ret->pos==-1 && ret->state==0)
7735 basic_ios_char_setstate(base, IOSTATE_failbit);
7739 basic_istream_char_sentry_destroy(this);
7747 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@JH@Z */
7748 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
7749 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg, 12)
7750 basic_istream_char* __thiscall basic_istream_char_seekg(basic_istream_char *this, streamoff off, int dir)
7752 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7754 TRACE("(%p %ld %d)\n", this, off, dir);
7756 if(basic_istream_char_sentry_create(this, TRUE)) {
7757 if(!ios_base_fail(&base->base)) {
7758 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7761 basic_streambuf_char_pubseekoff(strbuf, &ret, off, dir, OPENMODE_in);
7762 basic_istream_char_sentry_destroy(this);
7764 if(ret.off==0 && ret.pos==-1 && ret.state==0)
7765 basic_ios_char_setstate(base, IOSTATE_failbit);
7767 basic_ios_char_clear(base, IOSTATE_goodbit);
7771 basic_istream_char_sentry_destroy(this);
7773 basic_ios_char_setstate(base, IOSTATE_failbit);
7777 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
7778 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
7779 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg_fpos, 28)
7780 basic_istream_char* __thiscall basic_istream_char_seekg_fpos(basic_istream_char *this, fpos_int pos)
7782 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7784 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos));
7786 if(basic_istream_char_sentry_create(this, TRUE)) {
7787 if(!ios_base_fail(&base->base)) {
7788 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7791 basic_streambuf_char_pubseekpos(strbuf, &ret, pos, OPENMODE_in);
7792 basic_istream_char_sentry_destroy(this);
7794 if(ret.off==0 && ret.pos==-1 && ret.state==0)
7795 basic_ios_char_setstate(base, IOSTATE_failbit);
7797 basic_ios_char_clear(base, IOSTATE_goodbit);
7801 basic_istream_char_sentry_destroy(this);
7803 basic_ios_char_setstate(base, IOSTATE_failbit);
7807 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAF@Z */
7808 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAF@Z */
7809 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_short, 8)
7810 basic_istream_char* __thiscall basic_istream_char_read_short(basic_istream_char *this, short *v)
7812 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7813 int state = IOSTATE_goodbit;
7815 TRACE("(%p %p)\n", this, v);
7817 if(basic_istream_char_sentry_create(this, FALSE)) {
7818 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7819 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7820 istreambuf_iterator_char first={0}, last={0};
7823 first.strbuf = strbuf;
7824 num_get_char_get_long(numget, &last, first, last, &base->base, &state, &tmp);
7826 if(!(state&IOSTATE_failbit) && tmp==(LONG)((short)tmp))
7829 state |= IOSTATE_failbit;
7831 basic_istream_char_sentry_destroy(this);
7833 basic_ios_char_setstate(base, state);
7837 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAG@Z */
7838 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAG@Z */
7839 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ushort, 8)
7840 basic_istream_char* __thiscall basic_istream_char_read_ushort(basic_istream_char *this, unsigned short *v)
7842 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7843 int state = IOSTATE_goodbit;
7845 TRACE("(%p %p)\n", this, v);
7847 if(basic_istream_char_sentry_create(this, FALSE)) {
7848 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7849 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7850 istreambuf_iterator_char first={0}, last={0};
7852 first.strbuf = strbuf;
7853 num_get_char_get_ushort(numget, &last, first, last, &base->base, &state, v);
7855 basic_istream_char_sentry_destroy(this);
7857 basic_ios_char_setstate(base, state);
7861 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAH@Z */
7862 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAH@Z */
7863 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_int, 8)
7864 basic_istream_char* __thiscall basic_istream_char_read_int(basic_istream_char *this, int *v)
7866 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7867 int state = IOSTATE_goodbit;
7869 TRACE("(%p %p)\n", this, v);
7871 if(basic_istream_char_sentry_create(this, FALSE)) {
7872 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7873 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7874 istreambuf_iterator_char first={0}, last={0};
7876 first.strbuf = strbuf;
7877 num_get_char_get_long(numget, &last, first, last, &base->base, &state, v);
7879 basic_istream_char_sentry_destroy(this);
7881 basic_ios_char_setstate(base, state);
7885 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAI@Z */
7886 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAI@Z */
7887 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_uint, 8)
7888 basic_istream_char* __thiscall basic_istream_char_read_uint(basic_istream_char *this, unsigned int *v)
7890 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7891 int state = IOSTATE_goodbit;
7893 TRACE("(%p %p)\n", this, v);
7895 if(basic_istream_char_sentry_create(this, FALSE)) {
7896 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7897 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7898 istreambuf_iterator_char first={0}, last={0};
7900 first.strbuf = strbuf;
7901 num_get_char_get_uint(numget, &last, first, last, &base->base, &state, v);
7903 basic_istream_char_sentry_destroy(this);
7905 basic_ios_char_setstate(base, state);
7909 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAJ@Z */
7910 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAJ@Z */
7911 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_long, 8)
7912 basic_istream_char* __thiscall basic_istream_char_read_long(basic_istream_char *this, LONG *v)
7914 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7915 int state = IOSTATE_goodbit;
7917 TRACE("(%p %p)\n", this, v);
7919 if(basic_istream_char_sentry_create(this, FALSE)) {
7920 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7921 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7922 istreambuf_iterator_char first={0}, last={0};
7924 first.strbuf = strbuf;
7925 num_get_char_get_long(numget, &last, first, last, &base->base, &state, v);
7927 basic_istream_char_sentry_destroy(this);
7929 basic_ios_char_setstate(base, state);
7933 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAK@Z */
7934 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAK@Z */
7935 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ulong, 8)
7936 basic_istream_char* __thiscall basic_istream_char_read_ulong(basic_istream_char *this, ULONG *v)
7938 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7939 int state = IOSTATE_goodbit;
7941 TRACE("(%p %p)\n", this, v);
7943 if(basic_istream_char_sentry_create(this, FALSE)) {
7944 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7945 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7946 istreambuf_iterator_char first={0}, last={0};
7948 first.strbuf = strbuf;
7949 num_get_char_get_ulong(numget, &last, first, last, &base->base, &state, v);
7951 basic_istream_char_sentry_destroy(this);
7953 basic_ios_char_setstate(base, state);
7957 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAM@Z */
7958 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAM@Z */
7959 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_float, 8)
7960 basic_istream_char* __thiscall basic_istream_char_read_float(basic_istream_char *this, float *v)
7962 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7963 int state = IOSTATE_goodbit;
7965 TRACE("(%p %p)\n", this, v);
7967 if(basic_istream_char_sentry_create(this, FALSE)) {
7968 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7969 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7970 istreambuf_iterator_char first={0}, last={0};
7972 first.strbuf = strbuf;
7973 num_get_char_get_float(numget, &last, first, last, &base->base, &state, v);
7975 basic_istream_char_sentry_destroy(this);
7977 basic_ios_char_setstate(base, state);
7981 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAN@Z */
7982 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAN@Z */
7983 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_double, 8)
7984 basic_istream_char* __thiscall basic_istream_char_read_double(basic_istream_char *this, double *v)
7986 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
7987 int state = IOSTATE_goodbit;
7989 TRACE("(%p %p)\n", this, v);
7991 if(basic_istream_char_sentry_create(this, FALSE)) {
7992 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
7993 const num_get *numget = num_get_char_use_facet(strbuf->loc);
7994 istreambuf_iterator_char first={0}, last={0};
7996 first.strbuf = strbuf;
7997 num_get_char_get_double(numget, &last, first, last, &base->base, &state, v);
7999 basic_istream_char_sentry_destroy(this);
8001 basic_ios_char_setstate(base, state);
8005 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAO@Z */
8006 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAO@Z */
8007 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ldouble, 8)
8008 basic_istream_char* __thiscall basic_istream_char_read_ldouble(basic_istream_char *this, double *v)
8010 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
8011 int state = IOSTATE_goodbit;
8013 TRACE("(%p %p)\n", this, v);
8015 if(basic_istream_char_sentry_create(this, FALSE)) {
8016 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
8017 const num_get *numget = num_get_char_use_facet(strbuf->loc);
8018 istreambuf_iterator_char first={0}, last={0};
8020 first.strbuf = strbuf;
8021 num_get_char_get_ldouble(numget, &last, first, last, &base->base, &state, v);
8023 basic_istream_char_sentry_destroy(this);
8025 basic_ios_char_setstate(base, state);
8029 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAPAX@Z */
8030 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
8031 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ptr, 8)
8032 basic_istream_char* __thiscall basic_istream_char_read_ptr(basic_istream_char *this, void **v)
8034 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
8035 int state = IOSTATE_goodbit;
8037 TRACE("(%p %p)\n", this, v);
8039 if(basic_istream_char_sentry_create(this, FALSE)) {
8040 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
8041 const num_get *numget = num_get_char_use_facet(strbuf->loc);
8042 istreambuf_iterator_char first={0}, last={0};
8044 first.strbuf = strbuf;
8045 num_get_char_get_void(numget, &last, first, last, &base->base, &state, v);
8047 basic_istream_char_sentry_destroy(this);
8049 basic_ios_char_setstate(base, state);
8053 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_J@Z */
8054 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_J@Z */
8055 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_int64, 8)
8056 basic_istream_char* __thiscall basic_istream_char_read_int64(basic_istream_char *this, __int64 *v)
8058 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
8059 int state = IOSTATE_goodbit;
8061 TRACE("(%p %p)\n", this, v);
8063 if(basic_istream_char_sentry_create(this, FALSE)) {
8064 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
8065 const num_get *numget = num_get_char_use_facet(strbuf->loc);
8066 istreambuf_iterator_char first={0}, last={0};
8068 first.strbuf = strbuf;
8069 num_get_char_get_int64(numget, &last, first, last, &base->base, &state, v);
8071 basic_istream_char_sentry_destroy(this);
8073 basic_ios_char_setstate(base, state);
8077 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_K@Z */
8078 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_K@Z */
8079 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_uint64, 8)
8080 basic_istream_char* __thiscall basic_istream_char_read_uint64(basic_istream_char *this, unsigned __int64 *v)
8082 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
8083 int state = IOSTATE_goodbit;
8085 TRACE("(%p %p)\n", this, v);
8087 if(basic_istream_char_sentry_create(this, FALSE)) {
8088 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
8089 const num_get *numget = num_get_char_use_facet(strbuf->loc);
8090 istreambuf_iterator_char first={0}, last={0};
8092 first.strbuf = strbuf;
8093 num_get_char_get_uint64(numget, &last, first, last, &base->base, &state, v);
8095 basic_istream_char_sentry_destroy(this);
8097 basic_ios_char_setstate(base, state);
8101 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_N@Z */
8102 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_N@Z */
8103 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_bool, 8)
8104 basic_istream_char* __thiscall basic_istream_char_read_bool(basic_istream_char *this, MSVCP_bool *v)
8106 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
8107 int state = IOSTATE_goodbit;
8109 TRACE("(%p %p)\n", this, v);
8111 if(basic_istream_char_sentry_create(this, FALSE)) {
8112 basic_streambuf_char *strbuf = basic_ios_char_rdbuf_get(base);
8113 const num_get *numget = num_get_char_use_facet(strbuf->loc);
8114 istreambuf_iterator_char first={0}, last={0};
8116 first.strbuf = strbuf;
8117 num_get_char_get_bool(numget, &last, first, last, &base->base, &state, v);
8119 basic_istream_char_sentry_destroy(this);
8121 basic_ios_char_setstate(base, state);
8125 /* ??$getline@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@D@Z */
8126 /* ??$getline@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@D@Z */
8127 basic_istream_char* __cdecl basic_istream_char_getline_bstr_delim(
8128 basic_istream_char *istream, basic_string_char *str, char delim)
8130 IOSB_iostate state = IOSTATE_failbit;
8133 TRACE("(%p %p %c)\n", istream, str, delim);
8135 if(basic_istream_char_sentry_create(istream, TRUE)) {
8136 MSVCP_basic_string_char_clear(str);
8138 c = basic_istream_char_get(istream);
8140 state = IOSTATE_goodbit;
8142 for(; c!=delim && c!=EOF; c = basic_istream_char_get(istream)) {
8143 state = IOSTATE_goodbit;
8144 MSVCP_basic_string_char_append_ch(str, c);
8147 basic_istream_char_sentry_destroy(istream);
8149 basic_ios_char_setstate(basic_istream_char_get_basic_ios(istream),
8150 state | (c==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8154 /* ??$getline@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@@Z */
8155 /* ??$getline@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@@Z */
8156 basic_istream_char* __cdecl basic_istream_char_getline_bstr(
8157 basic_istream_char *istream, basic_string_char *str)
8159 return basic_istream_char_getline_bstr_delim(istream, str, '\n');
8162 /* ??$?5DU?$char_traits@D@std@@V?$allocator@D@1@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@@Z */
8163 /* ??$?5DU?$char_traits@D@std@@V?$allocator@D@1@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@0@@Z */
8164 basic_istream_char* __cdecl basic_istream_char_read_bstr(
8165 basic_istream_char *istream, basic_string_char *str)
8167 basic_ios_char *base = basic_istream_char_get_basic_ios(istream);
8168 IOSB_iostate state = IOSTATE_failbit;
8171 TRACE("(%p %p)\n", istream, str);
8173 if(basic_istream_char_sentry_create(istream, FALSE)) {
8174 const ctype_char *ctype = ctype_char_use_facet(base->strbuf->loc);
8175 MSVCP_size_t count = ios_base_width_get(&base->base);
8180 MSVCP_basic_string_char_clear(str);
8182 for(c = basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base));
8183 c!=EOF && !ctype_char_is_ch(ctype, _SPACE|_BLANK, c) && count>0;
8184 c = basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base)), count--) {
8185 state = IOSTATE_goodbit;
8186 MSVCP_basic_string_char_append_ch(str, c);
8189 basic_istream_char_sentry_destroy(istream);
8191 ios_base_width_set(&base->base, 0);
8192 basic_ios_char_setstate(base, state | (c==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8196 /* ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAD@Z */
8197 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAD@Z */
8198 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAC@Z */
8199 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAC@Z */
8200 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAE@Z */
8201 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAE@Z */
8202 basic_istream_char* __cdecl basic_istream_char_read_str(basic_istream_char *istream, char *str)
8204 basic_ios_char *base = basic_istream_char_get_basic_ios(istream);
8205 IOSB_iostate state = IOSTATE_failbit;
8208 TRACE("(%p %p)\n", istream, str);
8210 if(basic_istream_char_sentry_create(istream, FALSE)) {
8211 const ctype_char *ctype = ctype_char_use_facet(base->strbuf->loc);
8212 MSVCP_size_t count = ios_base_width_get(&base->base)-1;
8214 for(c = basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base));
8215 c!=EOF && !ctype_char_is_ch(ctype, _SPACE|_BLANK, c) && count>0;
8216 c = basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base)), count--) {
8217 state = IOSTATE_goodbit;
8221 basic_istream_char_sentry_destroy(istream);
8224 ios_base_width_set(&base->base, 0);
8225 basic_ios_char_setstate(base, state | (c==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8229 /* ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAD@Z */
8230 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAD@Z */
8231 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAC@Z */
8232 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAC@Z */
8233 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAE@Z */
8234 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAE@Z */
8235 basic_istream_char* __cdecl basic_istream_char_read_ch(basic_istream_char *istream, char *ch)
8237 IOSB_iostate state = IOSTATE_failbit;
8240 TRACE("(%p %p)\n", istream, ch);
8242 if(basic_istream_char_sentry_create(istream, FALSE)) {
8243 c = basic_streambuf_char_sbumpc(basic_ios_char_rdbuf_get(
8244 basic_istream_char_get_basic_ios(istream)));
8246 state = IOSTATE_goodbit;
8250 basic_istream_char_sentry_destroy(istream);
8252 basic_ios_char_setstate(basic_istream_char_get_basic_ios(istream),
8253 state | (c==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8257 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
8258 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
8259 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_streambuf, 8)
8260 basic_istream_char* __thiscall basic_istream_char_read_streambuf(
8261 basic_istream_char *this, basic_streambuf_char *streambuf)
8263 basic_ios_char *base = basic_istream_char_get_basic_ios(this);
8264 IOSB_iostate state = IOSTATE_failbit;
8267 TRACE("(%p %p)\n", this, streambuf);
8269 if(basic_istream_char_sentry_create(this, FALSE)) {
8270 for(c = basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base)); c!=EOF;
8271 c = basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base))) {
8272 state = IOSTATE_goodbit;
8273 if(basic_streambuf_char_sputc(streambuf, c) == EOF)
8277 basic_istream_char_sentry_destroy(this);
8279 basic_ios_char_setstate(base, state | (c==EOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8283 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
8284 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
8285 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func, 8)
8286 basic_istream_char* __thiscall basic_istream_char_read_func(basic_istream_char *this,
8287 basic_istream_char* (__cdecl *pfunc)(basic_istream_char*))
8289 TRACE("(%p %p)\n", this, pfunc);
8294 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z */
8295 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z */
8296 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func_basic_ios, 8)
8297 basic_istream_char* __thiscall basic_istream_char_read_func_basic_ios(basic_istream_char *this,
8298 basic_ios_char* (__cdecl *pfunc)(basic_ios_char*))
8300 TRACE("(%p %p)\n", this, pfunc);
8301 pfunc(basic_istream_char_get_basic_ios(this));
8305 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
8306 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
8307 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func_ios_base, 8)
8308 basic_istream_char* __thiscall basic_istream_char_read_func_ios_base(basic_istream_char *this,
8309 ios_base* (__cdecl *pfunc)(ios_base*))
8311 TRACE("(%p %p)\n", this, pfunc);
8312 pfunc(&basic_istream_char_get_basic_ios(this)->base);
8316 /* Caution: basic_istream uses virtual inheritance. */
8317 static inline basic_ios_wchar* basic_istream_wchar_get_basic_ios(basic_istream_wchar *this)
8319 return (basic_ios_wchar*)((char*)this+this->vbtable[1]);
8322 static inline basic_ios_wchar* basic_istream_wchar_to_basic_ios(basic_istream_wchar *ptr)
8324 return (basic_ios_wchar*)((char*)ptr+basic_istream_wchar_vbtable[1]);
8327 static inline basic_istream_wchar* basic_istream_wchar_from_basic_ios(basic_ios_wchar *ptr)
8329 return (basic_istream_wchar*)((char*)ptr-basic_istream_wchar_vbtable[1]);
8332 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z */
8333 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z */
8334 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor_init, 20)
8335 basic_istream_wchar* __thiscall basic_istream_wchar_ctor_init(basic_istream_wchar *this,
8336 basic_streambuf_wchar *strbuf, MSVCP_bool isstd, MSVCP_bool noinit, MSVCP_bool virt_init)
8338 basic_ios_wchar *base;
8340 TRACE("(%p %p %d %d %d)\n", this, strbuf, isstd, noinit, virt_init);
8343 this->vbtable = basic_istream_wchar_vbtable;
8344 base = basic_istream_wchar_get_basic_ios(this);
8345 basic_ios_wchar_ctor(base);
8347 base = basic_istream_wchar_get_basic_ios(this);
8350 base->base.vtable = &MSVCP_basic_istream_wchar_vtable;
8353 basic_ios_wchar_init(base, strbuf, isstd);
8357 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z */
8358 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z */
8359 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor_init, 20)
8360 basic_istream_wchar* __thiscall basic_istream_short_ctor_init(basic_istream_wchar *this,
8361 basic_streambuf_wchar *strbuf, MSVCP_bool isstd, MSVCP_bool noinit, MSVCP_bool virt_init)
8363 basic_istream_wchar_ctor_init(this, strbuf, isstd, noinit, virt_init);
8364 basic_istream_wchar_get_basic_ios(this)->base.vtable = &MSVCP_basic_istream_short_vtable;
8368 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
8369 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
8370 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor, 16)
8371 basic_istream_wchar* __thiscall basic_istream_wchar_ctor(basic_istream_wchar *this,
8372 basic_streambuf_wchar *strbuf, MSVCP_bool isstd, MSVCP_bool virt_init)
8374 return basic_istream_wchar_ctor_init(this, strbuf, isstd, FALSE, virt_init);
8377 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
8378 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
8379 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor, 16)
8380 basic_istream_wchar* __thiscall basic_istream_short_ctor(basic_istream_wchar *this,
8381 basic_streambuf_wchar *strbuf, MSVCP_bool isstd, MSVCP_bool virt_init)
8383 return basic_istream_short_ctor_init(this, strbuf, isstd, FALSE, virt_init);
8386 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z */
8387 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
8388 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor_uninitialized, 12)
8389 basic_istream_wchar* __thiscall basic_istream_wchar_ctor_uninitialized(
8390 basic_istream_wchar *this, int uninitialized, MSVCP_bool virt_init)
8392 basic_ios_wchar *base;
8394 TRACE("(%p %d %d)\n", this, uninitialized, virt_init);
8397 this->vbtable = basic_istream_wchar_vbtable;
8398 base = basic_istream_wchar_get_basic_ios(this);
8399 basic_ios_wchar_ctor(base);
8401 base = basic_istream_wchar_get_basic_ios(this);
8404 base->base.vtable = &MSVCP_basic_istream_wchar_vtable;
8405 ios_base_Addstd(&base->base);
8409 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z */
8410 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
8411 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor_uninitialized, 12)
8412 basic_istream_wchar* __thiscall basic_istream_short_ctor_uninitialized(
8413 basic_istream_wchar *this, int uninitialized, MSVCP_bool virt_init)
8415 basic_istream_wchar_ctor_uninitialized(this, uninitialized, virt_init);
8416 basic_istream_wchar_get_basic_ios(this)->base.vtable = &MSVCP_basic_istream_short_vtable;
8420 /* ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
8421 /* ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
8422 /* ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UAE@XZ */
8423 /* ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
8424 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_dtor, 4)
8425 void __thiscall basic_istream_wchar_dtor(basic_ios_wchar *base)
8427 basic_istream_wchar *this = basic_istream_wchar_from_basic_ios(base);
8429 /* don't destroy virtual base here */
8430 TRACE("(%p)\n", this);
8433 /* ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
8434 /* ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
8435 /* ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ */
8436 /* ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
8437 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_vbase_dtor, 4)
8438 void __thiscall basic_istream_wchar_vbase_dtor(basic_istream_wchar *this)
8440 TRACE("(%p)\n", this);
8441 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(this));
8442 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(this));
8445 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_vector_dtor, 8)
8446 basic_istream_wchar* __thiscall basic_istream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
8448 basic_istream_wchar *this = basic_istream_wchar_from_basic_ios(base);
8450 TRACE("(%p %x)\n", this, flags);
8453 /* we have an array, with the number of elements stored before the first object */
8454 INT_PTR i, *ptr = (INT_PTR *)this-1;
8456 for(i=*ptr-1; i>=0; i--)
8457 basic_istream_wchar_vbase_dtor(this+i);
8458 MSVCRT_operator_delete(ptr);
8460 basic_istream_wchar_vbase_dtor(this);
8462 MSVCRT_operator_delete(this);
8468 /* ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z */
8469 /* ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z */
8470 /* ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z */
8471 /* ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z */
8472 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Ipfx, 8)
8473 MSVCP_bool __thiscall basic_istream_wchar__Ipfx(basic_istream_wchar *this, MSVCP_bool noskip)
8475 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8477 TRACE("(%p %d)\n", this, noskip);
8479 if(!ios_base_good(&base->base)) {
8480 basic_ios_wchar_setstate(base, IOSTATE_failbit);
8484 if(basic_ios_wchar_tie_get(base))
8485 basic_ostream_wchar_flush(basic_ios_wchar_tie_get(base));
8487 if(!noskip && (ios_base_flags_get(&base->base) & FMTFLAG_skipws)) {
8488 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8489 const ctype_wchar *ctype = ctype_wchar_use_facet(base->strbuf->loc);
8492 for(ch = basic_streambuf_wchar_sgetc(strbuf); ;
8493 ch = basic_streambuf_wchar_snextc(strbuf)) {
8495 basic_ios_wchar_setstate(base, IOSTATE_eofbit);
8499 if(!ctype_wchar_is_ch(ctype, _SPACE|_BLANK, ch))
8507 /* ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z */
8508 /* ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z */
8509 /* ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z */
8510 /* ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z */
8511 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ipfx, 8)
8512 MSVCP_bool __thiscall basic_istream_wchar_ipfx(basic_istream_wchar *this, MSVCP_bool noskip)
8514 return basic_istream_wchar__Ipfx(this, noskip);
8517 /* ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
8518 /* ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
8519 /* ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ */
8520 /* ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
8521 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_isfx, 4)
8522 void __thiscall basic_istream_wchar_isfx(basic_istream_wchar *this)
8524 TRACE("(%p)\n", this);
8527 static BOOL basic_istream_wchar_sentry_create(basic_istream_wchar *istr, MSVCP_bool noskip)
8529 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(istr);
8531 if(basic_ios_wchar_rdbuf_get(base))
8532 basic_streambuf_wchar__Lock(base->strbuf);
8534 return basic_istream_wchar_ipfx(istr, noskip);
8537 static void basic_istream_wchar_sentry_destroy(basic_istream_wchar *istr)
8539 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(istr);
8541 if(basic_ios_wchar_rdbuf_get(base))
8542 basic_streambuf_wchar__Unlock(base->strbuf);
8545 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBEHXZ */
8546 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEBA_JXZ */
8547 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBEHXZ */
8548 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QEBA_JXZ */
8549 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_gcount, 4)
8550 int __thiscall basic_istream_wchar_gcount(const basic_istream_wchar *this)
8552 TRACE("(%p)\n", this);
8556 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
8557 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
8558 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ */
8559 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ */
8560 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get, 4)
8561 unsigned short __thiscall basic_istream_wchar_get(basic_istream_wchar *this)
8563 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8566 TRACE("(%p)\n", this);
8570 if(!basic_istream_wchar_sentry_create(this, TRUE)) {
8571 basic_istream_wchar_sentry_destroy(this);
8575 ret = basic_streambuf_wchar_sbumpc(basic_ios_wchar_rdbuf_get(base));
8576 basic_istream_wchar_sentry_destroy(this);
8578 basic_ios_wchar_setstate(base, IOSTATE_eofbit|IOSTATE_failbit);
8585 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AA_W@Z */
8586 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEA_W@Z */
8587 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAG@Z */
8588 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAG@Z */
8589 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_ch, 8)
8590 basic_istream_wchar* __thiscall basic_istream_wchar_get_ch(basic_istream_wchar *this, wchar_t *ch)
8594 TRACE("(%p %p)\n", this, ch);
8596 ret = basic_istream_wchar_get(this);
8602 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH_W@Z */
8603 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z */
8604 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGHG@Z */
8605 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z */
8606 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str_delim, 16)
8607 basic_istream_wchar* __thiscall basic_istream_wchar_get_str_delim(basic_istream_wchar *this, wchar_t *str, streamsize count, wchar_t delim)
8609 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8610 unsigned short ch = delim;
8612 TRACE("(%p %p %ld %c)\n", this, str, count, delim);
8616 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8617 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8619 for(ch = basic_streambuf_wchar_sgetc(strbuf); count>1;
8620 ch = basic_streambuf_wchar_snextc(strbuf)) {
8621 if(ch==WEOF || ch==delim)
8629 basic_istream_wchar_sentry_destroy(this);
8631 basic_ios_wchar_setstate(base, (!this->count ? IOSTATE_failbit : IOSTATE_goodbit) |
8632 (ch==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8638 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
8639 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
8640 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
8641 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
8642 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str, 12)
8643 basic_istream_wchar* __thiscall basic_istream_wchar_get_str(basic_istream_wchar *this, wchar_t *str, streamsize count)
8645 return basic_istream_wchar_get_str_delim(this, str, count, '\n');
8648 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z */
8649 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z */
8650 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z */
8651 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z */
8652 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_streambuf_delim, 12)
8653 basic_istream_wchar* __thiscall basic_istream_wchar_get_streambuf_delim(basic_istream_wchar *this, basic_streambuf_wchar *strbuf, wchar_t delim)
8655 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8656 unsigned short ch = delim;
8658 TRACE("(%p %p %c)\n", this, strbuf, delim);
8662 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8663 basic_streambuf_wchar *strbuf_read = basic_ios_wchar_rdbuf_get(base);
8665 for(ch = basic_streambuf_wchar_sgetc(strbuf_read); ;
8666 ch = basic_streambuf_wchar_snextc(strbuf_read)) {
8667 if(ch==WEOF || ch==delim)
8670 if(basic_streambuf_wchar_sputc(strbuf, ch) == WEOF)
8675 basic_istream_wchar_sentry_destroy(this);
8677 basic_ios_wchar_setstate(base, (!this->count ? IOSTATE_failbit : IOSTATE_goodbit) |
8678 (ch==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
8682 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z */
8683 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z */
8684 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z */
8685 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z */
8686 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_streambuf, 8)
8687 basic_istream_wchar* __thiscall basic_istream_wchar_get_streambuf(basic_istream_wchar *this, basic_streambuf_wchar *strbuf)
8689 return basic_istream_wchar_get_streambuf_delim(this, strbuf, '\n');
8692 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH_W@Z */
8693 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z */
8694 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGHG@Z */
8695 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z */
8696 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline_delim, 16)
8697 basic_istream_wchar* __thiscall basic_istream_wchar_getline_delim(basic_istream_wchar *this, wchar_t *str, streamsize count, wchar_t delim)
8699 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8700 unsigned short ch = delim;
8702 TRACE("(%p %p %ld %c)\n", this, str, count, delim);
8706 if(basic_istream_wchar_sentry_create(this, TRUE) && count>0) {
8707 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8710 ch = basic_streambuf_wchar_sbumpc(strbuf);
8712 if(ch==WEOF || ch==delim)
8722 else if(ch != WEOF) {
8723 ch = basic_streambuf_wchar_sgetc(strbuf);
8726 basic_streambuf_wchar__Gninc(strbuf);
8731 basic_istream_wchar_sentry_destroy(this);
8733 basic_ios_wchar_setstate(base, (ch==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit) |
8734 (!this->count || (ch!=delim && ch!=WEOF) ? IOSTATE_failbit : IOSTATE_goodbit));
8740 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
8741 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
8742 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
8743 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
8744 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline, 12)
8745 basic_istream_wchar* __thiscall basic_istream_wchar_getline(basic_istream_wchar *this, wchar_t *str, streamsize count)
8747 return basic_istream_wchar_getline_delim(this, str, count, '\n');
8750 /* ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@HG@Z */
8751 /* ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JG@Z */
8752 /* ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@HG@Z */
8753 /* ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JG@Z */
8754 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ignore, 12)
8755 basic_istream_wchar* __thiscall basic_istream_wchar_ignore(basic_istream_wchar *this, streamsize count, unsigned short delim)
8757 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8758 unsigned short ch = delim;
8760 TRACE("(%p %ld %d)\n", this, count, delim);
8764 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8765 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8768 ch = basic_streambuf_wchar_sbumpc(strbuf);
8770 if(ch==WEOF || ch==delim)
8774 if(count != INT_MAX)
8778 basic_istream_wchar_sentry_destroy(this);
8781 basic_ios_wchar_setstate(base, IOSTATE_eofbit);
8785 /* ?ws@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
8786 /* ?ws@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
8787 /* ?ws@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@1@AAV21@@Z */
8788 /* ?ws@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
8789 basic_istream_wchar* __cdecl ws_basic_istream_wchar(basic_istream_wchar *istream)
8791 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(istream);
8792 unsigned short ch = '\n';
8794 TRACE("(%p)\n", istream);
8796 if(basic_istream_wchar_sentry_create(istream, TRUE)) {
8797 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8798 const ctype_wchar *ctype = ctype_wchar_use_facet(strbuf->loc);
8800 for(ch = basic_streambuf_wchar_sgetc(strbuf); ctype_wchar_is_ch(ctype, _SPACE, ch);
8801 ch = basic_streambuf_wchar_snextc(strbuf)) {
8806 basic_istream_wchar_sentry_destroy(istream);
8809 basic_ios_wchar_setstate(base, IOSTATE_eofbit);
8813 /* ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
8814 /* ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
8815 /* ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ */
8816 /* ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ */
8817 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_peek, 4)
8818 unsigned short __thiscall basic_istream_wchar_peek(basic_istream_wchar *this)
8820 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8821 unsigned short ret = WEOF;
8823 TRACE("(%p)\n", this);
8827 if(basic_istream_wchar_sentry_create(this, TRUE))
8828 ret = basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base));
8829 basic_istream_wchar_sentry_destroy(this);
8833 /* ?_Read_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WIH@Z */
8834 /* ?_Read_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_K_J@Z */
8835 /* ?_Read_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGIH@Z */
8836 /* ?_Read_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_K_J@Z */
8837 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Read_s, 16)
8838 basic_istream_wchar* __thiscall basic_istream_wchar__Read_s(basic_istream_wchar *this, wchar_t *str, MSVCP_size_t size, streamsize count)
8840 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8841 IOSB_iostate state = IOSTATE_goodbit;
8843 TRACE("(%p %p %lu %ld)\n", this, str, size, count);
8845 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8846 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8848 this->count = basic_streambuf_wchar__Sgetn_s(strbuf, str, size, count);
8849 if(this->count != count)
8850 state |= IOSTATE_failbit | IOSTATE_eofbit;
8854 basic_istream_wchar_sentry_destroy(this);
8856 basic_ios_wchar_setstate(base, state);
8860 /* ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
8861 /* ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
8862 /* ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
8863 /* ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
8864 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read, 12)
8865 basic_istream_wchar* __thiscall basic_istream_wchar_read(basic_istream_wchar *this, wchar_t *str, streamsize count)
8867 return basic_istream_wchar__Read_s(this, str, count, count);
8870 /* ?_Readsome_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHPA_WIH@Z */
8871 /* ?_Readsome_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_K_J@Z */
8872 /* ?_Readsome_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHPAGIH@Z */
8873 /* ?_Readsome_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_K_J@Z */
8874 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Readsome_s, 16)
8875 streamsize __thiscall basic_istream_wchar__Readsome_s(basic_istream_wchar *this, wchar_t *str, MSVCP_size_t size, streamsize count)
8877 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8878 IOSB_iostate state = IOSTATE_goodbit;
8880 TRACE("(%p %p %lu %ld)\n", this, str, size, count);
8884 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8885 streamsize avail = basic_streambuf_wchar_in_avail(basic_ios_wchar_rdbuf_get(base));
8890 state |= IOSTATE_eofbit;
8892 basic_istream_wchar__Read_s(this, str, size, avail);
8894 state |= IOSTATE_failbit;
8896 basic_istream_wchar_sentry_destroy(this);
8898 basic_ios_wchar_setstate(base, state);
8902 /* ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHPA_WH@Z */
8903 /* ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z */
8904 /* ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHPAGH@Z */
8905 /* ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z */
8906 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_readsome, 12)
8907 streamsize __thiscall basic_istream_wchar_readsome(basic_istream_wchar *this, wchar_t *str, streamsize count)
8909 return basic_istream_wchar__Readsome_s(this, str, count, count);
8912 /* ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z */
8913 /* ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z */
8914 /* ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z */
8915 /* ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z */
8916 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_putback, 8)
8917 basic_istream_wchar* __thiscall basic_istream_wchar_putback(basic_istream_wchar *this, wchar_t ch)
8919 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8920 IOSB_iostate state = IOSTATE_goodbit;
8922 TRACE("(%p %c)\n", this, ch);
8926 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8927 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8929 if(!ios_base_good(&base->base))
8930 state |= IOSTATE_failbit;
8931 else if(!strbuf || basic_streambuf_wchar_sputbackc(strbuf, ch)==WEOF)
8932 state |= IOSTATE_badbit;
8934 basic_istream_wchar_sentry_destroy(this);
8936 basic_ios_wchar_setstate(base, state);
8940 /* ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ */
8941 /* ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ */
8942 /* ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ */
8943 /* ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ */
8944 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_unget, 4)
8945 basic_istream_wchar* __thiscall basic_istream_wchar_unget(basic_istream_wchar *this)
8947 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8948 IOSB_iostate state = IOSTATE_goodbit;
8950 TRACE("(%p)\n", this);
8954 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8955 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8957 if(!ios_base_good(&base->base))
8958 state |= IOSTATE_failbit;
8959 else if(!strbuf || basic_streambuf_wchar_sungetc(strbuf)==WEOF)
8960 state |= IOSTATE_badbit;
8962 basic_istream_wchar_sentry_destroy(this);
8964 basic_ios_wchar_setstate(base, state);
8968 /* ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
8969 /* ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAHXZ */
8970 /* ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHXZ */
8971 /* ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAHXZ */
8972 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_sync, 4)
8973 int __thiscall basic_istream_wchar_sync(basic_istream_wchar *this)
8975 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
8976 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
8978 TRACE("(%p)\n", this);
8983 if(basic_istream_wchar_sentry_create(this, TRUE)) {
8984 if(basic_streambuf_wchar_pubsync(strbuf) != -1) {
8985 basic_istream_wchar_sentry_destroy(this);
8989 basic_istream_wchar_sentry_destroy(this);
8991 basic_ios_wchar_setstate(base, IOSTATE_badbit);
8995 /* ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ */
8996 /* ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
8997 /* ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ */
8998 /* ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
8999 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_tellg, 8)
9000 fpos_int* __thiscall basic_istream_wchar_tellg(basic_istream_wchar *this, fpos_int *ret)
9002 TRACE("(%p %p)\n", this, ret);
9004 if(basic_istream_wchar_sentry_create(this, TRUE)) {
9005 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9006 if(!ios_base_fail(&base->base)) {
9007 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base),
9008 ret, 0, SEEKDIR_cur, OPENMODE_in);
9009 basic_istream_wchar_sentry_destroy(this);
9011 if(ret->off==0 && ret->pos==-1 && ret->state==0)
9012 basic_ios_wchar_setstate(base, IOSTATE_failbit);
9016 basic_istream_wchar_sentry_destroy(this);
9024 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@JH@Z */
9025 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z */
9026 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@JH@Z */
9027 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z */
9028 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg, 12)
9029 basic_istream_wchar* __thiscall basic_istream_wchar_seekg(basic_istream_wchar *this, streamoff off, int dir)
9031 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9033 TRACE("(%p %ld %d)\n", this, off, dir);
9035 if(basic_istream_wchar_sentry_create(this, TRUE)) {
9036 if(!ios_base_fail(&base->base)) {
9037 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9040 basic_streambuf_wchar_pubseekoff(strbuf, &ret, off, dir, OPENMODE_in);
9041 basic_istream_wchar_sentry_destroy(this);
9043 if(ret.off==0 && ret.pos==-1 && ret.state==0)
9044 basic_ios_wchar_setstate(base, IOSTATE_failbit);
9046 basic_ios_wchar_clear(base, IOSTATE_goodbit);
9050 basic_istream_wchar_sentry_destroy(this);
9052 basic_ios_wchar_setstate(base, IOSTATE_failbit);
9056 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
9057 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
9058 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
9059 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
9060 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg_fpos, 28)
9061 basic_istream_wchar* __thiscall basic_istream_wchar_seekg_fpos(basic_istream_wchar *this, fpos_int pos)
9063 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9065 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos));
9067 if(basic_istream_wchar_sentry_create(this, TRUE)) {
9068 if(!ios_base_fail(&base->base)) {
9069 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9072 basic_streambuf_wchar_pubseekpos(strbuf, &ret, pos, OPENMODE_in);
9073 basic_istream_wchar_sentry_destroy(this);
9075 if(ret.off==0 && ret.pos==-1 && ret.state==0)
9076 basic_ios_wchar_setstate(base, IOSTATE_failbit);
9078 basic_ios_wchar_clear(base, IOSTATE_goodbit);
9082 basic_istream_wchar_sentry_destroy(this);
9084 basic_ios_wchar_setstate(base, IOSTATE_failbit);
9088 static basic_istream_wchar* basic_istream_read_short(basic_istream_wchar *this, short *v, const num_get *numget)
9090 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9091 int state = IOSTATE_goodbit;
9093 TRACE("(%p %p)\n", this, v);
9095 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9096 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9097 istreambuf_iterator_wchar first={0}, last={0};
9100 first.strbuf = strbuf;
9101 num_get_wchar_get_long(numget, &last, first, last, &base->base, &state, &tmp);
9103 if(!(state&IOSTATE_failbit) && tmp==(LONG)((short)tmp))
9106 state |= IOSTATE_failbit;
9108 basic_istream_wchar_sentry_destroy(this);
9110 basic_ios_wchar_setstate(base, state);
9114 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAF@Z */
9115 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAF@Z */
9116 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_short, 8)
9117 basic_istream_wchar* __thiscall basic_istream_wchar_read_short(basic_istream_wchar *this, short *v)
9119 return basic_istream_read_short(this, v, num_get_wchar_use_facet(
9120 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9123 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAF@Z */
9124 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAF@Z */
9125 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_short, 8)
9126 basic_istream_wchar* __thiscall basic_istream_short_read_short(basic_istream_wchar *this, short *v)
9128 return basic_istream_read_short(this, v, num_get_short_use_facet(
9129 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9132 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAG@Z */
9133 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAG@Z */
9134 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ushort, 8)
9135 basic_istream_wchar* __thiscall basic_istream_wchar_read_ushort(basic_istream_wchar *this, unsigned short *v)
9137 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9138 int state = IOSTATE_goodbit;
9140 TRACE("(%p %p)\n", this, v);
9142 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9143 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9144 const num_get *numget = num_get_wchar_use_facet(strbuf->loc);
9145 istreambuf_iterator_wchar first={0}, last={0};
9147 first.strbuf = strbuf;
9148 num_get_wchar_get_ushort(numget, &last, first, last, &base->base, &state, v);
9150 basic_istream_wchar_sentry_destroy(this);
9152 basic_ios_wchar_setstate(base, state);
9156 static basic_istream_wchar* basic_istream_read_int(basic_istream_wchar *this, int *v, const num_get *numget)
9158 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9159 int state = IOSTATE_goodbit;
9161 TRACE("(%p %p)\n", this, v);
9163 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9164 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9165 istreambuf_iterator_wchar first={0}, last={0};
9167 first.strbuf = strbuf;
9168 num_get_wchar_get_long(numget, &last, first, last, &base->base, &state, v);
9170 basic_istream_wchar_sentry_destroy(this);
9172 basic_ios_wchar_setstate(base, state);
9176 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAH@Z */
9177 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAH@Z */
9178 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_int, 8)
9179 basic_istream_wchar* __thiscall basic_istream_wchar_read_int(basic_istream_wchar *this, int *v)
9181 return basic_istream_read_int(this, v, num_get_wchar_use_facet(
9182 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9185 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAH@Z */
9186 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAH@Z */
9187 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_int, 8)
9188 basic_istream_wchar* __thiscall basic_istream_short_read_int(basic_istream_wchar *this, int *v)
9190 return basic_istream_read_int(this, v, num_get_short_use_facet(
9191 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9194 static basic_istream_wchar* basic_istream_read_uint(basic_istream_wchar *this, unsigned int *v, const num_get *numget)
9196 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9197 int state = IOSTATE_goodbit;
9199 TRACE("(%p %p)\n", this, v);
9201 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9202 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9203 istreambuf_iterator_wchar first={0}, last={0};
9205 first.strbuf = strbuf;
9206 num_get_wchar_get_uint(numget, &last, first, last, &base->base, &state, v);
9208 basic_istream_wchar_sentry_destroy(this);
9210 basic_ios_wchar_setstate(base, state);
9214 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAI@Z */
9215 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAI@Z */
9216 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_uint, 8)
9217 basic_istream_wchar* __thiscall basic_istream_wchar_read_uint(basic_istream_wchar *this, unsigned int *v)
9219 return basic_istream_read_uint(this, v, num_get_wchar_use_facet(
9220 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9223 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAI@Z */
9224 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAI@Z */
9225 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_uint, 8)
9226 basic_istream_wchar* __thiscall basic_istream_short_read_uint(basic_istream_wchar *this, unsigned int *v)
9228 return basic_istream_read_uint(this, v, num_get_short_use_facet(
9229 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9232 static basic_istream_wchar* basic_istream_read_long(basic_istream_wchar *this, LONG *v, const num_get *numget)
9234 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9235 int state = IOSTATE_goodbit;
9237 TRACE("(%p %p)\n", this, v);
9239 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9240 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9241 istreambuf_iterator_wchar first={0}, last={0};
9243 first.strbuf = strbuf;
9244 num_get_wchar_get_long(numget, &last, first, last, &base->base, &state, v);
9246 basic_istream_wchar_sentry_destroy(this);
9248 basic_ios_wchar_setstate(base, state);
9252 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z */
9253 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z */
9254 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_long, 8)
9255 basic_istream_wchar* __thiscall basic_istream_wchar_read_long(basic_istream_wchar *this, LONG *v)
9257 return basic_istream_read_long(this, v, num_get_wchar_use_facet(
9258 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9261 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z */
9262 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z */
9263 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_long, 8)
9264 basic_istream_wchar* __thiscall basic_istream_short_read_long(basic_istream_wchar *this, LONG *v)
9266 return basic_istream_read_long(this, v, num_get_short_use_facet(
9267 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9270 static basic_istream_wchar* basic_istream_read_ulong(basic_istream_wchar *this, ULONG *v, const num_get *numget)
9272 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9273 int state = IOSTATE_goodbit;
9275 TRACE("(%p %p)\n", this, v);
9277 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9278 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9279 istreambuf_iterator_wchar first={0}, last={0};
9281 first.strbuf = strbuf;
9282 num_get_wchar_get_ulong(numget, &last, first, last, &base->base, &state, v);
9284 basic_istream_wchar_sentry_destroy(this);
9286 basic_ios_wchar_setstate(base, state);
9290 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAK@Z */
9291 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAK@Z */
9292 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ulong, 8)
9293 basic_istream_wchar* __thiscall basic_istream_wchar_read_ulong(basic_istream_wchar *this, ULONG *v)
9295 return basic_istream_read_ulong(this, v, num_get_wchar_use_facet(
9296 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9299 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAK@Z */
9300 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAK@Z */
9301 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ulong, 8)
9302 basic_istream_wchar* __thiscall basic_istream_short_read_ulong(basic_istream_wchar *this, ULONG *v)
9304 return basic_istream_read_ulong(this, v, num_get_short_use_facet(
9305 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9308 static basic_istream_wchar* basic_istream_read_float(basic_istream_wchar *this, float *v, const num_get *numget)
9310 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9311 int state = IOSTATE_goodbit;
9313 TRACE("(%p %p)\n", this, v);
9315 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9316 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9317 istreambuf_iterator_wchar first={0}, last={0};
9319 first.strbuf = strbuf;
9320 num_get_wchar_get_float(numget, &last, first, last, &base->base, &state, v);
9322 basic_istream_wchar_sentry_destroy(this);
9324 basic_ios_wchar_setstate(base, state);
9328 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAM@Z */
9329 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAM@Z */
9330 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_float, 8)
9331 basic_istream_wchar* __thiscall basic_istream_wchar_read_float(basic_istream_wchar *this, float *v)
9333 return basic_istream_read_float(this, v, num_get_wchar_use_facet(
9334 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9337 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAM@Z */
9338 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAM@Z */
9339 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_float, 8)
9340 basic_istream_wchar* __thiscall basic_istream_short_read_float(basic_istream_wchar *this, float *v)
9342 return basic_istream_read_float(this, v, num_get_short_use_facet(
9343 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9346 static basic_istream_wchar* basic_istream_read_double(basic_istream_wchar *this, double *v, const num_get *numget)
9348 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9349 int state = IOSTATE_goodbit;
9351 TRACE("(%p %p)\n", this, v);
9353 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9354 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9355 istreambuf_iterator_wchar first={0}, last={0};
9357 first.strbuf = strbuf;
9358 num_get_wchar_get_double(numget, &last, first, last, &base->base, &state, v);
9360 basic_istream_wchar_sentry_destroy(this);
9362 basic_ios_wchar_setstate(base, state);
9366 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAN@Z */
9367 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAN@Z */
9368 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_double, 8)
9369 basic_istream_wchar* __thiscall basic_istream_wchar_read_double(basic_istream_wchar *this, double *v)
9371 return basic_istream_read_double(this, v, num_get_wchar_use_facet(
9372 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9375 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAN@Z */
9376 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAN@Z */
9377 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_double, 8)
9378 basic_istream_wchar* __thiscall basic_istream_short_read_double(basic_istream_wchar *this, double *v)
9380 return basic_istream_read_double(this, v, num_get_short_use_facet(
9381 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9384 static basic_istream_wchar* basic_istream_read_ldouble(basic_istream_wchar *this, double *v, const num_get *numget)
9386 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9387 int state = IOSTATE_goodbit;
9389 TRACE("(%p %p)\n", this, v);
9391 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9392 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9393 istreambuf_iterator_wchar first={0}, last={0};
9395 first.strbuf = strbuf;
9396 num_get_wchar_get_ldouble(numget, &last, first, last, &base->base, &state, v);
9398 basic_istream_wchar_sentry_destroy(this);
9400 basic_ios_wchar_setstate(base, state);
9404 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAO@Z */
9405 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAO@Z */
9406 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ldouble, 8)
9407 basic_istream_wchar* __thiscall basic_istream_wchar_read_ldouble(basic_istream_wchar *this, double *v)
9409 return basic_istream_read_ldouble(this, v, num_get_wchar_use_facet(
9410 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9413 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAO@Z */
9414 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAO@Z */
9415 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ldouble, 8)
9416 basic_istream_wchar* __thiscall basic_istream_short_read_ldouble(basic_istream_wchar *this, double *v)
9418 return basic_istream_read_ldouble(this, v, num_get_short_use_facet(
9419 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9422 static basic_istream_wchar* basic_istream_read_ptr(basic_istream_wchar *this, void **v, const num_get *numget)
9424 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9425 int state = IOSTATE_goodbit;
9427 TRACE("(%p %p)\n", this, v);
9429 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9430 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9431 istreambuf_iterator_wchar first={0}, last={0};
9433 first.strbuf = strbuf;
9434 num_get_wchar_get_void(numget, &last, first, last, &base->base, &state, v);
9436 basic_istream_wchar_sentry_destroy(this);
9438 basic_ios_wchar_setstate(base, state);
9442 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAPAX@Z */
9443 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
9444 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ptr, 8)
9445 basic_istream_wchar* __thiscall basic_istream_wchar_read_ptr(basic_istream_wchar *this, void **v)
9447 return basic_istream_read_ptr(this, v, num_get_wchar_use_facet(
9448 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9451 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAPAX@Z */
9452 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
9453 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ptr, 8)
9454 basic_istream_wchar* __thiscall basic_istream_short_read_ptr(basic_istream_wchar *this, void **v)
9456 return basic_istream_read_ptr(this, v, num_get_short_use_facet(
9457 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9460 static basic_istream_wchar* basic_istream_read_int64(basic_istream_wchar *this, __int64 *v, const num_get *numget)
9462 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9463 int state = IOSTATE_goodbit;
9465 TRACE("(%p %p)\n", this, v);
9467 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9468 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9469 istreambuf_iterator_wchar first={0}, last={0};
9471 first.strbuf = strbuf;
9472 num_get_wchar_get_int64(numget, &last, first, last, &base->base, &state, v);
9474 basic_istream_wchar_sentry_destroy(this);
9476 basic_ios_wchar_setstate(base, state);
9480 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_J@Z */
9481 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_J@Z */
9482 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_int64, 8)
9483 basic_istream_wchar* __thiscall basic_istream_wchar_read_int64(basic_istream_wchar *this, __int64 *v)
9485 return basic_istream_read_int64(this, v, num_get_wchar_use_facet(
9486 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9489 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_J@Z */
9490 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_J@Z */
9491 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_int64, 8)
9492 basic_istream_wchar* __thiscall basic_istream_short_read_int64(basic_istream_wchar *this, __int64 *v)
9494 return basic_istream_read_int64(this, v, num_get_short_use_facet(
9495 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9498 static basic_istream_wchar* basic_istream_read_uint64(basic_istream_wchar *this, unsigned __int64 *v, const num_get *numget)
9500 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9501 int state = IOSTATE_goodbit;
9503 TRACE("(%p %p)\n", this, v);
9505 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9506 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9507 istreambuf_iterator_wchar first={0}, last={0};
9509 first.strbuf = strbuf;
9510 num_get_wchar_get_uint64(numget, &last, first, last, &base->base, &state, v);
9512 basic_istream_wchar_sentry_destroy(this);
9514 basic_ios_wchar_setstate(base, state);
9518 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_K@Z */
9519 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_K@Z */
9520 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_uint64, 8)
9521 basic_istream_wchar* __thiscall basic_istream_wchar_read_uint64(basic_istream_wchar *this, unsigned __int64 *v)
9523 return basic_istream_read_uint64(this, v, num_get_wchar_use_facet(
9524 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9527 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_K@Z */
9528 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_K@Z */
9529 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_uint64, 8)
9530 basic_istream_wchar* __thiscall basic_istream_short_read_uint64(basic_istream_wchar *this, unsigned __int64 *v)
9532 return basic_istream_read_uint64(this, v, num_get_short_use_facet(
9533 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9536 static basic_istream_wchar* basic_istream_read_bool(basic_istream_wchar *this, MSVCP_bool *v, const num_get *numget)
9538 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9539 int state = IOSTATE_goodbit;
9541 TRACE("(%p %p)\n", this, v);
9543 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9544 basic_streambuf_wchar *strbuf = basic_ios_wchar_rdbuf_get(base);
9545 istreambuf_iterator_wchar first={0}, last={0};
9547 first.strbuf = strbuf;
9548 num_get_wchar_get_bool(numget, &last, first, last, &base->base, &state, v);
9550 basic_istream_wchar_sentry_destroy(this);
9552 basic_ios_wchar_setstate(base, state);
9556 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_N@Z */
9557 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_N@Z */
9558 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_bool, 8)
9559 basic_istream_wchar* __thiscall basic_istream_wchar_read_bool(basic_istream_wchar *this, MSVCP_bool *v)
9561 return basic_istream_read_bool(this, v, num_get_wchar_use_facet(
9562 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9565 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_N@Z */
9566 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_N@Z */
9567 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_bool, 8)
9568 basic_istream_wchar* __thiscall basic_istream_short_read_bool(basic_istream_wchar *this, MSVCP_bool *v)
9570 return basic_istream_read_bool(this, v, num_get_short_use_facet(
9571 basic_istream_wchar_get_basic_ios(this)->strbuf->loc));
9574 /* ??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@_W@Z */
9575 /* ??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@_W@Z */
9576 /* ??$getline@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@AAV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@G@Z */
9577 /* ??$getline@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@AEAV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@G@Z */
9578 basic_istream_wchar* __cdecl basic_istream_wchar_getline_bstr_delim(
9579 basic_istream_wchar *istream, basic_string_wchar *str, wchar_t delim)
9581 IOSB_iostate state = IOSTATE_failbit;
9584 TRACE("(%p %p %c)\n", istream, str, delim);
9586 if(basic_istream_wchar_sentry_create(istream, TRUE)) {
9587 MSVCP_basic_string_wchar_clear(str);
9589 c = basic_istream_wchar_get(istream);
9591 state = IOSTATE_goodbit;
9593 for(; c!=delim && c!=WEOF; c = basic_istream_wchar_get(istream)) {
9594 state = IOSTATE_goodbit;
9595 MSVCP_basic_string_wchar_append_ch(str, c);
9598 basic_istream_wchar_sentry_destroy(istream);
9600 basic_ios_wchar_setstate(basic_istream_wchar_get_basic_ios(istream),
9601 state | (c==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
9605 /* ??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@@Z */
9606 /* ??$getline@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@@Z */
9607 /* ??$getline@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@AAV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z */
9608 /* ??$getline@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@AEAV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z */
9609 basic_istream_wchar* __cdecl basic_istream_wchar_getline_bstr(
9610 basic_istream_wchar *istream, basic_string_wchar *str)
9612 return basic_istream_wchar_getline_bstr_delim(istream, str, '\n');
9615 static basic_istream_wchar* basic_istream_read_bstr(basic_istream_wchar *istream,
9616 basic_string_wchar *str, const ctype_wchar *ctype)
9618 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(istream);
9619 IOSB_iostate state = IOSTATE_failbit;
9622 TRACE("(%p %p)\n", istream, str);
9624 if(basic_istream_wchar_sentry_create(istream, FALSE)) {
9625 MSVCP_size_t count = ios_base_width_get(&base->base);
9630 MSVCP_basic_string_wchar_clear(str);
9632 for(c = basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base));
9633 c!=WEOF && !ctype_wchar_is_ch(ctype, _SPACE|_BLANK, c) && count>0;
9634 c = basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base)), count--) {
9635 state = IOSTATE_goodbit;
9636 MSVCP_basic_string_wchar_append_ch(str, c);
9639 basic_istream_wchar_sentry_destroy(istream);
9641 ios_base_width_set(&base->base, 0);
9642 basic_ios_wchar_setstate(base, state | (c==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
9646 /* ??$?5_WU?$char_traits@_W@std@@V?$allocator@_W@1@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@@Z */
9647 /* ??$?5_WU?$char_traits@_W@std@@V?$allocator@_W@1@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEAV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@0@@Z */
9648 basic_istream_wchar* __cdecl basic_istream_wchar_read_bstr(
9649 basic_istream_wchar *istream, basic_string_wchar *str)
9651 return basic_istream_read_bstr(istream, str, ctype_wchar_use_facet(
9652 basic_istream_wchar_get_basic_ios(istream)->strbuf->loc));
9655 /* ??$?5GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@AAV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z */
9656 /* ??$?5GU?$char_traits@G@std@@V?$allocator@G@1@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@AEAV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@0@@Z */
9657 basic_istream_wchar* __cdecl basic_istream_short_read_bstr(
9658 basic_istream_wchar *istream, basic_string_wchar *str)
9660 return basic_istream_read_bstr(istream, str, ctype_short_use_facet(
9661 basic_istream_wchar_get_basic_ios(istream)->strbuf->loc));
9664 static basic_istream_wchar* basic_istream_read_str(basic_istream_wchar *istream, wchar_t *str, const ctype_wchar *ctype)
9666 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(istream);
9667 IOSB_iostate state = IOSTATE_failbit;
9668 unsigned short c = '\n';
9670 TRACE("(%p %p)\n", istream, str);
9672 if(basic_istream_wchar_sentry_create(istream, FALSE)) {
9673 MSVCP_size_t count = ios_base_width_get(&base->base)-1;
9675 for(c = basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base));
9676 c!=WEOF && !ctype_wchar_is_ch(ctype, _SPACE|_BLANK, c) && count>0;
9677 c = basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base)), count--) {
9678 state = IOSTATE_goodbit;
9682 basic_istream_wchar_sentry_destroy(istream);
9685 ios_base_width_set(&base->base, 0);
9686 basic_ios_wchar_setstate(base, state | (c==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
9690 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@PA_W@Z */
9691 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@PEA_W@Z */
9692 basic_istream_wchar* __cdecl basic_istream_wchar_read_str(basic_istream_wchar *istream, wchar_t *str)
9694 return basic_istream_read_str(istream, str, ctype_wchar_use_facet(
9695 basic_istream_wchar_get_basic_ios(istream)->strbuf->loc));
9698 /* ??$?5GU?$char_traits@G@std@@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@PAG@Z */
9699 /* ??$?5GU?$char_traits@G@std@@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@PEAG@Z */
9700 basic_istream_wchar* __cdecl basic_istream_short_read_str(basic_istream_wchar *istream, wchar_t *str)
9702 return basic_istream_read_str(istream, str, ctype_short_use_facet(
9703 basic_istream_wchar_get_basic_ios(istream)->strbuf->loc));
9706 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AA_W@Z */
9707 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEA_W@Z */
9708 /* ??$?5GU?$char_traits@G@std@@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@AAG@Z */
9709 /* ??$?5GU?$char_traits@G@std@@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@AEAG@Z */
9710 basic_istream_wchar* __cdecl basic_istream_wchar_read_ch(basic_istream_wchar *istream, wchar_t *ch)
9712 IOSB_iostate state = IOSTATE_failbit;
9713 unsigned short c = 0;
9715 TRACE("(%p %p)\n", istream, ch);
9717 if(basic_istream_wchar_sentry_create(istream, FALSE)) {
9718 c = basic_streambuf_wchar_sbumpc(basic_ios_wchar_rdbuf_get(
9719 basic_istream_wchar_get_basic_ios(istream)));
9721 state = IOSTATE_goodbit;
9725 basic_istream_wchar_sentry_destroy(istream);
9727 basic_ios_wchar_setstate(basic_istream_wchar_get_basic_ios(istream),
9728 state | (c==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
9732 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
9733 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
9734 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
9735 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
9736 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_streambuf, 8)
9737 basic_istream_wchar* __thiscall basic_istream_wchar_read_streambuf(
9738 basic_istream_wchar *this, basic_streambuf_wchar *streambuf)
9740 basic_ios_wchar *base = basic_istream_wchar_get_basic_ios(this);
9741 IOSB_iostate state = IOSTATE_failbit;
9742 unsigned short c = '\n';
9744 TRACE("(%p %p)\n", this, streambuf);
9746 if(basic_istream_wchar_sentry_create(this, FALSE)) {
9747 for(c = basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base)); c!=WEOF;
9748 c = basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base))) {
9749 state = IOSTATE_goodbit;
9750 if(basic_streambuf_wchar_sputc(streambuf, c) == WEOF)
9754 basic_istream_wchar_sentry_destroy(this);
9756 basic_ios_wchar_setstate(base, state | (c==WEOF ? IOSTATE_eofbit : IOSTATE_goodbit));
9760 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
9761 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
9762 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
9763 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
9764 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func, 8)
9765 basic_istream_wchar* __thiscall basic_istream_wchar_read_func(basic_istream_wchar *this,
9766 basic_istream_wchar* (__cdecl *pfunc)(basic_istream_wchar*))
9768 TRACE("(%p %p)\n", this, pfunc);
9773 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z */
9774 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z */
9775 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z */
9776 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z */
9777 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func_basic_ios, 8)
9778 basic_istream_wchar* __thiscall basic_istream_wchar_read_func_basic_ios(basic_istream_wchar *this,
9779 basic_ios_wchar* (__cdecl *pfunc)(basic_ios_wchar*))
9781 TRACE("(%p %p)\n", this, pfunc);
9782 pfunc(basic_istream_wchar_get_basic_ios(this));
9786 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
9787 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
9788 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
9789 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
9790 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func_ios_base, 8)
9791 basic_istream_wchar* __thiscall basic_istream_wchar_read_func_ios_base(
9792 basic_istream_wchar *this, ios_base* (__cdecl *pfunc)(ios_base*))
9794 TRACE("(%p %p)\n", this, pfunc);
9795 pfunc(&basic_istream_wchar_get_basic_ios(this)->base);
9799 static inline basic_ios_char* basic_iostream_char_to_basic_ios(basic_iostream_char *ptr)
9801 return (basic_ios_char*)((char*)ptr+basic_iostream_char_vbtable1[1]);
9804 static inline basic_iostream_char* basic_iostream_char_from_basic_ios(basic_ios_char *ptr)
9806 return (basic_iostream_char*)((char*)ptr-basic_iostream_char_vbtable1[1]);
9809 /* ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
9810 /* ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
9811 DEFINE_THISCALL_WRAPPER(basic_iostream_char_ctor, 12)
9812 basic_iostream_char* __thiscall basic_iostream_char_ctor(basic_iostream_char *this, basic_streambuf_char *strbuf, MSVCP_bool virt_init)
9814 basic_ios_char *basic_ios;
9816 TRACE("(%p %p %d)\n", this, strbuf, virt_init);
9819 this->base1.vbtable = basic_iostream_char_vbtable1;
9820 this->base2.vbtable = basic_iostream_char_vbtable2;
9821 basic_ios = basic_istream_char_get_basic_ios(&this->base1);
9822 basic_ios_char_ctor(basic_ios);
9824 basic_ios = basic_istream_char_get_basic_ios(&this->base1);
9827 basic_ios->base.vtable = &MSVCP_basic_iostream_char_vtable;
9829 basic_istream_char_ctor(&this->base1, strbuf, FALSE, FALSE);
9830 basic_ostream_char_ctor_uninitialized(&this->base2, 0, FALSE, FALSE);
9834 /* ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UAE@XZ */
9835 /* ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
9836 DEFINE_THISCALL_WRAPPER(basic_iostream_char_dtor, 4)
9837 void __thiscall basic_iostream_char_dtor(basic_ios_char *base)
9839 basic_iostream_char *this = basic_iostream_char_from_basic_ios(base);
9841 TRACE("(%p)\n", this);
9842 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base2));
9843 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base1));
9846 /* ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
9847 /* ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
9848 DEFINE_THISCALL_WRAPPER(basic_iostream_char_vbase_dtor, 4)
9849 void __thiscall basic_iostream_char_vbase_dtor(basic_iostream_char *this)
9851 TRACE("(%p)\n", this);
9852 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(this));
9853 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base1));
9856 DEFINE_THISCALL_WRAPPER(basic_iostream_char_vector_dtor, 8)
9857 basic_iostream_char* __thiscall basic_iostream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
9859 basic_iostream_char *this = basic_iostream_char_from_basic_ios(base);
9861 TRACE("(%p %x)\n", this, flags);
9864 /* we have an array, with the number of elements stored before the first object */
9865 INT_PTR i, *ptr = (INT_PTR *)this-1;
9867 for(i=*ptr-1; i>=0; i--)
9868 basic_iostream_char_vbase_dtor(this+i);
9869 MSVCRT_operator_delete(ptr);
9871 basic_iostream_char_vbase_dtor(this);
9873 MSVCRT_operator_delete(this);
9879 static inline basic_ios_wchar* basic_iostream_wchar_to_basic_ios(basic_iostream_wchar *ptr)
9881 return (basic_ios_wchar*)((char*)ptr+basic_iostream_wchar_vbtable1[1]);
9884 static inline basic_iostream_wchar* basic_iostream_wchar_from_basic_ios(basic_ios_wchar *ptr)
9886 return (basic_iostream_wchar*)((char*)ptr-basic_iostream_wchar_vbtable1[1]);
9889 /* ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
9890 /* ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
9891 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_ctor, 12)
9892 basic_iostream_wchar* __thiscall basic_iostream_wchar_ctor(basic_iostream_wchar *this,
9893 basic_streambuf_wchar *strbuf, MSVCP_bool virt_init)
9895 basic_ios_wchar *basic_ios;
9897 TRACE("(%p %p %d)\n", this, strbuf, virt_init);
9900 this->base1.vbtable = basic_iostream_wchar_vbtable1;
9901 this->base2.vbtable = basic_iostream_wchar_vbtable2;
9902 basic_ios = basic_istream_wchar_get_basic_ios(&this->base1);
9903 basic_ios_wchar_ctor(basic_ios);
9905 basic_ios = basic_istream_wchar_get_basic_ios(&this->base1);
9908 basic_istream_wchar_ctor(&this->base1, strbuf, FALSE, FALSE);
9909 basic_ostream_wchar_ctor_uninitialized(&this->base2, 0, FALSE, FALSE);
9911 basic_ios->base.vtable = &MSVCP_basic_iostream_wchar_vtable;
9915 /* ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
9916 /* ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
9917 DEFINE_THISCALL_WRAPPER(basic_iostream_short_ctor, 12)
9918 basic_iostream_wchar* __thiscall basic_iostream_short_ctor(basic_iostream_wchar *this,
9919 basic_streambuf_wchar *strbuf, MSVCP_bool virt_init)
9921 basic_iostream_wchar_ctor(this, strbuf, virt_init);
9922 basic_istream_wchar_get_basic_ios(&this->base1)->base.vtable = &MSVCP_basic_iostream_short_vtable;
9926 /* ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
9927 /* ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
9928 /* ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UAE@XZ */
9929 /* ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
9930 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_dtor, 4)
9931 void __thiscall basic_iostream_wchar_dtor(basic_ios_wchar *base)
9933 basic_iostream_wchar *this = basic_iostream_wchar_from_basic_ios(base);
9935 TRACE("(%p)\n", this);
9936 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base2));
9937 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base1));
9940 /* ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
9941 /* ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
9942 /* ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
9943 /* ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
9944 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_vbase_dtor, 4)
9945 void __thiscall basic_iostream_wchar_vbase_dtor(basic_iostream_wchar *this)
9947 TRACE("(%p)\n", this);
9948 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(this));
9949 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base1));
9952 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_vector_dtor, 8)
9953 basic_iostream_wchar* __thiscall basic_iostream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
9955 basic_iostream_wchar *this = basic_iostream_wchar_from_basic_ios(base);
9957 TRACE("(%p %x)\n", this, flags);
9960 /* we have an array, with the number of elements stored before the first object */
9961 INT_PTR i, *ptr = (INT_PTR *)this-1;
9963 for(i=*ptr-1; i>=0; i--)
9964 basic_iostream_wchar_vbase_dtor(this+i);
9965 MSVCRT_operator_delete(ptr);
9967 basic_iostream_wchar_vbase_dtor(this);
9969 MSVCRT_operator_delete(this);
9975 static inline basic_ios_char* basic_ofstream_char_to_basic_ios(basic_ofstream_char *ptr)
9977 return (basic_ios_char*)((char*)ptr+basic_ofstream_char_vbtable[1]);
9980 static inline basic_ofstream_char* basic_ofstream_char_from_basic_ios(basic_ios_char *ptr)
9982 return (basic_ofstream_char*)((char*)ptr-basic_ofstream_char_vbtable[1]);
9985 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
9986 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
9987 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor, 8)
9988 basic_ofstream_char* __thiscall basic_ofstream_char_ctor(basic_ofstream_char *this, MSVCP_bool virt_init)
9990 basic_ios_char *basic_ios;
9992 TRACE("(%p %d)\n", this, virt_init);
9995 this->base.vbtable = basic_ofstream_char_vbtable;
9996 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
9997 basic_ios_char_ctor(basic_ios);
9999 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10002 basic_filebuf_char_ctor(&this->filebuf);
10003 basic_ostream_char_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10004 basic_ios->base.vtable = &MSVCP_basic_ofstream_char_vtable;
10008 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
10009 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
10010 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_file, 12)
10011 basic_ofstream_char* __thiscall basic_ofstream_char_ctor_file(
10012 basic_ofstream_char *this, FILE *file, MSVCP_bool virt_init)
10014 basic_ios_char *basic_ios;
10016 TRACE("(%p %p %d)\n", this, file, virt_init);
10019 this->base.vbtable = basic_ofstream_char_vbtable;
10020 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10021 basic_ios_char_ctor(basic_ios);
10023 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10026 basic_filebuf_char_ctor_file(&this->filebuf, file);
10027 basic_ostream_char_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10028 basic_ios->base.vtable = &MSVCP_basic_ofstream_char_vtable;
10032 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
10033 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
10034 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_name, 20)
10035 basic_ofstream_char* __thiscall basic_ofstream_char_ctor_name(basic_ofstream_char *this,
10036 const char *name, int mode, int prot, MSVCP_bool virt_init)
10038 TRACE("(%p %s %d %d %d)\n", this, name, mode, prot, virt_init);
10040 basic_ofstream_char_ctor(this, virt_init);
10042 if(!basic_filebuf_char_open(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10043 basic_ios_char *basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10044 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10049 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
10050 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
10051 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
10052 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
10053 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_name_wchar, 20)
10054 basic_ofstream_char* __thiscall basic_ofstream_char_ctor_name_wchar(basic_ofstream_char *this,
10055 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
10057 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name), mode, prot, virt_init);
10059 basic_ofstream_char_ctor(this, virt_init);
10061 if(!basic_filebuf_char_open_wchar(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10062 basic_ios_char *basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10063 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10068 /* ??1?$basic_ofstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
10069 /* ??1?$basic_ofstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
10070 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_dtor, 4)
10071 void __thiscall basic_ofstream_char_dtor(basic_ios_char *base)
10073 basic_ofstream_char *this = basic_ofstream_char_from_basic_ios(base);
10075 TRACE("(%p)\n", this);
10077 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base));
10078 basic_filebuf_char_dtor(&this->filebuf);
10081 /* ??_D?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
10082 /* ??_D?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
10083 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_vbase_dtor, 4)
10084 void __thiscall basic_ofstream_char_vbase_dtor(basic_ofstream_char *this)
10086 TRACE("(%p)\n", this);
10088 basic_ofstream_char_dtor(basic_ofstream_char_to_basic_ios(this));
10089 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(&this->base));
10092 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_vector_dtor, 8)
10093 basic_ofstream_char* __thiscall basic_ofstream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
10095 basic_ofstream_char *this = basic_ofstream_char_from_basic_ios(base);
10097 TRACE("(%p %x)\n", this, flags);
10100 /* we have an array, with the number of elements stored before the first object */
10101 INT_PTR i, *ptr = (INT_PTR *)this-1;
10103 for(i=*ptr-1; i>=0; i--)
10104 basic_ofstream_char_vbase_dtor(this+i);
10105 MSVCRT_operator_delete(ptr);
10107 basic_ofstream_char_vbase_dtor(this);
10109 MSVCRT_operator_delete(this);
10115 /* ?close@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
10116 /* ?close@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
10117 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_close, 4)
10118 void __thiscall basic_ofstream_char_close(basic_ofstream_char *this)
10120 TRACE("(%p)\n", this);
10122 if(!basic_filebuf_char_close(&this->filebuf)) {
10123 basic_ios_char *basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10124 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10128 /* ?is_open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
10129 /* ?is_open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
10130 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_is_open, 4)
10131 MSVCP_bool __thiscall basic_ofstream_char_is_open(const basic_ofstream_char *this)
10133 TRACE("(%p)\n", this);
10134 return basic_filebuf_char_is_open(&this->filebuf);
10137 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
10138 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
10139 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open, 16)
10140 void __thiscall basic_ofstream_char_open(basic_ofstream_char *this,
10141 const char *name, int mode, int prot)
10143 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
10145 if(!basic_filebuf_char_open(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10146 basic_ios_char *basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10147 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10151 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
10152 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
10153 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_old, 12)
10154 void __thiscall basic_ofstream_char_open_old(basic_ofstream_char *this,
10155 const char *name, unsigned int mode)
10157 basic_ofstream_char_open(this, name, mode, _SH_DENYNO);
10160 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
10161 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
10162 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
10163 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
10164 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_wchar, 16)
10165 void __thiscall basic_ofstream_char_open_wchar(basic_ofstream_char *this,
10166 const wchar_t *name, int mode, int prot)
10168 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
10170 if(!basic_filebuf_char_open_wchar(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10171 basic_ios_char *basic_ios = basic_ostream_char_get_basic_ios(&this->base);
10172 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10176 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
10177 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
10178 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
10179 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
10180 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_wchar_old, 12)
10181 void __thiscall basic_ofstream_char_open_wchar_old(basic_ofstream_char *this,
10182 const wchar_t *name, unsigned int mode)
10184 basic_ofstream_char_open_wchar(this, name, mode, _SH_DENYNO);
10187 /* ?rdbuf@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
10188 /* ?rdbuf@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
10189 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_rdbuf, 4)
10190 basic_filebuf_char* __thiscall basic_ofstream_char_rdbuf(const basic_ofstream_char *this)
10192 TRACE("(%p)\n", this);
10193 return (basic_filebuf_char*)&this->filebuf;
10196 static inline basic_ios_wchar* basic_ofstream_wchar_to_basic_ios(basic_ofstream_wchar *ptr)
10198 return (basic_ios_wchar*)((char*)ptr+basic_ofstream_wchar_vbtable[1]);
10201 static inline basic_ofstream_wchar* basic_ofstream_wchar_from_basic_ios(basic_ios_wchar *ptr)
10203 return (basic_ofstream_wchar*)((char*)ptr-basic_ofstream_wchar_vbtable[1]);
10206 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
10207 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
10208 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor, 8)
10209 basic_ofstream_wchar* __thiscall basic_ofstream_wchar_ctor(basic_ofstream_wchar *this, MSVCP_bool virt_init)
10211 basic_ios_wchar *basic_ios;
10213 TRACE("(%p %d)\n", this, virt_init);
10216 this->base.vbtable = basic_ofstream_wchar_vbtable;
10217 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10218 basic_ios_wchar_ctor(basic_ios);
10220 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10223 basic_filebuf_wchar_ctor(&this->filebuf);
10224 basic_ostream_wchar_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10225 basic_ios->base.vtable = &MSVCP_basic_ofstream_wchar_vtable;
10229 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
10230 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
10231 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor, 8)
10232 basic_ofstream_wchar* __thiscall basic_ofstream_short_ctor(basic_ofstream_wchar *this, MSVCP_bool virt_init)
10234 basic_ofstream_wchar_ctor(this, virt_init);
10235 basic_ostream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ofstream_short_vtable;
10239 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
10240 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
10241 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_file, 12)
10242 basic_ofstream_wchar* __thiscall basic_ofstream_wchar_ctor_file(
10243 basic_ofstream_wchar *this, FILE *file, MSVCP_bool virt_init)
10245 basic_ios_wchar *basic_ios;
10247 TRACE("(%p %p %d)\n", this, file, virt_init);
10250 this->base.vbtable = basic_ofstream_wchar_vbtable;
10251 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10252 basic_ios_wchar_ctor(basic_ios);
10254 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10257 basic_filebuf_wchar_ctor_file(&this->filebuf, file);
10258 basic_ostream_wchar_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10259 basic_ios->base.vtable = &MSVCP_basic_ofstream_wchar_vtable;
10263 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
10264 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
10265 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_file, 12)
10266 basic_ofstream_wchar* __thiscall basic_ofstream_short_ctor_file(
10267 basic_ofstream_wchar *this, FILE *file, MSVCP_bool virt_init)
10269 basic_ofstream_wchar_ctor_file(this, file, virt_init);
10270 basic_ostream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ofstream_short_vtable;
10274 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDHH@Z */
10275 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDHH@Z */
10276 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_name, 20)
10277 basic_ofstream_wchar* __thiscall basic_ofstream_wchar_ctor_name(basic_ofstream_wchar *this,
10278 const char *name, int mode, int prot, MSVCP_bool virt_init)
10280 TRACE("(%p %s %d %d %d)\n", this, name, mode, prot, virt_init);
10282 basic_ofstream_wchar_ctor(this, virt_init);
10284 if(!basic_filebuf_wchar_open(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10285 basic_ios_wchar *basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10286 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10291 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PBDHH@Z */
10292 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDHH@Z */
10293 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_name, 20)
10294 basic_ofstream_wchar* __thiscall basic_ofstream_short_ctor_name(basic_ofstream_wchar *this,
10295 const char *name, int mode, int prot, MSVCP_bool virt_init)
10297 basic_ofstream_wchar_ctor_name(this, name, mode, prot, virt_init);
10298 basic_ostream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ofstream_short_vtable;
10302 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
10303 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
10304 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
10305 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
10306 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_name_wchar, 20)
10307 basic_ofstream_wchar* __thiscall basic_ofstream_wchar_ctor_name_wchar(basic_ofstream_wchar *this,
10308 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
10310 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name), mode, prot, virt_init);
10312 basic_ofstream_wchar_ctor(this, virt_init);
10314 if(!basic_filebuf_wchar_open_wchar(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10315 basic_ios_wchar *basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10316 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10321 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
10322 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
10323 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
10324 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
10325 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_name_wchar, 20)
10326 basic_ofstream_wchar* __thiscall basic_ofstream_short_ctor_name_wchar(basic_ofstream_wchar *this,
10327 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
10329 basic_ofstream_wchar_ctor_name_wchar(this, name, mode, prot, virt_init);
10330 basic_ostream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ofstream_short_vtable;
10334 /* ??1?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
10335 /* ??1?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
10336 /* ??1?$basic_ofstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
10337 /* ??1?$basic_ofstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
10338 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_dtor, 4)
10339 void __thiscall basic_ofstream_wchar_dtor(basic_ios_wchar *base)
10341 basic_ofstream_wchar *this = basic_ofstream_wchar_from_basic_ios(base);
10343 TRACE("(%p)\n", this);
10345 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base));
10346 basic_filebuf_wchar_dtor(&this->filebuf);
10349 /* ??_D?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
10350 /* ??_D?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
10351 /* ??_D?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
10352 /* ??_D?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
10353 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_vbase_dtor, 4)
10354 void __thiscall basic_ofstream_wchar_vbase_dtor(basic_ofstream_wchar *this)
10356 TRACE("(%p)\n", this);
10358 basic_ofstream_wchar_dtor(basic_ofstream_wchar_to_basic_ios(this));
10359 basic_ios_wchar_dtor(basic_ostream_wchar_get_basic_ios(&this->base));
10362 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_vector_dtor, 8)
10363 basic_ofstream_wchar* __thiscall basic_ofstream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
10365 basic_ofstream_wchar *this = basic_ofstream_wchar_from_basic_ios(base);
10367 TRACE("(%p %x)\n", this, flags);
10370 /* we have an array, with the number of elements stored before the first object */
10371 INT_PTR i, *ptr = (INT_PTR *)this-1;
10373 for(i=*ptr-1; i>=0; i--)
10374 basic_ofstream_wchar_vbase_dtor(this+i);
10375 MSVCRT_operator_delete(ptr);
10377 basic_ofstream_wchar_vbase_dtor(this);
10379 MSVCRT_operator_delete(this);
10385 /* ?close@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
10386 /* ?close@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
10387 /* ?close@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
10388 /* ?close@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
10389 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_close, 4)
10390 void __thiscall basic_ofstream_wchar_close(basic_ofstream_wchar *this)
10392 TRACE("(%p)\n", this);
10394 if(!basic_filebuf_wchar_close(&this->filebuf)) {
10395 basic_ios_wchar *basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10396 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10400 /* ?is_open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
10401 /* ?is_open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
10402 /* ?is_open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
10403 /* ?is_open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
10404 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_is_open, 4)
10405 MSVCP_bool __thiscall basic_ofstream_wchar_is_open(const basic_ofstream_wchar *this)
10407 TRACE("(%p)\n", this);
10408 return basic_filebuf_wchar_is_open(&this->filebuf);
10411 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
10412 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
10413 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
10414 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
10415 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open, 16)
10416 void __thiscall basic_ofstream_wchar_open(basic_ofstream_wchar *this,
10417 const char *name, int mode, int prot)
10419 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
10421 if(!basic_filebuf_wchar_open(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10422 basic_ios_wchar *basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10423 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10427 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
10428 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
10429 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
10430 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
10431 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_old, 12)
10432 void __thiscall basic_ofstream_wchar_open_old(basic_ofstream_wchar *this,
10433 const char *name, unsigned int mode)
10435 basic_ofstream_wchar_open(this, name, mode, _SH_DENYNO);
10438 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
10439 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
10440 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
10441 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
10442 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
10443 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
10444 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
10445 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
10446 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_wchar, 16)
10447 void __thiscall basic_ofstream_wchar_open_wchar(basic_ofstream_wchar *this,
10448 const wchar_t *name, int mode, int prot)
10450 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
10452 if(!basic_filebuf_wchar_open_wchar(&this->filebuf, name, mode|OPENMODE_out, prot)) {
10453 basic_ios_wchar *basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
10454 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10458 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
10459 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
10460 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
10461 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
10462 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
10463 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
10464 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
10465 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
10466 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_wchar_old, 12)
10467 void __thiscall basic_ofstream_wchar_open_wchar_old(basic_ofstream_wchar *this,
10468 const wchar_t *name, unsigned int mode)
10470 basic_ofstream_wchar_open_wchar(this, name, mode, _SH_DENYNO);
10473 /* ?rdbuf@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
10474 /* ?rdbuf@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
10475 /* ?rdbuf@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
10476 /* ?rdbuf@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
10477 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_rdbuf, 4)
10478 basic_filebuf_wchar* __thiscall basic_ofstream_wchar_rdbuf(const basic_ofstream_wchar *this)
10480 TRACE("(%p)\n", this);
10481 return (basic_filebuf_wchar*)&this->filebuf;
10484 static inline basic_ios_char* basic_ifstream_char_to_basic_ios(basic_ifstream_char *ptr)
10486 return (basic_ios_char*)((char*)ptr+basic_ifstream_char_vbtable[1]);
10489 static inline basic_ifstream_char* basic_ifstream_char_from_basic_ios(basic_ios_char *ptr)
10491 return (basic_ifstream_char*)((char*)ptr-basic_ifstream_char_vbtable[1]);
10494 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
10495 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
10496 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor, 8)
10497 basic_ifstream_char* __thiscall basic_ifstream_char_ctor(basic_ifstream_char *this, MSVCP_bool virt_init)
10499 basic_ios_char *basic_ios;
10501 TRACE("(%p %d)\n", this, virt_init);
10504 this->base.vbtable = basic_ifstream_char_vbtable;
10505 basic_ios = basic_istream_char_get_basic_ios(&this->base);
10506 basic_ios_char_ctor(basic_ios);
10508 basic_ios = basic_istream_char_get_basic_ios(&this->base);
10511 basic_filebuf_char_ctor(&this->filebuf);
10512 basic_istream_char_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10513 basic_ios->base.vtable = &MSVCP_basic_ifstream_char_vtable;
10517 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
10518 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
10519 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_file, 12)
10520 basic_ifstream_char* __thiscall basic_ifstream_char_ctor_file(
10521 basic_ifstream_char *this, FILE *file, MSVCP_bool virt_init)
10523 basic_ios_char *basic_ios;
10525 TRACE("(%p %p %d)\n", this, file, virt_init);
10528 this->base.vbtable = basic_ifstream_char_vbtable;
10529 basic_ios = basic_istream_char_get_basic_ios(&this->base);
10530 basic_ios_char_ctor(basic_ios);
10532 basic_ios = basic_istream_char_get_basic_ios(&this->base);
10535 basic_filebuf_char_ctor_file(&this->filebuf, file);
10536 basic_istream_char_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10537 basic_ios->base.vtable = &MSVCP_basic_ifstream_char_vtable;
10541 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
10542 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
10543 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name, 20)
10544 basic_ifstream_char* __thiscall basic_ifstream_char_ctor_name(basic_ifstream_char *this,
10545 const char *name, int mode, int prot, MSVCP_bool virt_init)
10547 TRACE("(%p %s %d %d %d)\n", this, name, mode, prot, virt_init);
10549 basic_ifstream_char_ctor(this, virt_init);
10551 if(!basic_filebuf_char_open(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10552 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base);
10553 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10558 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
10559 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
10560 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
10561 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
10562 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name_wchar, 20)
10563 basic_ifstream_char* __thiscall basic_ifstream_char_ctor_name_wchar(basic_ifstream_char *this,
10564 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
10566 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name), mode, prot, virt_init);
10568 basic_ifstream_char_ctor(this, virt_init);
10570 if(!basic_filebuf_char_open_wchar(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10571 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base);
10572 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10577 /* ??1?$basic_ifstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
10578 /* ??1?$basic_ifstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
10579 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_dtor, 4)
10580 void __thiscall basic_ifstream_char_dtor(basic_ios_char *base)
10582 basic_ifstream_char *this = basic_ifstream_char_from_basic_ios(base);
10584 TRACE("(%p)\n", this);
10586 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base));
10587 basic_filebuf_char_dtor(&this->filebuf);
10590 /* ??_D?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
10591 /* ??_D?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
10592 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_vbase_dtor, 4)
10593 void __thiscall basic_ifstream_char_vbase_dtor(basic_ifstream_char *this)
10595 TRACE("(%p)\n", this);
10597 basic_ifstream_char_dtor(basic_ifstream_char_to_basic_ios(this));
10598 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base));
10601 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_vector_dtor, 8)
10602 basic_ifstream_char* __thiscall basic_ifstream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
10604 basic_ifstream_char *this = basic_ifstream_char_from_basic_ios(base);
10606 TRACE("(%p %x)\n", this, flags);
10609 /* we have an array, with the number of elements stored before the first object */
10610 INT_PTR i, *ptr = (INT_PTR *)this-1;
10612 for(i=*ptr-1; i>=0; i--)
10613 basic_ifstream_char_vbase_dtor(this+i);
10614 MSVCRT_operator_delete(ptr);
10616 basic_ifstream_char_vbase_dtor(this);
10618 MSVCRT_operator_delete(this);
10624 /* ?close@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
10625 /* ?close@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
10626 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_close, 4)
10627 void __thiscall basic_ifstream_char_close(basic_ifstream_char *this)
10629 TRACE("(%p)\n", this);
10631 if(!basic_filebuf_char_close(&this->filebuf)) {
10632 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base);
10633 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10637 /* ?is_open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
10638 /* ?is_open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
10639 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_is_open, 4)
10640 MSVCP_bool __thiscall basic_ifstream_char_is_open(const basic_ifstream_char *this)
10642 TRACE("(%p)\n", this);
10643 return basic_filebuf_char_is_open(&this->filebuf);
10646 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
10647 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
10648 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open, 16)
10649 void __thiscall basic_ifstream_char_open(basic_ifstream_char *this,
10650 const char *name, int mode, int prot)
10652 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
10654 if(!basic_filebuf_char_open(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10655 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base);
10656 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10660 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
10661 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
10662 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_old, 12)
10663 void __thiscall basic_ifstream_char_open_old(basic_ifstream_char *this,
10664 const char *name, unsigned int mode)
10666 basic_ifstream_char_open(this, name, mode, _SH_DENYNO);
10669 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
10670 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
10671 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
10672 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
10673 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_wchar, 16)
10674 void __thiscall basic_ifstream_char_open_wchar(basic_ifstream_char *this,
10675 const wchar_t *name, int mode, int prot)
10677 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
10679 if(!basic_filebuf_char_open_wchar(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10680 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base);
10681 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
10685 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
10686 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
10687 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
10688 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
10689 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_wchar_old, 12)
10690 void __thiscall basic_ifstream_char_open_wchar_old(basic_ifstream_char *this,
10691 const wchar_t *name, unsigned int mode)
10693 basic_ifstream_char_open_wchar(this, name, mode, _SH_DENYNO);
10696 /* ?rdbuf@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
10697 /* ?rdbuf@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
10698 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_rdbuf, 4)
10699 basic_filebuf_char* __thiscall basic_ifstream_char_rdbuf(const basic_ifstream_char *this)
10701 TRACE("(%p)\n", this);
10702 return (basic_filebuf_char*)&this->filebuf;
10705 static inline basic_ios_wchar* basic_ifstream_wchar_to_basic_ios(basic_ifstream_wchar *ptr)
10707 return (basic_ios_wchar*)((char*)ptr+basic_ifstream_wchar_vbtable[1]);
10710 static inline basic_ifstream_wchar* basic_ifstream_wchar_from_basic_ios(basic_ios_wchar *ptr)
10712 return (basic_ifstream_wchar*)((char*)ptr-basic_ifstream_wchar_vbtable[1]);
10715 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
10716 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
10717 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor, 8)
10718 basic_ifstream_wchar* __thiscall basic_ifstream_wchar_ctor(basic_ifstream_wchar *this, MSVCP_bool virt_init)
10720 basic_ios_wchar *basic_ios;
10722 TRACE("(%p %d)\n", this, virt_init);
10725 this->base.vbtable = basic_ifstream_wchar_vbtable;
10726 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10727 basic_ios_wchar_ctor(basic_ios);
10729 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10732 basic_filebuf_wchar_ctor(&this->filebuf);
10733 basic_istream_wchar_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10734 basic_ios->base.vtable = &MSVCP_basic_ifstream_wchar_vtable;
10738 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
10739 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
10740 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor, 8)
10741 basic_ifstream_wchar* __thiscall basic_ifstream_short_ctor(basic_ifstream_wchar *this, MSVCP_bool virt_init)
10743 basic_ifstream_wchar_ctor(this, virt_init);
10744 basic_istream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ifstream_short_vtable;
10748 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
10749 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
10750 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_file, 12)
10751 basic_ifstream_wchar* __thiscall basic_ifstream_wchar_ctor_file(
10752 basic_ifstream_wchar *this, FILE *file, MSVCP_bool virt_init)
10754 basic_ios_wchar *basic_ios;
10756 TRACE("(%p %p %d)\n", this, file, virt_init);
10759 this->base.vbtable = basic_ifstream_wchar_vbtable;
10760 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10761 basic_ios_wchar_ctor(basic_ios);
10763 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10766 basic_filebuf_wchar_ctor_file(&this->filebuf, file);
10767 basic_istream_wchar_ctor(&this->base, &this->filebuf.base, FALSE, FALSE);
10768 basic_ios->base.vtable = &MSVCP_basic_ifstream_wchar_vtable;
10772 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
10773 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
10774 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_file, 12)
10775 basic_ifstream_wchar* __thiscall basic_ifstream_short_ctor_file(
10776 basic_ifstream_wchar *this, FILE *file, MSVCP_bool virt_init)
10778 basic_ifstream_wchar_ctor_file(this, file, virt_init);
10779 basic_istream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ifstream_short_vtable;
10783 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDHH@Z */
10784 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDHH@Z */
10785 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name, 20)
10786 basic_ifstream_wchar* __thiscall basic_ifstream_wchar_ctor_name(basic_ifstream_wchar *this,
10787 const char *name, int mode, int prot, MSVCP_bool virt_init)
10789 TRACE("(%p %s %d %d %d)\n", this, name, mode, prot, virt_init);
10791 basic_ifstream_wchar_ctor(this, virt_init);
10793 if(!basic_filebuf_wchar_open(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10794 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10795 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10800 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBDHH@Z */
10801 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDHH@Z */
10802 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name, 20)
10803 basic_ifstream_wchar* __thiscall basic_ifstream_short_ctor_name(basic_ifstream_wchar *this,
10804 const char *name, int mode, int prot, MSVCP_bool virt_init)
10806 basic_ifstream_wchar_ctor_name(this, name, mode, prot, virt_init);
10807 basic_istream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ifstream_short_vtable;
10811 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
10812 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
10813 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
10814 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
10815 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name_wchar, 20)
10816 basic_ifstream_wchar* __thiscall basic_ifstream_wchar_ctor_name_wchar(basic_ifstream_wchar *this,
10817 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
10819 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name), mode, prot, virt_init);
10821 basic_ifstream_wchar_ctor(this, virt_init);
10823 if(!basic_filebuf_wchar_open_wchar(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10824 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10825 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10830 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
10831 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
10832 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
10833 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
10834 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name_wchar, 20)
10835 basic_ifstream_wchar* __thiscall basic_ifstream_short_ctor_name_wchar(basic_ifstream_wchar *this,
10836 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
10838 basic_ifstream_wchar_ctor_name_wchar(this, name, mode, prot, virt_init);
10839 basic_istream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ifstream_short_vtable;
10843 /* ??1?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
10844 /* ??1?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
10845 /* ??1?$basic_ifstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
10846 /* ??1?$basic_ifstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
10847 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_dtor, 4)
10848 void __thiscall basic_ifstream_wchar_dtor(basic_ios_wchar *base)
10850 basic_ifstream_wchar *this = basic_ifstream_wchar_from_basic_ios(base);
10852 TRACE("(%p)\n", this);
10854 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base));
10855 basic_filebuf_wchar_dtor(&this->filebuf);
10858 /* ??_D?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
10859 /* ??_D?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
10860 /* ??_D?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
10861 /* ??_D?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
10862 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_vbase_dtor, 4)
10863 void __thiscall basic_ifstream_wchar_vbase_dtor(basic_ifstream_wchar *this)
10865 TRACE("(%p)\n", this);
10867 basic_ifstream_wchar_dtor(basic_ifstream_wchar_to_basic_ios(this));
10868 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base));
10871 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_vector_dtor, 8)
10872 basic_ifstream_wchar* __thiscall basic_ifstream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
10874 basic_ifstream_wchar *this = basic_ifstream_wchar_from_basic_ios(base);
10876 TRACE("(%p %x)\n", this, flags);
10879 /* we have an array, with the number of elements stored before the first object */
10880 INT_PTR i, *ptr = (INT_PTR *)this-1;
10882 for(i=*ptr-1; i>=0; i--)
10883 basic_ifstream_wchar_vbase_dtor(this+i);
10884 MSVCRT_operator_delete(ptr);
10886 basic_ifstream_wchar_vbase_dtor(this);
10888 MSVCRT_operator_delete(this);
10894 /* ?close@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
10895 /* ?close@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
10896 /* ?close@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
10897 /* ?close@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
10898 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_close, 4)
10899 void __thiscall basic_ifstream_wchar_close(basic_ifstream_wchar *this)
10901 TRACE("(%p)\n", this);
10903 if(!basic_filebuf_wchar_close(&this->filebuf)) {
10904 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10905 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10909 /* ?is_open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
10910 /* ?is_open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
10911 /* ?is_open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
10912 /* ?is_open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
10913 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_is_open, 4)
10914 MSVCP_bool __thiscall basic_ifstream_wchar_is_open(const basic_ifstream_wchar *this)
10916 TRACE("(%p)\n", this);
10917 return basic_filebuf_wchar_is_open(&this->filebuf);
10920 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
10921 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
10922 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
10923 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
10924 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open, 16)
10925 void __thiscall basic_ifstream_wchar_open(basic_ifstream_wchar *this,
10926 const char *name, int mode, int prot)
10928 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
10930 if(!basic_filebuf_wchar_open(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10931 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10932 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10936 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
10937 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
10938 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
10939 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
10940 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_old, 12)
10941 void __thiscall basic_ifstream_wchar_open_old(basic_ifstream_wchar *this,
10942 const char *name, unsigned int mode)
10944 basic_ifstream_wchar_open(this, name, mode, _SH_DENYNO);
10947 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
10948 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
10949 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
10950 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
10951 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
10952 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
10953 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
10954 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
10955 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_wchar, 16)
10956 void __thiscall basic_ifstream_wchar_open_wchar(basic_ifstream_wchar *this,
10957 const wchar_t *name, int mode, int prot)
10959 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
10961 if(!basic_filebuf_wchar_open_wchar(&this->filebuf, name, mode|OPENMODE_in, prot)) {
10962 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
10963 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
10967 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
10968 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
10969 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
10970 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
10971 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
10972 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
10973 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
10974 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
10975 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_wchar_old, 12)
10976 void __thiscall basic_ifstream_wchar_open_wchar_old(basic_ifstream_wchar *this,
10977 const wchar_t *name, unsigned int mode)
10979 basic_ifstream_wchar_open_wchar(this, name, mode, _SH_DENYNO);
10982 /* ?rdbuf@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
10983 /* ?rdbuf@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
10984 /* ?rdbuf@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
10985 /* ?rdbuf@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
10986 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_rdbuf, 4)
10987 basic_filebuf_wchar* __thiscall basic_ifstream_wchar_rdbuf(const basic_ifstream_wchar *this)
10989 TRACE("(%p)\n", this);
10990 return (basic_filebuf_wchar*)&this->filebuf;
10993 static inline basic_ios_char* basic_fstream_char_to_basic_ios(basic_fstream_char *ptr)
10995 return (basic_ios_char*)((char*)ptr+basic_fstream_char_vbtable1[1]);
10998 static inline basic_fstream_char* basic_fstream_char_from_basic_ios(basic_ios_char *ptr)
11000 return (basic_fstream_char*)((char*)ptr-basic_fstream_char_vbtable1[1]);
11003 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
11004 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
11005 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor, 8)
11006 basic_fstream_char* __thiscall basic_fstream_char_ctor(basic_fstream_char *this, MSVCP_bool virt_init)
11008 basic_ios_char *basic_ios;
11010 TRACE("(%p %d)\n", this, virt_init);
11013 this->base.base1.vbtable = basic_fstream_char_vbtable1;
11014 this->base.base2.vbtable = basic_fstream_char_vbtable2;
11015 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11016 basic_ios_char_ctor(basic_ios);
11018 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11021 basic_filebuf_char_ctor(&this->filebuf);
11022 basic_iostream_char_ctor(&this->base, &this->filebuf.base, FALSE);
11023 basic_ios->base.vtable = &MSVCP_basic_fstream_char_vtable;
11027 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
11028 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11029 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_file, 12)
11030 basic_fstream_char* __thiscall basic_fstream_char_ctor_file(basic_fstream_char *this,
11031 FILE *file, MSVCP_bool virt_init)
11033 basic_ios_char *basic_ios;
11035 TRACE("(%p %p %d)\n", this, file, virt_init);
11038 this->base.base1.vbtable = basic_fstream_char_vbtable1;
11039 this->base.base2.vbtable = basic_fstream_char_vbtable2;
11040 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11041 basic_ios_char_ctor(basic_ios);
11043 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11046 basic_filebuf_char_ctor_file(&this->filebuf, file);
11047 basic_iostream_char_ctor(&this->base, &this->filebuf.base, FALSE);
11048 basic_ios->base.vtable = &MSVCP_basic_fstream_char_vtable;
11052 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
11053 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
11054 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name, 20)
11055 basic_fstream_char* __thiscall basic_fstream_char_ctor_name(basic_fstream_char *this,
11056 const char *name, int mode, int prot, MSVCP_bool virt_init)
11058 TRACE("(%p %s %d %d %d)\n", this, name, mode, prot, virt_init);
11060 basic_fstream_char_ctor(this, virt_init);
11062 if(!basic_filebuf_char_open(&this->filebuf, name, mode, prot)) {
11063 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11064 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
11069 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
11070 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
11071 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
11072 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
11073 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name_wchar, 20)
11074 basic_fstream_char* __thiscall basic_fstream_char_ctor_name_wchar(basic_fstream_char *this,
11075 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
11077 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name), mode, prot, virt_init);
11079 basic_fstream_char_ctor(this, virt_init);
11081 if(!basic_filebuf_char_open_wchar(&this->filebuf, name, mode, prot)) {
11082 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11083 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
11088 /* ??1?$basic_fstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
11089 /* ??1?$basic_fstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
11090 DEFINE_THISCALL_WRAPPER(basic_fstream_char_dtor, 4)
11091 void __thiscall basic_fstream_char_dtor(basic_ios_char *base)
11093 basic_fstream_char *this = basic_fstream_char_from_basic_ios(base);
11095 TRACE("(%p)\n", this);
11097 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base));
11098 basic_filebuf_char_dtor(&this->filebuf);
11101 /* ??_D?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11102 /* ??_D?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11103 DEFINE_THISCALL_WRAPPER(basic_fstream_char_vbase_dtor, 4)
11104 void __thiscall basic_fstream_char_vbase_dtor(basic_fstream_char *this)
11106 TRACE("(%p)\n", this);
11108 basic_fstream_char_dtor(basic_fstream_char_to_basic_ios(this));
11109 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base.base1));
11112 DEFINE_THISCALL_WRAPPER(basic_fstream_char_vector_dtor, 8)
11113 basic_fstream_char* __thiscall basic_fstream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
11115 basic_fstream_char *this = basic_fstream_char_from_basic_ios(base);
11117 TRACE("(%p %x)\n", this, flags);
11120 /* we have an array, with the number of elements stored before the first object */
11121 INT_PTR i, *ptr = (INT_PTR *)this-1;
11123 for(i=*ptr-1; i>=0; i--)
11124 basic_fstream_char_vbase_dtor(this+i);
11125 MSVCRT_operator_delete(ptr);
11127 basic_fstream_char_vbase_dtor(this);
11129 MSVCRT_operator_delete(this);
11135 /* ?close@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11136 /* ?close@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11137 DEFINE_THISCALL_WRAPPER(basic_fstream_char_close, 4)
11138 void __thiscall basic_fstream_char_close(basic_fstream_char *this)
11140 TRACE("(%p)\n", this);
11142 if(!basic_filebuf_char_close(&this->filebuf)) {
11143 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11144 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
11148 /* ?is_open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
11149 /* ?is_open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
11150 DEFINE_THISCALL_WRAPPER(basic_fstream_char_is_open, 4)
11151 MSVCP_bool __thiscall basic_fstream_char_is_open(const basic_fstream_char *this)
11153 TRACE("(%p)\n", this);
11154 return basic_filebuf_char_is_open(&this->filebuf);
11157 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
11158 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
11159 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open, 16)
11160 void __thiscall basic_fstream_char_open(basic_fstream_char *this,
11161 const char *name, int mode, int prot)
11163 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
11165 if(!basic_filebuf_char_open(&this->filebuf, name, mode, prot)) {
11166 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11167 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
11171 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
11172 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
11173 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_old, 12)
11174 void __thiscall basic_fstream_char_open_old(basic_fstream_char *this,
11175 const char *name, unsigned int mode)
11177 basic_fstream_char_open(this, name, mode, _SH_DENYNO);
11180 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
11181 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
11182 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
11183 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
11184 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_wchar, 16)
11185 void __thiscall basic_fstream_char_open_wchar(basic_fstream_char *this,
11186 const wchar_t *name, int mode, int prot)
11188 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
11190 if(!basic_filebuf_char_open_wchar(&this->filebuf, name, mode, prot)) {
11191 basic_ios_char *basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
11192 basic_ios_char_setstate(basic_ios, IOSTATE_failbit);
11196 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
11197 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
11198 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
11199 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
11200 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_wchar_old, 12)
11201 void __thiscall basic_fstream_char_open_wchar_old(basic_fstream_char *this,
11202 const wchar_t *name, unsigned int mode)
11204 basic_fstream_char_open_wchar(this, name, mode, _SH_DENYNO);
11207 /* ?rdbuf@?$basic_fstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11208 /* ?rdbuf@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11209 DEFINE_THISCALL_WRAPPER(basic_fstream_char_rdbuf, 4)
11210 basic_filebuf_char* __thiscall basic_fstream_char_rdbuf(const basic_fstream_char *this)
11212 TRACE("(%p)\n", this);
11213 return (basic_filebuf_char*)&this->filebuf;
11216 static inline basic_ios_wchar* basic_fstream_wchar_to_basic_ios(basic_fstream_wchar *ptr)
11218 return (basic_ios_wchar*)((char*)ptr+basic_fstream_wchar_vbtable1[1]);
11221 static inline basic_fstream_wchar* basic_fstream_wchar_from_basic_ios(basic_ios_wchar *ptr)
11223 return (basic_fstream_wchar*)((char*)ptr-basic_fstream_wchar_vbtable1[1]);
11226 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
11227 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
11228 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor, 8)
11229 basic_fstream_wchar* __thiscall basic_fstream_wchar_ctor(basic_fstream_wchar *this, MSVCP_bool virt_init)
11231 basic_ios_wchar *basic_ios;
11233 TRACE("(%p %d)\n", this, virt_init);
11236 this->base.base1.vbtable = basic_fstream_wchar_vbtable1;
11237 this->base.base2.vbtable = basic_fstream_wchar_vbtable2;
11238 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11239 basic_ios_wchar_ctor(basic_ios);
11241 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11244 basic_filebuf_wchar_ctor(&this->filebuf);
11245 basic_iostream_wchar_ctor(&this->base, &this->filebuf.base, FALSE);
11246 basic_ios->base.vtable = &MSVCP_basic_fstream_wchar_vtable;
11250 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
11251 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
11252 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor, 8)
11253 basic_fstream_wchar* __thiscall basic_fstream_short_ctor(basic_fstream_wchar *this, MSVCP_bool virt_init)
11255 basic_fstream_wchar_ctor(this, virt_init);
11256 basic_istream_wchar_get_basic_ios(&this->base.base1)->base.vtable = &MSVCP_basic_fstream_short_vtable;
11260 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
11261 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11262 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_file, 12)
11263 basic_fstream_wchar* __thiscall basic_fstream_wchar_ctor_file(basic_fstream_wchar *this,
11264 FILE *file, MSVCP_bool virt_init)
11266 basic_ios_wchar *basic_ios;
11268 TRACE("(%p %p %d)\n", this, file, virt_init);
11271 this->base.base1.vbtable = basic_fstream_wchar_vbtable1;
11272 this->base.base2.vbtable = basic_fstream_wchar_vbtable2;
11273 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11274 basic_ios_wchar_ctor(basic_ios);
11276 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11279 basic_filebuf_wchar_ctor_file(&this->filebuf, file);
11280 basic_iostream_wchar_ctor(&this->base, &this->filebuf.base, FALSE);
11281 basic_ios->base.vtable = &MSVCP_basic_fstream_wchar_vtable;
11285 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
11286 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11287 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_file, 12)
11288 basic_fstream_wchar* __thiscall basic_fstream_short_ctor_file(basic_fstream_wchar *this,
11289 FILE *file, MSVCP_bool virt_init)
11291 basic_fstream_wchar_ctor_file(this, file, virt_init);
11292 basic_istream_wchar_get_basic_ios(&this->base.base1)->base.vtable = &MSVCP_basic_fstream_short_vtable;
11296 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
11297 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
11298 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name, 20)
11299 basic_fstream_wchar* __thiscall basic_fstream_wchar_ctor_name(basic_fstream_wchar *this,
11300 const char *name, int mode, int prot, MSVCP_bool virt_init)
11302 TRACE("(%p %s %d %d %d)\n", this, name, mode, prot, virt_init);
11304 basic_fstream_wchar_ctor(this, virt_init);
11306 if(!basic_filebuf_wchar_open(&this->filebuf, name, mode, prot)) {
11307 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11308 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
11313 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
11314 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
11315 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name, 20)
11316 basic_fstream_wchar* __thiscall basic_fstream_short_ctor_name(basic_fstream_wchar *this,
11317 const char *name, int mode, int prot, MSVCP_bool virt_init)
11319 basic_fstream_wchar_ctor_name(this, name, mode, prot, virt_init);
11320 basic_istream_wchar_get_basic_ios(&this->base.base1)->base.vtable = &MSVCP_basic_fstream_short_vtable;
11324 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
11325 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
11326 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
11327 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
11328 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name_wchar, 20)
11329 basic_fstream_wchar* __thiscall basic_fstream_wchar_ctor_name_wchar(basic_fstream_wchar *this,
11330 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
11332 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name), mode, prot, virt_init);
11334 basic_fstream_wchar_ctor(this, virt_init);
11336 if(!basic_filebuf_wchar_open_wchar(&this->filebuf, name, mode, prot)) {
11337 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11338 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
11343 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
11344 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
11345 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
11346 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
11347 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name_wchar, 20)
11348 basic_fstream_wchar* __thiscall basic_fstream_short_ctor_name_wchar(basic_fstream_wchar *this,
11349 const wchar_t *name, int mode, int prot, MSVCP_bool virt_init)
11351 basic_fstream_wchar_ctor_name_wchar(this, name, mode, prot, virt_init);
11352 basic_istream_wchar_get_basic_ios(&this->base.base1)->base.vtable = &MSVCP_basic_fstream_short_vtable;
11356 /* ??1?$basic_fstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
11357 /* ??1?$basic_fstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
11358 /* ??1?$basic_fstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
11359 /* ??1?$basic_fstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
11360 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_dtor, 4)
11361 void __thiscall basic_fstream_wchar_dtor(basic_ios_wchar *base)
11363 basic_fstream_wchar *this = basic_fstream_wchar_from_basic_ios(base);
11365 TRACE("(%p)\n", this);
11367 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(&this->base));
11368 basic_filebuf_wchar_dtor(&this->filebuf);
11371 /* ??_D?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11372 /* ??_D?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11373 /* ??_D?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11374 /* ??_D?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11375 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_vbase_dtor, 4)
11376 void __thiscall basic_fstream_wchar_vbase_dtor(basic_fstream_wchar *this)
11378 TRACE("(%p)\n", this);
11380 basic_fstream_wchar_dtor(basic_fstream_wchar_to_basic_ios(this));
11381 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base.base1));
11384 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_vector_dtor, 8)
11385 basic_fstream_wchar* __thiscall basic_fstream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
11387 basic_fstream_wchar *this = basic_fstream_wchar_from_basic_ios(base);
11389 TRACE("(%p %x)\n", this, flags);
11392 /* we have an array, with the number of elements stored before the first object */
11393 INT_PTR i, *ptr = (INT_PTR *)this-1;
11395 for(i=*ptr-1; i>=0; i--)
11396 basic_fstream_wchar_vbase_dtor(this+i);
11397 MSVCRT_operator_delete(ptr);
11399 basic_fstream_wchar_vbase_dtor(this);
11401 MSVCRT_operator_delete(this);
11407 /* ?close@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11408 /* ?close@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11409 /* ?close@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11410 /* ?close@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11411 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_close, 4)
11412 void __thiscall basic_fstream_wchar_close(basic_fstream_wchar *this)
11414 TRACE("(%p)\n", this);
11416 if(!basic_filebuf_wchar_close(&this->filebuf)) {
11417 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11418 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
11422 /* ?is_open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
11423 /* ?is_open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
11424 /* ?is_open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
11425 /* ?is_open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
11426 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_is_open, 4)
11427 MSVCP_bool __thiscall basic_fstream_wchar_is_open(const basic_fstream_wchar *this)
11429 TRACE("(%p)\n", this);
11430 return basic_filebuf_wchar_is_open(&this->filebuf);
11433 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
11434 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
11435 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
11436 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
11437 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open, 16)
11438 void __thiscall basic_fstream_wchar_open(basic_fstream_wchar *this,
11439 const char *name, int mode, int prot)
11441 TRACE("(%p %s %d %d)\n", this, name, mode, prot);
11443 if(!basic_filebuf_wchar_open(&this->filebuf, name, mode, prot)) {
11444 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11445 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
11449 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
11450 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
11451 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
11452 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
11453 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_old, 12)
11454 void __thiscall basic_fstream_wchar_open_old(basic_fstream_wchar *this,
11455 const char *name, unsigned int mode)
11457 basic_fstream_wchar_open(this, name, mode, _SH_DENYNO);
11460 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
11461 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
11462 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
11463 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
11464 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
11465 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
11466 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
11467 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
11468 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_wchar, 16)
11469 void __thiscall basic_fstream_wchar_open_wchar(basic_fstream_wchar *this,
11470 const wchar_t *name, int mode, int prot)
11472 TRACE("(%p %s %d %d)\n", this, debugstr_w(name), mode, prot);
11474 if(!basic_filebuf_wchar_open_wchar(&this->filebuf, name, mode, prot)) {
11475 basic_ios_wchar *basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
11476 basic_ios_wchar_setstate(basic_ios, IOSTATE_failbit);
11480 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
11481 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
11482 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
11483 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
11484 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
11485 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
11486 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
11487 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
11488 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_wchar_old, 12)
11489 void __thiscall basic_fstream_wchar_open_wchar_old(basic_fstream_wchar *this,
11490 const wchar_t *name, unsigned int mode)
11492 basic_fstream_wchar_open_wchar(this, name, mode, _SH_DENYNO);
11495 /* ?rdbuf@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
11496 /* ?rdbuf@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
11497 /* ?rdbuf@?$basic_fstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
11498 /* ?rdbuf@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
11499 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_rdbuf, 4)
11500 basic_filebuf_wchar* __thiscall basic_fstream_wchar_rdbuf(const basic_fstream_wchar *this)
11502 TRACE("(%p)\n", this);
11503 return (basic_filebuf_wchar*)&this->filebuf;
11506 static inline basic_ios_char* basic_ostringstream_char_to_basic_ios(basic_ostringstream_char *ptr)
11508 return (basic_ios_char*)((char*)ptr+basic_ostringstream_char_vbtable[1]);
11511 static inline basic_ostringstream_char* basic_ostringstream_char_from_basic_ios(basic_ios_char *ptr)
11513 return (basic_ostringstream_char*)((char*)ptr-basic_ostringstream_char_vbtable[1]);
11516 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
11517 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
11518 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor_str, 16)
11519 basic_ostringstream_char* __thiscall basic_ostringstream_char_ctor_str(basic_ostringstream_char *this,
11520 const basic_string_char *str, int mode, MSVCP_bool virt_init)
11522 basic_ios_char *basic_ios;
11524 TRACE("(%p %p %d %d)\n", this, str, mode, virt_init);
11527 this->base.vbtable = basic_ostringstream_char_vbtable;
11528 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
11529 basic_ios_char_ctor(basic_ios);
11531 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
11534 basic_stringbuf_char_ctor_str(&this->strbuf, str, mode|OPENMODE_out);
11535 basic_ostream_char_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
11536 basic_ios->base.vtable = &MSVCP_basic_ostringstream_char_vtable;
11540 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
11541 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
11542 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor_mode, 12)
11543 basic_ostringstream_char* __thiscall basic_ostringstream_char_ctor_mode(
11544 basic_ostringstream_char *this, int mode, MSVCP_bool virt_init)
11546 basic_ios_char *basic_ios;
11548 TRACE("(%p %d %d)\n", this, mode, virt_init);
11551 this->base.vbtable = basic_ostringstream_char_vbtable;
11552 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
11553 basic_ios_char_ctor(basic_ios);
11555 basic_ios = basic_ostream_char_get_basic_ios(&this->base);
11558 basic_stringbuf_char_ctor_mode(&this->strbuf, mode|OPENMODE_out);
11559 basic_ostream_char_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
11560 basic_ios->base.vtable = &MSVCP_basic_ostringstream_char_vtable;
11564 /* ??_F?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
11565 /* ??_F?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
11566 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor, 8)
11567 basic_ostringstream_char* __thiscall basic_ostringstream_char_ctor(
11568 basic_ostringstream_char *this, MSVCP_bool virt_init)
11570 return basic_ostringstream_char_ctor_mode(this, 0, virt_init);
11573 /* ??1?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
11574 /* ??1?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
11575 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_dtor, 4)
11576 void __thiscall basic_ostringstream_char_dtor(basic_ios_char *base)
11578 basic_ostringstream_char *this = basic_ostringstream_char_from_basic_ios(base);
11580 TRACE("(%p)\n", this);
11582 basic_stringbuf_char_dtor(&this->strbuf);
11583 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base));
11586 /* ??_D?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
11587 /* ??_D?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
11588 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_vbase_dtor, 4)
11589 void __thiscall basic_ostringstream_char_vbase_dtor(basic_ostringstream_char *this)
11591 TRACE("(%p)\n", this);
11593 basic_ostringstream_char_dtor(basic_ostringstream_char_to_basic_ios(this));
11594 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(&this->base));
11597 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_vector_dtor, 8)
11598 basic_ostringstream_char* __thiscall basic_ostringstream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
11600 basic_ostringstream_char *this = basic_ostringstream_char_from_basic_ios(base);
11602 TRACE("(%p %x)\n", this, flags);
11605 /* we have an array, with the number of elements stored before the first object */
11606 INT_PTR i, *ptr = (INT_PTR *)this-1;
11608 for(i=*ptr-1; i>=0; i--)
11609 basic_ostringstream_char_vbase_dtor(this+i);
11610 MSVCRT_operator_delete(ptr);
11612 basic_ostringstream_char_vbase_dtor(this);
11614 MSVCRT_operator_delete(this);
11620 /* ?rdbuf@?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEPAV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11621 /* ?rdbuf@?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBAPEAV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11622 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_rdbuf, 4)
11623 basic_stringbuf_char* __thiscall basic_ostringstream_char_rdbuf(const basic_ostringstream_char *this)
11625 TRACE("(%p)\n", this);
11626 return (basic_stringbuf_char*)&this->strbuf;
11629 /* ?str@?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
11630 /* ?str@?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
11631 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_str_set, 8)
11632 void __thiscall basic_ostringstream_char_str_set(basic_ostringstream_char *this, const basic_string_char *str)
11634 TRACE("(%p %p)\n", this, str);
11635 basic_stringbuf_char_str_set(&this->strbuf, str);
11638 /* ?str@?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11639 /* ?str@?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11640 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_str_get, 8)
11641 basic_string_char* __thiscall basic_ostringstream_char_str_get(const basic_ostringstream_char *this, basic_string_char *ret)
11643 TRACE("(%p %p)\n", this, ret);
11644 return basic_stringbuf_char_str_get(&this->strbuf, ret);
11647 static inline basic_ios_wchar* basic_ostringstream_wchar_to_basic_ios(basic_ostringstream_wchar *ptr)
11649 return (basic_ios_wchar*)((char*)ptr+basic_ostringstream_wchar_vbtable[1]);
11652 static inline basic_ostringstream_wchar* basic_ostringstream_wchar_from_basic_ios(basic_ios_wchar *ptr)
11654 return (basic_ostringstream_wchar*)((char*)ptr-basic_ostringstream_wchar_vbtable[1]);
11657 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
11658 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@AEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
11659 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor_str, 16)
11660 basic_ostringstream_wchar* __thiscall basic_ostringstream_wchar_ctor_str(basic_ostringstream_wchar *this,
11661 const basic_string_wchar *str, int mode, MSVCP_bool virt_init)
11663 basic_ios_wchar *basic_ios;
11665 TRACE("(%p %p %d %d)\n", this, str, mode, virt_init);
11668 this->base.vbtable = basic_ostringstream_wchar_vbtable;
11669 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
11670 basic_ios_wchar_ctor(basic_ios);
11672 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
11675 basic_stringbuf_wchar_ctor_str(&this->strbuf, str, mode|OPENMODE_out);
11676 basic_ostream_wchar_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
11677 basic_ios->base.vtable = &MSVCP_basic_ostringstream_wchar_vtable;
11681 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
11682 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
11683 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor_str, 16)
11684 basic_ostringstream_wchar* __thiscall basic_ostringstream_short_ctor_str(basic_ostringstream_wchar *this,
11685 const basic_string_wchar *str, int mode, MSVCP_bool virt_init)
11687 basic_ostringstream_wchar_ctor_str(this, str, mode, virt_init);
11688 basic_ostream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ostringstream_short_vtable;
11692 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
11693 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
11694 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor_mode, 12)
11695 basic_ostringstream_wchar* __thiscall basic_ostringstream_wchar_ctor_mode(
11696 basic_ostringstream_wchar *this, int mode, MSVCP_bool virt_init)
11698 basic_ios_wchar *basic_ios;
11700 TRACE("(%p %d %d)\n", this, mode, virt_init);
11703 this->base.vbtable = basic_ostringstream_wchar_vbtable;
11704 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
11705 basic_ios_wchar_ctor(basic_ios);
11707 basic_ios = basic_ostream_wchar_get_basic_ios(&this->base);
11710 basic_stringbuf_wchar_ctor_mode(&this->strbuf, mode|OPENMODE_out);
11711 basic_ostream_wchar_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
11712 basic_ios->base.vtable = &MSVCP_basic_ostringstream_wchar_vtable;
11716 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
11717 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
11718 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor_mode, 12)
11719 basic_ostringstream_wchar* __thiscall basic_ostringstream_short_ctor_mode(
11720 basic_ostringstream_wchar *this, int mode, MSVCP_bool virt_init)
11722 basic_ostringstream_wchar_ctor_mode(this, mode, virt_init);
11723 basic_ostream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_ostringstream_short_vtable;
11727 /* ??_F?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
11728 /* ??_F?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
11729 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor, 8)
11730 basic_ostringstream_wchar* __thiscall basic_ostringstream_wchar_ctor(
11731 basic_ostringstream_wchar *this, MSVCP_bool virt_init)
11733 return basic_ostringstream_wchar_ctor_mode(this, 0, virt_init);
11736 /* ??_F?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
11737 /* ??_F?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
11738 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor, 8)
11739 basic_ostringstream_wchar* __thiscall basic_ostringstream_short_ctor(
11740 basic_ostringstream_wchar *this, MSVCP_bool virt_init)
11742 return basic_ostringstream_short_ctor_mode(this, 0, virt_init);
11745 /* ??1?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
11746 /* ??1?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
11747 /* ??1?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
11748 /* ??1?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
11749 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_dtor, 4)
11750 void __thiscall basic_ostringstream_wchar_dtor(basic_ios_wchar *base)
11752 basic_ostringstream_wchar *this = basic_ostringstream_wchar_from_basic_ios(base);
11754 TRACE("(%p)\n", this);
11756 basic_stringbuf_wchar_dtor(&this->strbuf);
11757 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base));
11760 /* ??_D?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
11761 /* ??_D?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
11762 /* ??_D?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
11763 /* ??_D?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
11764 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_vbase_dtor, 4)
11765 void __thiscall basic_ostringstream_wchar_vbase_dtor(basic_ostringstream_wchar *this)
11767 TRACE("(%p)\n", this);
11769 basic_ostringstream_wchar_dtor(basic_ostringstream_wchar_to_basic_ios(this));
11770 basic_ios_wchar_dtor(basic_ostream_wchar_get_basic_ios(&this->base));
11773 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_vector_dtor, 8)
11774 basic_ostringstream_wchar* __thiscall basic_ostringstream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
11776 basic_ostringstream_wchar *this = basic_ostringstream_wchar_from_basic_ios(base);
11778 TRACE("(%p %x)\n", this, flags);
11781 /* we have an array, with the number of elements stored before the first object */
11782 INT_PTR i, *ptr = (INT_PTR *)this-1;
11784 for(i=*ptr-1; i>=0; i--)
11785 basic_ostringstream_wchar_vbase_dtor(this+i);
11786 MSVCRT_operator_delete(ptr);
11788 basic_ostringstream_wchar_vbase_dtor(this);
11790 MSVCRT_operator_delete(this);
11796 /* ?rdbuf@?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBEPAV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
11797 /* ?rdbuf@?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBAPEAV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
11798 /* ?rdbuf@?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBEPAV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
11799 /* ?rdbuf@?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBAPEAV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
11800 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_rdbuf, 4)
11801 basic_stringbuf_wchar* __thiscall basic_ostringstream_wchar_rdbuf(const basic_ostringstream_wchar *this)
11803 TRACE("(%p)\n", this);
11804 return (basic_stringbuf_wchar*)&this->strbuf;
11807 /* ?str@?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
11808 /* ?str@?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXAEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
11809 /* ?str@?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
11810 /* ?str@?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXAEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
11811 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_str_set, 8)
11812 void __thiscall basic_ostringstream_wchar_str_set(basic_ostringstream_wchar *this, const basic_string_wchar *str)
11814 TRACE("(%p %p)\n", this, str);
11815 basic_stringbuf_wchar_str_set(&this->strbuf, str);
11818 /* ?str@?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
11819 /* ?str@?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
11820 /* ?str@?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
11821 /* ?str@?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
11822 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_str_get, 8)
11823 basic_string_wchar* __thiscall basic_ostringstream_wchar_str_get(const basic_ostringstream_wchar *this, basic_string_wchar *ret)
11825 TRACE("(%p %p)\n", this, ret);
11826 return basic_stringbuf_wchar_str_get(&this->strbuf, ret);
11829 static inline basic_ios_char* basic_istringstream_char_to_basic_ios(basic_istringstream_char *ptr)
11831 return (basic_ios_char*)((char*)ptr+basic_istringstream_char_vbtable[1]);
11834 static inline basic_istringstream_char* basic_istringstream_char_from_basic_ios(basic_ios_char *ptr)
11836 return (basic_istringstream_char*)((char*)ptr-basic_istringstream_char_vbtable[1]);
11839 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
11840 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
11841 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor_str, 16)
11842 basic_istringstream_char* __thiscall basic_istringstream_char_ctor_str(basic_istringstream_char *this,
11843 const basic_string_char *str, int mode, MSVCP_bool virt_init)
11845 basic_ios_char *basic_ios;
11847 TRACE("(%p %p %d %d)\n", this, str, mode, virt_init);
11850 this->base.vbtable = basic_istringstream_char_vbtable;
11851 basic_ios = basic_istream_char_get_basic_ios(&this->base);
11852 basic_ios_char_ctor(basic_ios);
11854 basic_ios = basic_istream_char_get_basic_ios(&this->base);
11857 basic_stringbuf_char_ctor_str(&this->strbuf, str, mode|OPENMODE_in);
11858 basic_istream_char_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
11859 basic_ios->base.vtable = &MSVCP_basic_istringstream_char_vtable;
11863 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
11864 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
11865 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor_mode, 12)
11866 basic_istringstream_char* __thiscall basic_istringstream_char_ctor_mode(
11867 basic_istringstream_char *this, int mode, MSVCP_bool virt_init)
11869 basic_ios_char *basic_ios;
11871 TRACE("(%p %d %d)\n", this, mode, virt_init);
11874 this->base.vbtable = basic_istringstream_char_vbtable;
11875 basic_ios = basic_istream_char_get_basic_ios(&this->base);
11876 basic_ios_char_ctor(basic_ios);
11878 basic_ios = basic_istream_char_get_basic_ios(&this->base);
11881 basic_stringbuf_char_ctor_mode(&this->strbuf, mode|OPENMODE_in);
11882 basic_istream_char_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
11883 basic_ios->base.vtable = &MSVCP_basic_istringstream_char_vtable;
11887 /* ??_F?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
11888 /* ??_F?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
11889 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor, 8)
11890 basic_istringstream_char* __thiscall basic_istringstream_char_ctor(
11891 basic_istringstream_char *this, MSVCP_bool virt_init)
11893 return basic_istringstream_char_ctor_mode(this, 0, virt_init);
11896 /* ??1?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
11897 /* ??1?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
11898 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_dtor, 4)
11899 void __thiscall basic_istringstream_char_dtor(basic_ios_char *base)
11901 basic_istringstream_char *this = basic_istringstream_char_from_basic_ios(base);
11903 TRACE("(%p)\n", this);
11905 basic_stringbuf_char_dtor(&this->strbuf);
11906 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base));
11909 /* ??_D?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
11910 /* ??_D?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
11911 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_vbase_dtor, 4)
11912 void __thiscall basic_istringstream_char_vbase_dtor(basic_istringstream_char *this)
11914 TRACE("(%p)\n", this);
11916 basic_istringstream_char_dtor(basic_istringstream_char_to_basic_ios(this));
11917 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base));
11920 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_vector_dtor, 8)
11921 basic_istringstream_char* __thiscall basic_istringstream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
11923 basic_istringstream_char *this = basic_istringstream_char_from_basic_ios(base);
11925 TRACE("(%p %x)\n", this, flags);
11928 /* we have an array, with the number of elements stored before the first object */
11929 INT_PTR i, *ptr = (INT_PTR *)this-1;
11931 for(i=*ptr-1; i>=0; i--)
11932 basic_istringstream_char_vbase_dtor(this+i);
11933 MSVCRT_operator_delete(ptr);
11935 basic_istringstream_char_vbase_dtor(this);
11937 MSVCRT_operator_delete(this);
11943 /* ?rdbuf@?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEPAV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11944 /* ?rdbuf@?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBAPEAV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11945 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_rdbuf, 4)
11946 basic_stringbuf_char* __thiscall basic_istringstream_char_rdbuf(const basic_istringstream_char *this)
11948 TRACE("(%p)\n", this);
11949 return (basic_stringbuf_char*)&this->strbuf;
11952 /* ?str@?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
11953 /* ?str@?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
11954 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_str_set, 8)
11955 void __thiscall basic_istringstream_char_str_set(basic_istringstream_char *this, const basic_string_char *str)
11957 TRACE("(%p %p)\n", this, str);
11958 basic_stringbuf_char_str_set(&this->strbuf, str);
11961 /* ?str@?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11962 /* ?str@?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
11963 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_str_get, 8)
11964 basic_string_char* __thiscall basic_istringstream_char_str_get(const basic_istringstream_char *this, basic_string_char *ret)
11966 TRACE("(%p %p)\n", this, ret);
11967 return basic_stringbuf_char_str_get(&this->strbuf, ret);
11970 static inline basic_ios_wchar* basic_istringstream_wchar_to_basic_ios(basic_istringstream_wchar *ptr)
11972 return (basic_ios_wchar*)((char*)ptr+basic_istringstream_wchar_vbtable[1]);
11975 static inline basic_istringstream_wchar* basic_istringstream_wchar_from_basic_ios(basic_ios_wchar *ptr)
11977 return (basic_istringstream_wchar*)((char*)ptr-basic_istringstream_wchar_vbtable[1]);
11980 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
11981 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@AEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
11982 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor_str, 16)
11983 basic_istringstream_wchar* __thiscall basic_istringstream_wchar_ctor_str(basic_istringstream_wchar *this,
11984 const basic_string_wchar *str, int mode, MSVCP_bool virt_init)
11986 basic_ios_wchar *basic_ios;
11988 TRACE("(%p %p %d %d)\n", this, str, mode, virt_init);
11991 this->base.vbtable = basic_istringstream_wchar_vbtable;
11992 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
11993 basic_ios_wchar_ctor(basic_ios);
11995 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
11998 basic_stringbuf_wchar_ctor_str(&this->strbuf, str, mode|OPENMODE_in);
11999 basic_istream_wchar_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
12000 basic_ios->base.vtable = &MSVCP_basic_istringstream_wchar_vtable;
12004 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
12005 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
12006 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor_str, 16)
12007 basic_istringstream_wchar* __thiscall basic_istringstream_short_ctor_str(basic_istringstream_wchar *this,
12008 const basic_string_wchar *str, int mode, MSVCP_bool virt_init)
12010 basic_istringstream_wchar_ctor_str(this, str, mode, virt_init);
12011 basic_istream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_istringstream_short_vtable;
12015 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
12016 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
12017 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor_mode, 12)
12018 basic_istringstream_wchar* __thiscall basic_istringstream_wchar_ctor_mode(
12019 basic_istringstream_wchar *this, int mode, MSVCP_bool virt_init)
12021 basic_ios_wchar *basic_ios;
12023 TRACE("(%p %d %d)\n", this, mode, virt_init);
12026 this->base.vbtable = basic_istringstream_wchar_vbtable;
12027 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
12028 basic_ios_wchar_ctor(basic_ios);
12030 basic_ios = basic_istream_wchar_get_basic_ios(&this->base);
12033 basic_stringbuf_wchar_ctor_mode(&this->strbuf, mode|OPENMODE_in);
12034 basic_istream_wchar_ctor(&this->base, &this->strbuf.base, FALSE, FALSE);
12035 basic_ios->base.vtable = &MSVCP_basic_istringstream_wchar_vtable;
12039 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
12040 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
12041 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor_mode, 12)
12042 basic_istringstream_wchar* __thiscall basic_istringstream_short_ctor_mode(
12043 basic_istringstream_wchar *this, int mode, MSVCP_bool virt_init)
12045 basic_istringstream_wchar_ctor_mode(this, mode, virt_init);
12046 basic_istream_wchar_get_basic_ios(&this->base)->base.vtable = &MSVCP_basic_istringstream_short_vtable;
12050 /* ??_F?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
12051 /* ??_F?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
12052 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor, 8)
12053 basic_istringstream_wchar* __thiscall basic_istringstream_wchar_ctor(
12054 basic_istringstream_wchar *this, MSVCP_bool virt_init)
12056 return basic_istringstream_wchar_ctor_mode(this, 0, virt_init);
12059 /* ??_F?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
12060 /* ??_F?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
12061 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor, 8)
12062 basic_istringstream_wchar* __thiscall basic_istringstream_short_ctor(
12063 basic_istringstream_wchar *this, MSVCP_bool virt_init)
12065 return basic_istringstream_short_ctor_mode(this, 0, virt_init);
12068 /* ??1?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
12069 /* ??1?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
12070 /* ??1?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
12071 /* ??1?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
12072 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_dtor, 4)
12073 void __thiscall basic_istringstream_wchar_dtor(basic_ios_wchar *base)
12075 basic_istringstream_wchar *this = basic_istringstream_wchar_from_basic_ios(base);
12077 TRACE("(%p)\n", this);
12079 basic_stringbuf_wchar_dtor(&this->strbuf);
12080 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base));
12083 /* ??_D?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
12084 /* ??_D?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
12085 /* ??_D?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
12086 /* ??_D?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
12087 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_vbase_dtor, 4)
12088 void __thiscall basic_istringstream_wchar_vbase_dtor(basic_istringstream_wchar *this)
12090 TRACE("(%p)\n", this);
12092 basic_istringstream_wchar_dtor(basic_istringstream_wchar_to_basic_ios(this));
12093 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base));
12096 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_vector_dtor, 8)
12097 basic_istringstream_wchar* __thiscall basic_istringstream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
12099 basic_istringstream_wchar *this = basic_istringstream_wchar_from_basic_ios(base);
12101 TRACE("(%p %x)\n", this, flags);
12104 /* we have an array, with the number of elements stored before the first object */
12105 INT_PTR i, *ptr = (INT_PTR *)this-1;
12107 for(i=*ptr-1; i>=0; i--)
12108 basic_istringstream_wchar_vbase_dtor(this+i);
12109 MSVCRT_operator_delete(ptr);
12111 basic_istringstream_wchar_vbase_dtor(this);
12113 MSVCRT_operator_delete(this);
12119 /* ?rdbuf@?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBEPAV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12120 /* ?rdbuf@?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBAPEAV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12121 /* ?rdbuf@?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBEPAV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12122 /* ?rdbuf@?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBAPEAV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12123 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_rdbuf, 4)
12124 basic_stringbuf_wchar* __thiscall basic_istringstream_wchar_rdbuf(const basic_istringstream_wchar *this)
12126 TRACE("(%p)\n", this);
12127 return (basic_stringbuf_wchar*)&this->strbuf;
12130 /* ?str@?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
12131 /* ?str@?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXAEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
12132 /* ?str@?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
12133 /* ?str@?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXAEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
12134 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_str_set, 8)
12135 void __thiscall basic_istringstream_wchar_str_set(basic_istringstream_wchar *this, const basic_string_wchar *str)
12137 TRACE("(%p %p)\n", this, str);
12138 basic_stringbuf_wchar_str_set(&this->strbuf, str);
12141 /* ?str@?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12142 /* ?str@?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12143 /* ?str@?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12144 /* ?str@?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12145 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_str_get, 8)
12146 basic_string_wchar* __thiscall basic_istringstream_wchar_str_get(const basic_istringstream_wchar *this, basic_string_wchar *ret)
12148 TRACE("(%p %p)\n", this, ret);
12149 return basic_stringbuf_wchar_str_get(&this->strbuf, ret);
12152 static inline basic_ios_char* basic_stringstream_char_to_basic_ios(basic_stringstream_char *ptr)
12154 return (basic_ios_char*)((char*)ptr+basic_stringstream_char_vbtable1[1]);
12157 static inline basic_stringstream_char* basic_stringstream_char_from_basic_ios(basic_ios_char *ptr)
12159 return (basic_stringstream_char*)((char*)ptr-basic_stringstream_char_vbtable1[1]);
12162 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
12163 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@H@Z */
12164 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor_str, 16)
12165 basic_stringstream_char* __thiscall basic_stringstream_char_ctor_str(basic_stringstream_char *this,
12166 const basic_string_char *str, int mode, MSVCP_bool virt_init)
12168 basic_ios_char *basic_ios;
12170 TRACE("(%p %p %d %d)\n", this, str, mode, virt_init);
12173 this->base.base1.vbtable = basic_stringstream_char_vbtable1;
12174 this->base.base2.vbtable = basic_stringstream_char_vbtable2;
12175 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
12176 basic_ios_char_ctor(basic_ios);
12178 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
12181 basic_stringbuf_char_ctor_str(&this->strbuf, str, mode);
12182 basic_iostream_char_ctor(&this->base, &this->strbuf.base, FALSE);
12183 basic_ios->base.vtable = &MSVCP_basic_stringstream_char_vtable;
12187 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
12188 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
12189 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor_mode, 12)
12190 basic_stringstream_char* __thiscall basic_stringstream_char_ctor_mode(
12191 basic_stringstream_char *this, int mode, MSVCP_bool virt_init)
12193 basic_ios_char *basic_ios;
12195 TRACE("(%p %d %d)\n", this, mode, virt_init);
12198 this->base.base1.vbtable = basic_stringstream_char_vbtable1;
12199 this->base.base2.vbtable = basic_stringstream_char_vbtable2;
12200 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
12201 basic_ios_char_ctor(basic_ios);
12203 basic_ios = basic_istream_char_get_basic_ios(&this->base.base1);
12206 basic_stringbuf_char_ctor_mode(&this->strbuf, mode);
12207 basic_iostream_char_ctor(&this->base, &this->strbuf.base, FALSE);
12208 basic_ios->base.vtable = &MSVCP_basic_stringstream_char_vtable;
12212 /* ??_F?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
12213 /* ??_F?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
12214 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor, 8)
12215 basic_stringstream_char* __thiscall basic_stringstream_char_ctor(
12216 basic_stringstream_char *this, MSVCP_bool virt_init)
12218 return basic_stringstream_char_ctor_mode(
12219 this, OPENMODE_out|OPENMODE_in, virt_init);
12222 /* ??1?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
12223 /* ??1?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
12224 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_dtor, 4)
12225 void __thiscall basic_stringstream_char_dtor(basic_ios_char *base)
12227 basic_stringstream_char *this = basic_stringstream_char_from_basic_ios(base);
12229 TRACE("(%p)\n", this);
12231 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base));
12232 basic_stringbuf_char_dtor(&this->strbuf);
12235 /* ??_D?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
12236 /* ??_D?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
12237 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_vbase_dtor, 4)
12238 void __thiscall basic_stringstream_char_vbase_dtor(basic_stringstream_char *this)
12240 TRACE("(%p)\n", this);
12242 basic_stringstream_char_dtor(basic_stringstream_char_to_basic_ios(this));
12243 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base.base1));
12246 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_vector_dtor, 8)
12247 basic_stringstream_char* __thiscall basic_stringstream_char_vector_dtor(basic_ios_char *base, unsigned int flags)
12249 basic_stringstream_char *this = basic_stringstream_char_from_basic_ios(base);
12251 TRACE("(%p %x)\n", this, flags);
12254 /* we have an array, with the number of elements stored before the first object */
12255 INT_PTR i, *ptr = (INT_PTR *)this-1;
12257 for(i=*ptr-1; i>=0; i--)
12258 basic_stringstream_char_vbase_dtor(this+i);
12259 MSVCRT_operator_delete(ptr);
12261 basic_stringstream_char_vbase_dtor(this);
12263 MSVCRT_operator_delete(this);
12269 /* ?rdbuf@?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBEPAV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
12270 /* ?rdbuf@?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBAPEAV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
12271 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_rdbuf, 4)
12272 basic_stringbuf_char* __thiscall basic_stringstream_char_rdbuf(const basic_stringstream_char *this)
12274 TRACE("(%p)\n", this);
12275 return (basic_stringbuf_char*)&this->strbuf;
12278 /* ?str@?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
12279 /* ?str@?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
12280 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_str_set, 8)
12281 void __thiscall basic_stringstream_char_str_set(basic_stringstream_char *this, const basic_string_char *str)
12283 TRACE("(%p %p)\n", this, str);
12284 basic_stringbuf_char_str_set(&this->strbuf, str);
12287 /* ?str@?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
12288 /* ?str@?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
12289 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_str_get, 8)
12290 basic_string_char* __thiscall basic_stringstream_char_str_get(const basic_stringstream_char *this, basic_string_char *ret)
12292 TRACE("(%p %p)\n", this, ret);
12293 return basic_stringbuf_char_str_get(&this->strbuf, ret);
12296 static inline basic_ios_wchar* basic_stringstream_wchar_to_basic_ios(basic_stringstream_wchar *ptr)
12298 return (basic_ios_wchar*)((char*)ptr+basic_stringstream_wchar_vbtable1[1]);
12301 static inline basic_stringstream_wchar* basic_stringstream_wchar_from_basic_ios(basic_ios_wchar *ptr)
12303 return (basic_stringstream_wchar*)((char*)ptr-basic_stringstream_wchar_vbtable1[1]);
12306 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@ABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
12307 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@AEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@1@H@Z */
12308 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor_str, 16)
12309 basic_stringstream_wchar* __thiscall basic_stringstream_wchar_ctor_str(basic_stringstream_wchar *this,
12310 const basic_string_wchar *str, int mode, MSVCP_bool virt_init)
12312 basic_ios_wchar *basic_ios;
12314 TRACE("(%p %p %d %d)\n", this, str, mode, virt_init);
12317 this->base.base1.vbtable = basic_stringstream_wchar_vbtable1;
12318 this->base.base2.vbtable = basic_stringstream_wchar_vbtable2;
12319 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
12320 basic_ios_wchar_ctor(basic_ios);
12322 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
12325 basic_stringbuf_wchar_ctor_str(&this->strbuf, str, mode);
12326 basic_iostream_wchar_ctor(&this->base, &this->strbuf.base, FALSE);
12327 basic_ios->base.vtable = &MSVCP_basic_stringstream_wchar_vtable;
12331 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@ABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
12332 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@AEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@1@H@Z */
12333 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor_str, 16)
12334 basic_stringstream_wchar* __thiscall basic_stringstream_short_ctor_str(basic_stringstream_wchar *this,
12335 const basic_string_wchar *str, int mode, MSVCP_bool virt_init)
12337 basic_stringstream_wchar_ctor_str(this, str, mode, virt_init);
12338 basic_istream_wchar_get_basic_ios(&this->base.base1)->base.vtable = &MSVCP_basic_stringstream_short_vtable;
12342 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
12343 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
12344 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor_mode, 12)
12345 basic_stringstream_wchar* __thiscall basic_stringstream_wchar_ctor_mode(
12346 basic_stringstream_wchar *this, int mode, MSVCP_bool virt_init)
12348 basic_ios_wchar *basic_ios;
12350 TRACE("(%p %d %d)\n", this, mode, virt_init);
12353 this->base.base1.vbtable = basic_stringstream_wchar_vbtable1;
12354 this->base.base2.vbtable = basic_stringstream_wchar_vbtable2;
12355 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
12356 basic_ios_wchar_ctor(basic_ios);
12358 basic_ios = basic_istream_wchar_get_basic_ios(&this->base.base1);
12361 basic_stringbuf_wchar_ctor_mode(&this->strbuf, mode);
12362 basic_iostream_wchar_ctor(&this->base, &this->strbuf.base, FALSE);
12363 basic_ios->base.vtable = &MSVCP_basic_stringstream_wchar_vtable;
12367 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
12368 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
12369 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor_mode, 12)
12370 basic_stringstream_wchar* __thiscall basic_stringstream_short_ctor_mode(
12371 basic_stringstream_wchar *this, int mode, MSVCP_bool virt_init)
12373 basic_stringstream_wchar_ctor_mode(this, mode, virt_init);
12374 basic_istream_wchar_get_basic_ios(&this->base.base1)->base.vtable = &MSVCP_basic_stringstream_short_vtable;
12378 /* ??_F?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
12379 /* ??_F?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
12380 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor, 8)
12381 basic_stringstream_wchar* __thiscall basic_stringstream_wchar_ctor(
12382 basic_stringstream_wchar *this, MSVCP_bool virt_init)
12384 return basic_stringstream_wchar_ctor_mode(
12385 this, OPENMODE_out|OPENMODE_in, virt_init);
12388 /* ??_F?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
12389 /* ??_F?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
12390 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor, 8)
12391 basic_stringstream_wchar* __thiscall basic_stringstream_short_ctor(
12392 basic_stringstream_wchar *this, MSVCP_bool virt_init)
12394 return basic_stringstream_short_ctor_mode(
12395 this, OPENMODE_out|OPENMODE_in, virt_init);
12398 /* ??1?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
12399 /* ??1?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
12400 /* ??1?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
12401 /* ??1?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
12402 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_dtor, 4)
12403 void __thiscall basic_stringstream_wchar_dtor(basic_ios_wchar *base)
12405 basic_stringstream_wchar *this = basic_stringstream_wchar_from_basic_ios(base);
12407 TRACE("(%p)\n", this);
12409 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(&this->base));
12410 basic_stringbuf_wchar_dtor(&this->strbuf);
12413 /* ??_D?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
12414 /* ??_D?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
12415 /* ??_D?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
12416 /* ??_D?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
12417 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_vbase_dtor, 4)
12418 void __thiscall basic_stringstream_wchar_vbase_dtor(basic_stringstream_wchar *this)
12420 TRACE("(%p)\n", this);
12422 basic_stringstream_wchar_dtor(basic_stringstream_wchar_to_basic_ios(this));
12423 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base.base1));
12426 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_vector_dtor, 8)
12427 basic_stringstream_wchar* __thiscall basic_stringstream_wchar_vector_dtor(basic_ios_wchar *base, unsigned int flags)
12429 basic_stringstream_wchar *this = basic_stringstream_wchar_from_basic_ios(base);
12431 TRACE("(%p %x)\n", this, flags);
12434 /* we have an array, with the number of elements stored before the first object */
12435 INT_PTR i, *ptr = (INT_PTR *)this-1;
12437 for(i=*ptr-1; i>=0; i--)
12438 basic_stringstream_wchar_vbase_dtor(this+i);
12439 MSVCRT_operator_delete(ptr);
12441 basic_stringstream_wchar_vbase_dtor(this);
12443 MSVCRT_operator_delete(this);
12449 /* ?rdbuf@?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBEPAV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12450 /* ?rdbuf@?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBAPEAV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12451 /* ?rdbuf@?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBEPAV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12452 /* ?rdbuf@?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBAPEAV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12453 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_rdbuf, 4)
12454 basic_stringbuf_wchar* __thiscall basic_stringstream_wchar_rdbuf(const basic_stringstream_wchar *this)
12456 TRACE("(%p)\n", this);
12457 return (basic_stringbuf_wchar*)&this->strbuf;
12460 /* ?str@?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXABV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
12461 /* ?str@?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXAEBV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@@Z */
12462 /* ?str@?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXABV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
12463 /* ?str@?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXAEBV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@@Z */
12464 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_str_set, 8)
12465 void __thiscall basic_stringstream_wchar_str_set(basic_stringstream_wchar *this, const basic_string_wchar *str)
12467 TRACE("(%p %p)\n", this, str);
12468 basic_stringbuf_wchar_str_set(&this->strbuf, str);
12471 /* ?str@?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12472 /* ?str@?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
12473 /* ?str@?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12474 /* ?str@?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
12475 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_str_get, 8)
12476 basic_string_wchar* __thiscall basic_stringstream_wchar_str_get(const basic_stringstream_wchar *this, basic_string_wchar *ret)
12478 TRACE("(%p %p)\n", this, ret);
12479 return basic_stringbuf_wchar_str_get(&this->strbuf, ret);
12482 /* ?_Init@strstreambuf@std@@IAEXHPAD0H@Z */
12483 /* ?_Init@strstreambuf@std@@IEAAX_JPEAD1H@Z */
12484 DEFINE_THISCALL_WRAPPER(strstreambuf__Init, 20)
12485 void __thiscall strstreambuf__Init(strstreambuf *this, streamsize len, char *g, char *p, int mode)
12487 TRACE("(%p %ld %p %p %d)\n", this, len, g, p, mode);
12489 this->minsize = 32;
12490 this->endsave = NULL;
12491 this->strmode = mode;
12492 this->palloc = NULL;
12493 this->pfree = NULL;
12496 this->strmode |= STRSTATE_Dynamic;
12497 if(len > this->minsize)
12498 this->minsize = len;
12499 this->seekhigh = NULL;
12508 this->seekhigh = g+len;
12509 basic_streambuf_char_setg(&this->base, g, g, p ? p : this->seekhigh);
12511 basic_streambuf_char_setp(&this->base, p, this->seekhigh);
12514 /* ??0strstreambuf@std@@QAE@PACH0@Z */
12515 /* ??0strstreambuf@std@@QEAA@PEAC_J0@Z */
12516 /* ??0strstreambuf@std@@QAE@PADH0@Z */
12517 /* ??0strstreambuf@std@@QEAA@PEAD_J0@Z */
12518 /* ??0strstreambuf@std@@QAE@PAEH0@Z */
12519 /* ??0strstreambuf@std@@QEAA@PEAE_J0@Z */
12520 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get_put, 16)
12521 strstreambuf* __thiscall strstreambuf_ctor_get_put(strstreambuf *this, char *g, streamsize len, char *p)
12523 TRACE("(%p %p %ld %p)\n", this, g, len, p);
12525 basic_streambuf_char_ctor(&this->base);
12526 this->base.vtable = &MSVCP_strstreambuf_vtable;
12528 strstreambuf__Init(this, len, g, p, 0);
12532 /* ??0strstreambuf@std@@QAE@H@Z */
12533 /* ??0strstreambuf@std@@QEAA@_J@Z */
12534 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_len, 8)
12535 strstreambuf* __thiscall strstreambuf_ctor_len(strstreambuf *this, streamsize len)
12537 return strstreambuf_ctor_get_put(this, NULL, len, NULL);
12540 /* ??0strstreambuf@std@@QAE@P6APAXI@ZP6AXPAX@Z@Z */
12541 /* ??0strstreambuf@std@@QEAA@P6APEAX_K@ZP6AXPEAX@Z@Z */
12542 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_alloc, 12)
12543 strstreambuf* __thiscall strstreambuf_ctor_alloc(strstreambuf *this, void* (__cdecl *palloc)(MSVCP_size_t), void (__cdecl *pfree)(void*))
12545 TRACE("(%p %p %p)\n", this, palloc, pfree);
12547 strstreambuf_ctor_get_put(this, NULL, 0, NULL);
12548 this->palloc = palloc;
12549 this->pfree = pfree;
12553 /* ??0strstreambuf@std@@QAE@PBCH@Z */
12554 /* ??0strstreambuf@std@@QEAA@PEBC_J@Z */
12555 /* ??0strstreambuf@std@@QAE@PBDH@Z */
12556 /* ??0strstreambuf@std@@QEAA@PEBD_J@Z */
12557 /* ??0strstreambuf@std@@QAE@PBEH@Z */
12558 /* ??0strstreambuf@std@@QEAA@PEBE_J@Z */
12559 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get, 12)
12560 strstreambuf* __thiscall strstreambuf_ctor_get(strstreambuf *this, const char *g, streamsize len)
12562 TRACE("(%p %p %ld)\n", this, g, len);
12564 strstreambuf_ctor_get_put(this, NULL, 0, NULL);
12565 this->strmode |= STRSTATE_Constant;
12569 /* ??_Fstrstreambuf@std@@QAEXXZ */
12570 /* ??_Fstrstreambuf@std@@QEAAXXZ */
12571 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor, 4)
12572 strstreambuf* __thiscall strstreambuf_ctor(strstreambuf *this)
12574 return strstreambuf_ctor_get_put(this, NULL, 0, NULL);
12577 /* ?_Tidy@strstreambuf@std@@IAEXXZ */
12578 /* ?_Tidy@strstreambuf@std@@IEAAXXZ */
12579 DEFINE_THISCALL_WRAPPER(strstreambuf__Tidy, 4)
12580 void __thiscall strstreambuf__Tidy(strstreambuf *this)
12582 TRACE("(%p)\n", this);
12584 if((this->strmode & STRSTATE_Allocated) && !(this->strmode & STRSTATE_Frozen)) {
12586 this->pfree(basic_streambuf_char_eback(&this->base));
12588 MSVCRT_operator_delete(basic_streambuf_char_eback(&this->base));
12591 this->endsave = NULL;
12592 this->seekhigh = NULL;
12593 this->strmode &= ~(STRSTATE_Allocated | STRSTATE_Frozen);
12594 basic_streambuf_char_setg(&this->base, NULL, NULL, NULL);
12595 basic_streambuf_char_setp(&this->base, NULL, NULL);
12598 /* ??1strstreambuf@std@@UAE@XZ */
12599 /* ??1strstreambuf@std@@UEAA@XZ */
12600 DEFINE_THISCALL_WRAPPER(strstreambuf_dtor, 4)
12601 void __thiscall strstreambuf_dtor(strstreambuf *this)
12603 TRACE("(%p)\n", this);
12605 strstreambuf__Tidy(this);
12606 basic_streambuf_char_dtor(&this->base);
12609 DEFINE_THISCALL_WRAPPER(strstreambuf_vector_dtor, 8)
12610 strstreambuf* __thiscall strstreambuf_vector_dtor(strstreambuf *this, unsigned int flags)
12612 TRACE("(%p %x)\n", this, flags);
12614 /* we have an array, with the number of elements stored before the first object */
12615 INT_PTR i, *ptr = (INT_PTR *)this-1;
12617 for(i=*ptr-1; i>=0; i--)
12618 strstreambuf_dtor(this+i);
12619 MSVCRT_operator_delete(ptr);
12621 strstreambuf_dtor(this);
12623 MSVCRT_operator_delete(this);
12629 /* ?freeze@strstreambuf@std@@QAEX_N@Z */
12630 /* ?freeze@strstreambuf@std@@QEAAX_N@Z */
12631 DEFINE_THISCALL_WRAPPER(strstreambuf_freeze, 8)
12632 void __thiscall strstreambuf_freeze(strstreambuf *this, MSVCP_bool freeze)
12634 TRACE("(%p %d)\n", this, freeze);
12636 if(!freeze == !(this->strmode *STRSTATE_Frozen))
12640 this->strmode |= STRSTATE_Frozen;
12641 this->endsave = basic_streambuf_char_epptr(&this->base);
12642 basic_streambuf_char_setp_next(&this->base, basic_streambuf_char_pbase(&this->base),
12643 basic_streambuf_char_pptr(&this->base), basic_streambuf_char_eback(&this->base));
12645 this->strmode &= ~STRSTATE_Frozen;
12646 basic_streambuf_char_setp_next(&this->base, basic_streambuf_char_pbase(&this->base),
12647 basic_streambuf_char_pptr(&this->base), this->endsave);
12651 /* ?str@strstreambuf@std@@QAEPADXZ */
12652 /* ?str@strstreambuf@std@@QEAAPEADXZ */
12653 DEFINE_THISCALL_WRAPPER(strstreambuf_str, 4)
12654 char* __thiscall strstreambuf_str(strstreambuf *this)
12656 TRACE("(%p)\n", this);
12658 strstreambuf_freeze(this, TRUE);
12659 return basic_streambuf_char_gptr(&this->base);
12662 /* ?pcount@strstreambuf@std@@QBEHXZ */
12663 /* ?pcount@strstreambuf@std@@QEBA_JXZ */
12664 DEFINE_THISCALL_WRAPPER(strstreambuf_pcount, 4)
12665 streamsize __thiscall strstreambuf_pcount(const strstreambuf *this)
12667 char *ppos = basic_streambuf_char_pptr(&this->base);
12669 TRACE("(%p)\n", this);
12671 return ppos ? ppos-basic_streambuf_char_pbase(&this->base) : 0;
12674 /* ?overflow@strstreambuf@std@@MAEHH@Z */
12675 /* ?overflow@strstreambuf@std@@MEAAHH@Z */
12676 DEFINE_THISCALL_WRAPPER(strstreambuf_overflow, 8)
12677 int __thiscall strstreambuf_overflow(strstreambuf *this, int c)
12679 MSVCP_size_t old_size, size;
12682 TRACE("(%p %d)\n", this, c);
12687 if(this->strmode & STRSTATE_Frozen)
12690 ptr = basic_streambuf_char_pptr(&this->base);
12691 if(ptr && ptr<basic_streambuf_char_epptr(&this->base))
12692 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base) = c);
12694 if(!(this->strmode & STRSTATE_Dynamic) || (this->strmode & STRSTATE_Constant))
12697 ptr = basic_streambuf_char_eback(&this->base);
12698 old_size = ptr ? basic_streambuf_char_epptr(&this->base) - ptr : 0;
12700 size = old_size + old_size/2;
12701 if(size < this->minsize)
12702 size = this->minsize;
12705 buf = this->palloc(size);
12707 buf = MSVCRT_operator_new(size);
12711 memcpy(buf, ptr, old_size);
12712 if(this->strmode & STRSTATE_Allocated) {
12716 MSVCRT_operator_delete(ptr);
12719 this->strmode |= STRSTATE_Allocated;
12721 this->seekhigh = buf;
12722 basic_streambuf_char_setp(&this->base, buf, buf+size);
12723 basic_streambuf_char_setg(&this->base, buf, buf, buf);
12725 this->seekhigh = this->seekhigh-ptr+buf;
12726 basic_streambuf_char_setp_next(&this->base, basic_streambuf_char_pbase(&this->base)-ptr+buf,
12727 basic_streambuf_char_pptr(&this->base)-ptr+buf, buf+size);
12728 basic_streambuf_char_setg(&this->base, buf, basic_streambuf_char_gptr(&this->base)-ptr+buf,
12729 basic_streambuf_char_pptr(&this->base));
12732 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base) = c);
12735 /* ?pbackfail@strstreambuf@std@@MAEHH@Z */
12736 /* ?pbackfail@strstreambuf@std@@MEAAHH@Z */
12737 DEFINE_THISCALL_WRAPPER(strstreambuf_pbackfail, 8)
12738 int __thiscall strstreambuf_pbackfail(strstreambuf *this, int c)
12740 char *ptr = basic_streambuf_char_gptr(&this->base);
12742 TRACE("(%p %d)\n", this, c);
12744 if(ptr<=basic_streambuf_char_eback(&this->base)
12745 || ((this->strmode & STRSTATE_Constant) && c!=ptr[-1]))
12748 basic_streambuf_char_gbump(&this->base, -1);
12751 if(this->strmode & STRSTATE_Constant)
12752 return (unsigned char)c;
12754 return (unsigned char)(ptr[0] = c);
12757 /* ?seekoff@strstreambuf@std@@MAE?AV?$fpos@H@2@JHH@Z */
12758 /* ?seekoff@strstreambuf@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
12759 DEFINE_THISCALL_WRAPPER(strstreambuf_seekoff, 20)
12760 fpos_int* __thiscall strstreambuf_seekoff(strstreambuf *this, fpos_int *ret, streamoff off, int way, int mode)
12762 char *eback = basic_streambuf_char_eback(&this->base);
12763 char *pptr = basic_streambuf_char_pptr(&this->base);
12764 char *gptr = basic_streambuf_char_gptr(&this->base);
12766 TRACE("(%p %p %ld %d %d)\n", this, ret, off, way, mode);
12771 if(pptr > this->seekhigh)
12772 this->seekhigh = pptr;
12774 if((mode & OPENMODE_in) && gptr) {
12775 if(way==SEEKDIR_cur && !(mode & OPENMODE_out))
12777 else if(way == SEEKDIR_end)
12778 off += this->seekhigh-eback;
12779 else if(way != SEEKDIR_beg)
12782 if(off<0 || off>this->seekhigh-eback) {
12785 basic_streambuf_char_gbump(&this->base, eback-gptr+off);
12786 if((mode & OPENMODE_out) && pptr) {
12787 basic_streambuf_char_setp_next(&this->base, eback,
12788 gptr, basic_streambuf_char_epptr(&this->base));
12791 }else if((mode & OPENMODE_out) && pptr) {
12792 if(way == SEEKDIR_cur)
12794 else if(way == SEEKDIR_end)
12795 off += this->seekhigh-eback;
12796 else if(way != SEEKDIR_beg)
12799 if(off<0 || off>this->seekhigh-eback)
12802 basic_streambuf_char_pbump(&this->base, eback-pptr+off);
12811 /* ?seekpos@strstreambuf@std@@MAE?AV?$fpos@H@2@V32@H@Z */
12812 /* ?seekpos@strstreambuf@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
12813 DEFINE_THISCALL_WRAPPER(strstreambuf_seekpos, 36)
12814 fpos_int* __thiscall strstreambuf_seekpos(strstreambuf *this, fpos_int *ret, fpos_int pos, int mode)
12816 TRACE("(%p %p %s %d)\n", this, ret, debugstr_fpos_int(&pos), mode);
12818 if(pos.off==0 && pos.pos==-1 && pos.state==0) {
12823 return strstreambuf_seekoff(this, ret, pos.off, SEEKDIR_beg, mode);
12826 /* ?underflow@strstreambuf@std@@MAEHXZ */
12827 /* ?underflow@strstreambuf@std@@MEAAHXZ */
12828 DEFINE_THISCALL_WRAPPER(strstreambuf_underflow, 4)
12829 int __thiscall strstreambuf_underflow(strstreambuf *this)
12831 char *gptr = basic_streambuf_char_gptr(&this->base);
12834 TRACE("(%p)\n", this);
12839 if(gptr < basic_streambuf_char_egptr(&this->base))
12840 return (unsigned char)(*gptr);
12842 pptr = basic_streambuf_char_gptr(&this->base);
12843 if(pptr > this->seekhigh)
12844 this->seekhigh = pptr;
12846 if(this->seekhigh <= gptr)
12849 basic_streambuf_char_setg(&this->base, basic_streambuf_char_eback(&this->base),
12850 gptr, this->seekhigh);
12851 return (unsigned char)(*gptr);
12854 static void __cdecl setprecision_func(ios_base *base, streamsize prec)
12856 ios_base_precision_set(base, prec);
12859 /* ?setprecision@std@@YA?AU?$_Smanip@H@1@H@Z */
12860 /* ?setprecision@std@@YA?AU?$_Smanip@_J@1@_J@Z */
12861 manip_streamsize* __cdecl setprecision(manip_streamsize *ret, streamsize prec)
12863 TRACE("(%p %ld)\n", ret, prec);
12865 ret->pfunc = setprecision_func;
12870 static void __cdecl setw_func(ios_base *base, streamsize width)
12872 ios_base_width_set(base, width);
12875 /* ?setw@std@@YA?AU?$_Smanip@H@1@H@Z */
12876 /* ?setw@std@@YA?AU?$_Smanip@_J@1@_J@Z */
12877 manip_streamsize* __cdecl setw(manip_streamsize *ret, streamsize width)
12879 TRACE("(%p %ld)\n", ret, width);
12881 ret->pfunc = setw_func;
12886 static void __cdecl resetioflags_func(ios_base *base, int mask)
12888 ios_base_setf_mask(base, 0, mask);
12891 /* ?resetiosflags@std@@YA?AU?$_Smanip@H@1@H@Z */
12892 manip_int* __cdecl resetiosflags(manip_int *ret, int mask)
12894 TRACE("(%p %d)\n", ret, mask);
12896 ret->pfunc = resetioflags_func;
12901 static void __cdecl setiosflags_func(ios_base *base, int mask)
12903 ios_base_setf_mask(base, FMTFLAG_mask, mask);
12906 /* ?setiosflags@std@@YA?AU?$_Smanip@H@1@H@Z */
12907 manip_int* __cdecl setiosflags(manip_int *ret, int mask)
12909 TRACE("(%p %d)\n", ret, mask);
12911 ret->pfunc = setiosflags_func;
12916 static void __cdecl setbase_func(ios_base *base, int set_base)
12919 set_base = FMTFLAG_dec;
12920 else if(set_base == 8)
12921 set_base = FMTFLAG_oct;
12922 else if(set_base == 16)
12923 set_base = FMTFLAG_hex;
12927 ios_base_setf_mask(base, set_base, FMTFLAG_basefield);
12930 /* ?setbase@std@@YA?AU?$_Smanip@H@1@H@Z */
12931 manip_int* __cdecl setbase(manip_int *ret, int base)
12933 TRACE("(%p %d)\n", ret, base);
12935 ret->pfunc = setbase_func;
12940 static basic_filebuf_char filebuf_char_stdin;
12941 /* ?cin@std@@3V?$basic_istream@DU?$char_traits@D@std@@@1@A */
12943 basic_istream_char obj;
12944 basic_ios_char vbase;
12946 /* ?_Ptr_cin@std@@3PAV?$basic_istream@DU?$char_traits@D@std@@@1@A */
12947 /* ?_Ptr_cin@std@@3PEAV?$basic_istream@DU?$char_traits@D@std@@@1@EA */
12948 basic_istream_char *_Ptr_cin = &cin.obj;
12950 static basic_filebuf_wchar filebuf_short_stdin;
12951 /* ?wcin@std@@3V?$basic_istream@GU?$char_traits@G@std@@@1@A */
12953 basic_istream_wchar obj;
12954 basic_ios_wchar vbase;
12955 } ucin = { { 0 } };
12956 /* ?_Ptr_wcin@std@@3PAV?$basic_istream@GU?$char_traits@G@std@@@1@A */
12957 /* ?_Ptr_wcin@std@@3PEAV?$basic_istream@GU?$char_traits@G@std@@@1@EA */
12958 basic_istream_wchar *_Ptr_ucin = &ucin.obj;
12960 static basic_filebuf_wchar filebuf_wchar_stdin;
12961 /* ?wcin@std@@3V?$basic_istream@_WU?$char_traits@_W@std@@@1@A */
12963 basic_istream_wchar obj;
12964 basic_ios_wchar vbase;
12965 } wcin = { { 0 } };
12966 /* ?_Ptr_wcin@std@@3PAV?$basic_istream@_WU?$char_traits@_W@std@@@1@A */
12967 /* ?_Ptr_wcin@std@@3PEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@EA */
12968 basic_istream_wchar *_Ptr_wcin = &wcin.obj;
12970 static basic_filebuf_char filebuf_char_stdout;
12971 /* ?cout@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
12973 basic_ostream_char obj;
12974 basic_ios_char vbase;
12975 } cout = { { 0 } };
12976 /* ?_Ptr_cout@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
12977 /* ?_Ptr_cout@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
12978 basic_ostream_char *_Ptr_cout = &cout.obj;
12980 static basic_filebuf_wchar filebuf_short_stdout;
12981 /* ?wcout@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
12983 basic_ostream_wchar obj;
12984 basic_ios_wchar vbase;
12985 } ucout = { { 0 } };
12986 /* ?_Ptr_wcout@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
12987 /* ?_Ptr_wcout@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
12988 basic_ostream_wchar *_Ptr_ucout = &ucout.obj;
12990 static basic_filebuf_wchar filebuf_wchar_stdout;
12991 /* ?wcout@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
12993 basic_ostream_wchar obj;
12994 basic_ios_wchar vbase;
12995 } wcout = { { 0 } };
12996 /* ?_Ptr_wcout@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
12997 /* ?_Ptr_wcout@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
12998 basic_ostream_wchar *_Ptr_wcout = &wcout.obj;
13000 static basic_filebuf_char filebuf_char_stderr;
13001 /* ?cerr@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
13003 basic_ostream_char obj;
13004 basic_ios_char vbase;
13005 } cerr = { { 0 } };
13006 /* ?_Ptr_cerr@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
13007 /* ?_Ptr_cerr@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
13008 basic_ostream_char *_Ptr_cerr = &cerr.obj;
13010 static basic_filebuf_wchar filebuf_short_stderr;
13011 /* ?wcerr@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
13013 basic_ostream_wchar obj;
13014 basic_ios_wchar vbase;
13015 } ucerr = { { 0 } };
13016 /* ?_Ptr_wcerr@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
13017 /* ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
13018 basic_ostream_wchar *_Ptr_ucerr = &ucerr.obj;
13020 static basic_filebuf_wchar filebuf_wchar_stderr;
13021 /* ?wcerr@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
13023 basic_ostream_wchar obj;
13024 basic_ios_wchar vbase;
13025 } wcerr = { { 0 } };
13026 /* ?_Ptr_wcerr@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
13027 /* ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
13028 basic_ostream_wchar *_Ptr_wcerr = &wcerr.obj;
13030 static basic_filebuf_char filebuf_char_log;
13031 /* ?clog@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
13033 basic_ostream_char obj;
13034 basic_ios_char vbase;
13035 } clog = { { 0 } };
13036 /* ?_Ptr_clog@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
13037 /* ?_Ptr_clog@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
13038 basic_ostream_char *_Ptr_clog = &clog.obj;
13040 static basic_filebuf_wchar filebuf_short_log;
13041 /* ?wclog@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
13043 basic_ostream_wchar obj;
13044 basic_ios_wchar vbase;
13045 } uclog = { { 0 } };
13046 /* ?_Ptr_wclog@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
13047 /* ?_Ptr_wclog@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
13048 basic_ostream_wchar *_Ptr_uclog = &uclog.obj;
13050 static basic_filebuf_wchar filebuf_wchar_log;
13051 /* ?wclog@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
13053 basic_ostream_wchar obj;
13054 basic_ios_wchar vbase;
13055 } wclog = { { 0 } };
13056 /* ?_Ptr_wclog@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
13057 /* ?_Ptr_wclog@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
13058 basic_ostream_wchar *_Ptr_wclog = &wclog.obj;
13060 /* ?_Init_cnt@Init@ios_base@std@@0HA */
13061 int ios_base_Init__Init_cnt = -1;
13063 /* ?_Init_cnt_func@Init@ios_base@std@@CAAAHXZ */
13064 /* ?_Init_cnt_func@Init@ios_base@std@@CAAEAHXZ */
13065 int* __cdecl ios_base_Init__Init_cnt_func(void)
13067 return &ios_base_Init__Init_cnt;
13070 /* ?_Init_ctor@Init@ios_base@std@@CAXPAV123@@Z */
13071 /* ?_Init_ctor@Init@ios_base@std@@CAXPEAV123@@Z */
13072 void __cdecl ios_base_Init__Init_ctor(void *this)
13074 TRACE("(%p)\n", this);
13076 if(ios_base_Init__Init_cnt < 0)
13077 ios_base_Init__Init_cnt = 1;
13079 ios_base_Init__Init_cnt++;
13082 /* ??0Init@ios_base@std@@QAE@XZ */
13083 /* ??0Init@ios_base@std@@QEAA@XZ */
13084 DEFINE_THISCALL_WRAPPER(ios_base_Init_ctor, 4)
13085 void* __thiscall ios_base_Init_ctor(void *this)
13087 ios_base_Init__Init_ctor(this);
13091 /* ?_Init_dtor@Init@ios_base@std@@CAXPAV123@@Z */
13092 /* ?_Init_dtor@Init@ios_base@std@@CAXPEAV123@@Z */
13093 void __cdecl ios_base_Init__Init_dtor(void *this)
13095 TRACE("(%p)\n", this);
13097 ios_base_Init__Init_cnt--;
13098 if(!ios_base_Init__Init_cnt) {
13099 basic_ostream_char_flush(&cout.obj);
13100 basic_ostream_char_flush(&cerr.obj);
13101 basic_ostream_char_flush(&clog.obj);
13105 /* ??1Init@ios_base@std@@QAE@XZ */
13106 /* ??1Init@ios_base@std@@QEAA@XZ */
13107 DEFINE_THISCALL_WRAPPER(ios_base_Init_dtor, 4)
13108 void __thiscall ios_base_Init_dtor(void *this)
13110 ios_base_Init__Init_dtor(this);
13113 /* ??4Init@ios_base@std@@QAEAAV012@ABV012@@Z */
13114 /* ??4Init@ios_base@std@@QEAAAEAV012@AEBV012@@Z */
13115 DEFINE_THISCALL_WRAPPER(ios_base_Init_op_assign, 8)
13116 void* __thiscall ios_base_Init_op_assign(void *this, void *rhs)
13118 TRACE("(%p %p)\n", this, rhs);
13122 /* ?_Init_cnt@_Winit@std@@0HA */
13123 int _Winit__Init_cnt = -1;
13125 /* ??0_Winit@std@@QAE@XZ */
13126 /* ??0_Winit@std@@QEAA@XZ */
13127 DEFINE_THISCALL_WRAPPER(_Winit_ctor, 4)
13128 void* __thiscall _Winit_ctor(void *this)
13130 TRACE("(%p)\n", this);
13132 if(_Winit__Init_cnt < 0)
13133 _Winit__Init_cnt = 1;
13135 _Winit__Init_cnt++;
13140 /* ??1_Winit@std@@QAE@XZ */
13141 /* ??1_Winit@std@@QAE@XZ */
13142 DEFINE_THISCALL_WRAPPER(_Winit_dtor, 4)
13143 void __thiscall _Winit_dtor(void *this)
13145 TRACE("(%p)\n", this);
13147 _Winit__Init_cnt--;
13148 if(!_Winit__Init_cnt) {
13149 basic_ostream_wchar_flush(&wcout.obj);
13150 basic_ostream_wchar_flush(&wcerr.obj);
13151 basic_ostream_wchar_flush(&wclog.obj);
13155 /* ??4_Winit@std@@QAEAAV01@ABV01@@Z */
13156 /* ??4_Winit@std@@QEAAAEAV01@AEBV01@@Z */
13157 DEFINE_THISCALL_WRAPPER(_Winit_op_assign, 8)
13158 void* __thiscall _Winit_op_assign(void *this, void *rhs)
13160 TRACE("(%p %p)\n", this, rhs);
13164 void init_io(void *base)
13167 init_iosb_rtti(base);
13168 init_ios_base_rtti(base);
13169 init_basic_ios_char_rtti(base);
13170 init_basic_ios_wchar_rtti(base);
13171 init_basic_ios_short_rtti(base);
13172 init_basic_streambuf_char_rtti(base);
13173 init_basic_streambuf_wchar_rtti(base);
13174 init_basic_streambuf_short_rtti(base);
13175 init_basic_filebuf_char_rtti(base);
13176 init_basic_filebuf_wchar_rtti(base);
13177 init_basic_filebuf_short_rtti(base);
13178 init_basic_stringbuf_char_rtti(base);
13179 init_basic_stringbuf_wchar_rtti(base);
13180 init_basic_stringbuf_short_rtti(base);
13181 init_basic_ostream_char_rtti(base);
13182 init_basic_ostream_wchar_rtti(base);
13183 init_basic_ostream_short_rtti(base);
13184 init_basic_istream_char_rtti(base);
13185 init_basic_istream_wchar_rtti(base);
13186 init_basic_istream_short_rtti(base);
13187 init_basic_iostream_char_rtti(base);
13188 init_basic_iostream_wchar_rtti(base);
13189 init_basic_iostream_short_rtti(base);
13190 init_basic_ofstream_char_rtti(base);
13191 init_basic_ofstream_wchar_rtti(base);
13192 init_basic_ofstream_short_rtti(base);
13193 init_basic_ifstream_char_rtti(base);
13194 init_basic_ifstream_wchar_rtti(base);
13195 init_basic_ifstream_short_rtti(base);
13196 init_basic_fstream_char_rtti(base);
13197 init_basic_fstream_wchar_rtti(base);
13198 init_basic_fstream_short_rtti(base);
13199 init_basic_ostringstream_char_rtti(base);
13200 init_basic_ostringstream_wchar_rtti(base);
13201 init_basic_ostringstream_short_rtti(base);
13202 init_basic_istringstream_char_rtti(base);
13203 init_basic_istringstream_wchar_rtti(base);
13204 init_basic_istringstream_short_rtti(base);
13205 init_basic_stringstream_char_rtti(base);
13206 init_basic_stringstream_wchar_rtti(base);
13207 init_basic_stringstream_short_rtti(base);
13208 init_strstreambuf_rtti(base);
13211 basic_filebuf_char_ctor_file(&filebuf_char_stdin, stdin);
13212 basic_istream_char_ctor(&cin.obj, &filebuf_char_stdin.base, FALSE/*FIXME*/, TRUE);
13214 basic_filebuf_short_ctor_file(&filebuf_short_stdin, stdin);
13215 basic_istream_short_ctor(&ucin.obj, &filebuf_short_stdin.base, FALSE/*FIXME*/, TRUE);
13217 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stdin, stdin);
13218 basic_istream_wchar_ctor(&wcin.obj, &filebuf_wchar_stdin.base, FALSE/*FIXME*/, TRUE);
13220 basic_filebuf_char_ctor_file(&filebuf_char_stdout, stdout);
13221 basic_ostream_char_ctor(&cout.obj, &filebuf_char_stdout.base, FALSE/*FIXME*/, TRUE);
13223 basic_filebuf_short_ctor_file(&filebuf_short_stdout, stdout);
13224 basic_ostream_short_ctor(&ucout.obj, &filebuf_short_stdout.base, FALSE/*FIXME*/, TRUE);
13226 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stdout, stdout);
13227 basic_ostream_wchar_ctor(&wcout.obj, &filebuf_wchar_stdout.base, FALSE/*FIXME*/, TRUE);
13229 basic_filebuf_char_ctor_file(&filebuf_char_stderr, stderr);
13230 basic_ostream_char_ctor(&cerr.obj, &filebuf_char_stderr.base, FALSE/*FIXME*/, TRUE);
13232 basic_filebuf_short_ctor_file(&filebuf_short_stderr, stderr);
13233 basic_ostream_short_ctor(&ucerr.obj, &filebuf_short_stderr.base, FALSE/*FIXME*/, TRUE);
13235 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stderr, stderr);
13236 basic_ostream_wchar_ctor(&wcerr.obj, &filebuf_wchar_stderr.base, FALSE/*FIXME*/, TRUE);
13238 basic_filebuf_char_ctor_file(&filebuf_char_log, stderr);
13239 basic_ostream_char_ctor(&clog.obj, &filebuf_char_log.base, FALSE/*FIXME*/, TRUE);
13241 basic_filebuf_short_ctor_file(&filebuf_short_log, stderr);
13242 basic_ostream_short_ctor(&uclog.obj, &filebuf_short_log.base, FALSE/*FIXME*/, TRUE);
13244 basic_filebuf_wchar_ctor_file(&filebuf_wchar_log, stderr);
13245 basic_ostream_wchar_ctor(&wclog.obj, &filebuf_wchar_log.base, FALSE/*FIXME*/, TRUE);
13250 basic_istream_char_vbase_dtor(&cin.obj);
13251 basic_filebuf_char_dtor(&filebuf_char_stdin);
13253 basic_istream_wchar_vbase_dtor(&ucin.obj);
13254 basic_filebuf_wchar_dtor(&filebuf_short_stdin);
13256 basic_istream_wchar_vbase_dtor(&wcin.obj);
13257 basic_filebuf_wchar_dtor(&filebuf_wchar_stdin);
13259 basic_ostream_char_vbase_dtor(&cout.obj);
13260 basic_filebuf_char_dtor(&filebuf_char_stdout);
13262 basic_ostream_wchar_vbase_dtor(&ucout.obj);
13263 basic_filebuf_wchar_dtor(&filebuf_short_stdout);
13265 basic_ostream_wchar_vbase_dtor(&wcout.obj);
13266 basic_filebuf_wchar_dtor(&filebuf_wchar_stdout);
13268 basic_ostream_char_vbase_dtor(&cerr.obj);
13269 basic_filebuf_char_dtor(&filebuf_char_stderr);
13271 basic_ostream_wchar_vbase_dtor(&ucerr.obj);
13272 basic_filebuf_wchar_dtor(&filebuf_short_stderr);
13274 basic_ostream_wchar_vbase_dtor(&wcerr.obj);
13275 basic_filebuf_wchar_dtor(&filebuf_wchar_stderr);
13277 basic_ostream_char_vbase_dtor(&clog.obj);
13278 basic_filebuf_char_dtor(&filebuf_char_log);
13280 basic_ostream_wchar_vbase_dtor(&uclog.obj);
13281 basic_filebuf_wchar_dtor(&filebuf_short_log);
13283 basic_ostream_wchar_vbase_dtor(&wclog.obj);
13284 basic_filebuf_wchar_dtor(&filebuf_wchar_log);