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 #define SECSPERDAY 86400
33 /* 1601 to 1970 is 369 years plus 89 leap days */
34 #define SECS_1601_TO_1970 ((369 * 365 + 89) * (ULONGLONG)SECSPERDAY)
35 #define TICKSPERSEC 10000000
36 #define TICKS_1601_TO_1970 (SECS_1601_TO_1970 * TICKSPERSEC)
38 /* ?_Index@ios_base@std@@0HA */
39 int ios_base_Index
= 0;
40 /* ?_Sync@ios_base@std@@0_NA */
41 MSVCP_bool ios_base_Sync
= FALSE
;
45 __int64
DECLSPEC_ALIGN(8) pos
;
49 static inline const char* debugstr_fpos_int(fpos_int
*fpos
)
51 return wine_dbg_sprintf("fpos(%s %s %d)", wine_dbgstr_longlong(fpos
->off
), wine_dbgstr_longlong(fpos
->pos
), fpos
->state
);
55 void (__cdecl
*pfunc
)(ios_base
*, streamsize
);
60 void (__cdecl
*pfunc
)(ios_base
*, int);
68 } basic_filebuf__Initfl
;
71 basic_streambuf_char base
;
76 basic_string_char
*conv
;
90 basic_streambuf_wchar base
;
95 basic_string_char
*conv
;
106 } basic_filebuf_wchar
;
109 STRINGBUF_allocated
= 1,
110 STRINGBUF_no_write
= 2,
111 STRINGBUF_no_read
= 4,
112 STRINGBUF_append
= 8,
113 STRINGBUF_at_end
= 16
114 } basic_stringbuf_state
;
117 basic_streambuf_char base
;
120 char allocator
; /* empty struct */
121 } basic_stringbuf_char
;
124 basic_streambuf_wchar base
;
127 char allocator
; /* empty struct */
128 } basic_stringbuf_wchar
;
132 basic_streambuf_char
*strbuf
;
133 struct _basic_ostream_char
*stream
;
139 basic_streambuf_wchar
*strbuf
;
140 struct _basic_ostream_wchar
*stream
;
144 typedef struct _basic_ostream_char
{
146 /* virtual inheritance
147 * basic_ios_char basic_ios;
149 } basic_ostream_char
;
151 typedef struct _basic_ostream_wchar
{
153 /* virtual inheritance
154 * basic_ios_wchar basic_ios;
156 } basic_ostream_wchar
;
161 /* virtual inheritance
162 * basic_ios_char basic_ios;
164 } basic_istream_char
;
169 /* virtual inheritance
170 * basic_ios_wchar basic_ios;
172 } basic_istream_wchar
;
175 basic_istream_char base1
;
176 basic_ostream_char base2
;
177 /* virtual inheritance
178 * basic_ios_char basic_ios;
180 } basic_iostream_char
;
183 basic_istream_wchar base1
;
184 basic_ostream_wchar base2
;
185 /* virtual inheritance
186 * basic_ios_wchar basic_ios;
188 } basic_iostream_wchar
;
191 basic_ostream_char base
;
192 basic_filebuf_char filebuf
;
193 /* virtual inheritance
194 * basic_ios_char basic_ios;
196 } basic_ofstream_char
;
199 basic_ostream_wchar base
;
200 basic_filebuf_wchar filebuf
;
201 /* virtual inheritance
202 * basic_ios_wchar basic_ios;
204 } basic_ofstream_wchar
;
207 basic_istream_char base
;
208 basic_filebuf_char filebuf
;
209 /* virtual inheritance
210 * basic_ios_char basic_ios;
212 } basic_ifstream_char
;
215 basic_istream_wchar base
;
216 basic_filebuf_wchar filebuf
;
217 /* virtual inheritance
218 * basic_ios_wchar basic_ios;
220 } basic_ifstream_wchar
;
223 basic_iostream_char base
;
224 basic_filebuf_char filebuf
;
225 /* virtual inheritance
226 * basic_ios_char basic_ios;
228 } basic_fstream_char
;
231 basic_iostream_wchar base
;
232 basic_filebuf_wchar filebuf
;
233 /* virtual inheritance
234 * basic_ios_char basic_ios;
236 } basic_fstream_wchar
;
239 basic_ostream_char base
;
240 basic_stringbuf_char strbuf
;
241 /* virtual inheritance
242 * basic_ios_char basic_ios;
244 } basic_ostringstream_char
;
247 basic_ostream_wchar base
;
248 basic_stringbuf_wchar strbuf
;
249 /* virtual inheritance
250 * basic_ios_wchar basic_ios;
252 } basic_ostringstream_wchar
;
255 basic_istream_char base
;
256 basic_stringbuf_char strbuf
;
257 /* virtual inheritance
258 * basic_ios_char basic_ios;
260 } basic_istringstream_char
;
263 basic_istream_wchar base
;
264 basic_stringbuf_wchar strbuf
;
265 /* virtual inheritance
266 * basic_ios_wchar basic_ios;
268 } basic_istringstream_wchar
;
271 basic_iostream_char base
;
272 basic_stringbuf_char strbuf
;
273 /* virtual inheritance
274 * basic_ios_char basic_ios;
276 } basic_stringstream_char
;
279 basic_iostream_wchar base
;
280 basic_stringbuf_wchar strbuf
;
281 /* virtual inheritance
282 * basic_ios_wchar basic_ios;
284 } basic_stringstream_wchar
;
287 STRSTATE_Allocated
= 1,
288 STRSTATE_Constant
= 2,
289 STRSTATE_Dynamic
= 4,
291 } strstreambuf__Strstate
;
294 basic_streambuf_char base
;
299 void* (__cdecl
*palloc
)(MSVCP_size_t
);
300 void (__cdecl
*pfree
)(void*);
304 basic_ostream_char base
;
306 /* virtual inheritance
307 * basic_ios_char basic_ios;
312 basic_istream_char base
;
314 /* virtual inheritance
315 * basic_ios_char basic_ios;
320 basic_iostream_char base
;
322 /* virtual inheritance
323 * basic_ios_char basic_ios;
334 status_unknown
, file_not_found
, regular_file
, directory_file
,
335 symlink_file
, block_file
, character_file
, fifo_file
, socket_file
,
339 #if _MSVCP_VER >= 100
340 #define VBTABLE_ALIGN 8
342 #define VBTABLE_ALIGN 4
345 extern const vtable_ptr MSVCP_iosb_vtable
;
347 /* ??_7ios_base@std@@6B@ */
348 extern const vtable_ptr MSVCP_ios_base_vtable
;
350 /* ??_7?$basic_ios@DU?$char_traits@D@std@@@std@@6B@ */
351 extern const vtable_ptr MSVCP_basic_ios_char_vtable
;
353 /* ??_7?$basic_ios@_WU?$char_traits@_W@std@@@std@@6B@ */
354 extern const vtable_ptr MSVCP_basic_ios_wchar_vtable
;
356 /* ??_7?$basic_ios@GU?$char_traits@G@std@@@std@@6B@ */
357 extern const vtable_ptr MSVCP_basic_ios_short_vtable
;
359 /* ??_7?$basic_streambuf@DU?$char_traits@D@std@@@std@@6B@ */
360 extern const vtable_ptr MSVCP_basic_streambuf_char_vtable
;
362 /* ??_7?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@6B@ */
363 extern const vtable_ptr MSVCP_basic_streambuf_wchar_vtable
;
365 /* ??_7?$basic_streambuf@GU?$char_traits@G@std@@@std@@6B@ */
366 extern const vtable_ptr MSVCP_basic_streambuf_short_vtable
;
368 /* ??_7?$basic_filebuf@DU?$char_traits@D@std@@@std@@6B@ */
369 extern const vtable_ptr MSVCP_basic_filebuf_char_vtable
;
371 /* ??_7?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@6B@ */
372 extern const vtable_ptr MSVCP_basic_filebuf_wchar_vtable
;
374 /* ??_7?$basic_filebuf@GU?$char_traits@G@std@@@std@@6B@ */
375 extern const vtable_ptr MSVCP_basic_filebuf_short_vtable
;
377 /* ??_7?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
378 extern const vtable_ptr MSVCP_basic_stringbuf_char_vtable
;
380 /* ??_7?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
381 extern const vtable_ptr MSVCP_basic_stringbuf_wchar_vtable
;
383 /* ??_7?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
384 extern const vtable_ptr MSVCP_basic_stringbuf_short_vtable
;
386 /* ??_8?$basic_ostream@DU?$char_traits@D@std@@@std@@7B@ */
387 const int basic_ostream_char_vbtable
[] = {0, ALIGNED_SIZE(sizeof(basic_ostream_char
), VBTABLE_ALIGN
)};
388 /* ??_7?$basic_ostream@DU?$char_traits@D@std@@@std@@6B@ */
389 extern const vtable_ptr MSVCP_basic_ostream_char_vtable
;
391 /* ??_8?$basic_ostream@_WU?$char_traits@_W@std@@@std@@7B@ */
392 const int basic_ostream_wchar_vbtable
[] = {0, ALIGNED_SIZE(sizeof(basic_ostream_wchar
), VBTABLE_ALIGN
)};
393 /* ??_7?$basic_ostream@_WU?$char_traits@_W@std@@@std@@6B@ */
394 extern const vtable_ptr MSVCP_basic_ostream_wchar_vtable
;
396 /* ??_8?$basic_ostream@GU?$char_traits@G@std@@@std@@7B@ */
397 const int basic_ostream_short_vbtable
[] = {0, ALIGNED_SIZE(sizeof(basic_ostream_wchar
), VBTABLE_ALIGN
)};
398 /* ??_7?$basic_ostream@GU?$char_traits@G@std@@@std@@6B@ */
399 extern const vtable_ptr MSVCP_basic_ostream_short_vtable
;
401 /* ??_8?$basic_istream@DU?$char_traits@D@std@@@std@@7B@ */
402 const int basic_istream_char_vbtable
[] = {0, ALIGNED_SIZE(sizeof(basic_istream_char
), VBTABLE_ALIGN
)};
403 /* ??_7?$basic_istream@DU?$char_traits@D@std@@@std@@6B@ */
404 extern const vtable_ptr MSVCP_basic_istream_char_vtable
;
406 /* ??_8?$basic_istream@_WU?$char_traits@_W@std@@@std@@7B@ */
407 const int basic_istream_wchar_vbtable
[] = {0, ALIGNED_SIZE(sizeof(basic_istream_wchar
), VBTABLE_ALIGN
)};
408 /* ??_7?$basic_istream@_WU?$char_traits@_W@std@@@std@@6B@ */
409 extern const vtable_ptr MSVCP_basic_istream_wchar_vtable
;
411 /* ??_8?$basic_istream@GU?$char_traits@G@std@@@std@@7B@ */
412 const int basic_istream_short_vbtable
[] = {0, ALIGNED_SIZE(sizeof(basic_istream_wchar
), VBTABLE_ALIGN
)};
413 /* ??_7?$basic_istream@GU?$char_traits@G@std@@@std@@6B@ */
414 extern const vtable_ptr MSVCP_basic_istream_short_vtable
;
416 /* ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
417 const int basic_iostream_char_vbtable1
[] = {0, ALIGNED_SIZE(sizeof(basic_iostream_char
), VBTABLE_ALIGN
)};
418 /* ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
419 const int basic_iostream_char_vbtable2
[] = {0, ALIGNED_SIZE(sizeof(basic_iostream_char
), VBTABLE_ALIGN
)-FIELD_OFFSET(basic_iostream_char
, base2
)};
420 /* ??_7?$basic_iostream@DU?$char_traits@D@std@@@std@@6B@ */
421 extern const vtable_ptr MSVCP_basic_iostream_char_vtable
;
423 /* ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
424 /* ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
425 const int basic_iostream_wchar_vbtable1
[] = {0, ALIGNED_SIZE(sizeof(basic_iostream_wchar
), VBTABLE_ALIGN
)};
426 /* ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
427 /* ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
428 const int basic_iostream_wchar_vbtable2
[] = {0, ALIGNED_SIZE(sizeof(basic_iostream_wchar
), VBTABLE_ALIGN
)-FIELD_OFFSET(basic_iostream_wchar
, base2
)};
429 /* ??_7?$basic_iostream@_WU?$char_traits@_W@std@@@std@@6B@ */
430 extern const vtable_ptr MSVCP_basic_iostream_wchar_vtable
;
431 /* ??_7?$basic_iostream@GU?$char_traits@G@std@@@std@@6B@ */
432 extern const vtable_ptr MSVCP_basic_iostream_short_vtable
;
434 /* ??_8?$basic_ofstream@DU?$char_traits@D@std@@@std@@7B@ */
435 const int basic_ofstream_char_vbtable
[] = {0, sizeof(basic_ofstream_char
)};
436 /* ??_7?$basic_ofstream@DU?$char_traits@D@std@@@std@@6B@ */
437 extern const vtable_ptr MSVCP_basic_ofstream_char_vtable
;
439 /* ??_8?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@7B@ */
440 const int basic_ofstream_wchar_vbtable
[] = {0, sizeof(basic_ofstream_wchar
)};
441 /* ??_7?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@6B@ */
442 extern const vtable_ptr MSVCP_basic_ofstream_wchar_vtable
;
444 /* ??_8?$basic_ofstream@GU?$char_traits@G@std@@@std@@7B@ */
445 const int basic_ofstream_short_vbtable
[] = {0, sizeof(basic_ofstream_wchar
)};
446 /* ??_7?$basic_ofstream@GU?$char_traits@G@std@@@std@@6B@ */
447 extern const vtable_ptr MSVCP_basic_ofstream_short_vtable
;
449 /* ??_8?$basic_ifstream@DU?$char_traits@D@std@@@std@@7B@ */
450 const int basic_ifstream_char_vbtable
[] = {0, sizeof(basic_ifstream_char
)};
451 /* ??_7?$basic_ifstream@DU?$char_traits@D@std@@@std@@6B@ */
452 extern const vtable_ptr MSVCP_basic_ifstream_char_vtable
;
454 /* ??_8?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@7B@ */
455 const int basic_ifstream_wchar_vbtable
[] = {0, sizeof(basic_ifstream_wchar
)};
456 /* ??_7?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@6B@ */
457 extern const vtable_ptr MSVCP_basic_ifstream_wchar_vtable
;
459 /* ??_8?$basic_ifstream@GU?$char_traits@G@std@@@std@@7B@ */
460 const int basic_ifstream_short_vbtable
[] = {0, sizeof(basic_ifstream_wchar
)};
461 /* ??_7?$basic_ifstream@GU?$char_traits@G@std@@@std@@6B@ */
462 extern const vtable_ptr MSVCP_basic_ifstream_short_vtable
;
464 /* ??_8?$basic_fstream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
465 const int basic_fstream_char_vbtable1
[] = {0, sizeof(basic_fstream_char
)};
466 /* ??_8?$basic_fstream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
467 const int basic_fstream_char_vbtable2
[] = {0, sizeof(basic_fstream_char
)-FIELD_OFFSET(basic_fstream_char
, base
.base2
)};
468 /* ??_7?$basic_fstream@DU?$char_traits@D@std@@@std@@6B@ */
469 extern const vtable_ptr MSVCP_basic_fstream_char_vtable
;
471 /* ??_8?$basic_fstream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
472 /* ??_8?$basic_fstream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
473 const int basic_fstream_wchar_vbtable1
[] = {0, sizeof(basic_fstream_wchar
)};
474 /* ??_8?$basic_fstream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
475 /* ??_8?$basic_fstream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
476 const int basic_fstream_wchar_vbtable2
[] = {0, sizeof(basic_fstream_wchar
)-FIELD_OFFSET(basic_fstream_wchar
, base
.base2
)};
477 /* ??_7?$basic_fstream@_WU?$char_traits@_W@std@@@std@@6B@ */
478 extern const vtable_ptr MSVCP_basic_fstream_wchar_vtable
;
479 /* ??_7?$basic_fstream@GU?$char_traits@G@std@@@std@@6B@ */
480 extern const vtable_ptr MSVCP_basic_fstream_short_vtable
;
482 /* ??_8?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@ */
483 const int basic_ostringstream_char_vbtable
[] = {0, sizeof(basic_ostringstream_char
)};
484 /* ??_7?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
485 extern const vtable_ptr MSVCP_basic_ostringstream_char_vtable
;
487 /* ??_8?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B@ */
488 const int basic_ostringstream_wchar_vbtable
[] = {0, sizeof(basic_ostringstream_wchar
)};
489 /* ??_7?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
490 extern const vtable_ptr MSVCP_basic_ostringstream_wchar_vtable
;
492 /* ??_8?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B@ */
493 const int basic_ostringstream_short_vbtable
[] = {0, sizeof(basic_ostringstream_wchar
)};
494 /* ??_7?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
495 extern const vtable_ptr MSVCP_basic_ostringstream_short_vtable
;
497 /* ??_8?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@ */
498 const int basic_istringstream_char_vbtable
[] = {0, sizeof(basic_istringstream_char
)};
499 /* ??_7?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
500 extern const vtable_ptr MSVCP_basic_istringstream_char_vtable
;
502 /* ??_8?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B@ */
503 const int basic_istringstream_wchar_vbtable
[] = {0, sizeof(basic_istringstream_wchar
)};
504 /* ??_7?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
505 extern const vtable_ptr MSVCP_basic_istringstream_wchar_vtable
;
507 /* ??_8?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B@ */
508 const int basic_istringstream_short_vbtable
[] = {0, sizeof(basic_istringstream_wchar
)};
509 /* ??_7?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
510 extern const vtable_ptr MSVCP_basic_istringstream_short_vtable
;
512 /* ??_8?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
513 const int basic_stringstream_char_vbtable1
[] = {0, sizeof(basic_stringstream_char
)};
514 /* ??_8?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
515 const int basic_stringstream_char_vbtable2
[] = {0, sizeof(basic_stringstream_char
)-FIELD_OFFSET(basic_stringstream_char
, base
.base2
)};
516 /* ??_7?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
517 extern const vtable_ptr MSVCP_basic_stringstream_char_vtable
;
519 /* ??_8?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
520 const int basic_stringstream_wchar_vbtable1
[] = {0, sizeof(basic_stringstream_wchar
)};
521 /* ??_8?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
522 const int basic_stringstream_wchar_vbtable2
[] = {0, sizeof(basic_stringstream_wchar
)-FIELD_OFFSET(basic_stringstream_wchar
, base
.base2
)};
523 /* ??_7?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
524 extern const vtable_ptr MSVCP_basic_stringstream_wchar_vtable
;
526 /* ??_8?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
527 const int basic_stringstream_short_vbtable1
[] = {0, sizeof(basic_stringstream_wchar
)};
528 /* ??_8?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
529 const int basic_stringstream_short_vbtable2
[] = {0, sizeof(basic_stringstream_wchar
)-FIELD_OFFSET(basic_stringstream_wchar
, base
.base2
)};
530 /* ??_7?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
531 extern const vtable_ptr MSVCP_basic_stringstream_short_vtable
;
533 /* ??_7strstreambuf@std@@6B */
534 extern const vtable_ptr MSVCP_strstreambuf_vtable
;
536 static const int ostrstream_vbtable
[] = {0, sizeof(ostrstream
)};
537 extern const vtable_ptr MSVCP_ostrstream_vtable
;
539 static const int istrstream_vbtable
[] = {0, sizeof(istrstream
)};
541 static const int strstream_vbtable1
[] = {0, sizeof(strstream
)};
542 static const int strstream_vbtable2
[] = {0, sizeof(strstream
)-FIELD_OFFSET(strstream
, base
.base2
)};
543 extern const vtable_ptr MSVCP_strstream_vtable
;
545 DEFINE_RTTI_DATA0(iosb
, 0, ".?AV?$_Iosb@H@std@@")
546 DEFINE_RTTI_DATA1(ios_base
, 0, &iosb_rtti_base_descriptor
, ".?AV?$_Iosb@H@std@@")
547 DEFINE_RTTI_DATA2(basic_ios_char
, 0, &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
548 ".?AV?$basic_ios@DU?$char_traits@D@std@@@std@@")
549 DEFINE_RTTI_DATA2(basic_ios_wchar
, 0, &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
550 ".?AV?$basic_ios@_WU?$char_traits@_W@std@@@std@@")
551 DEFINE_RTTI_DATA2(basic_ios_short
, 0, &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
552 ".?AV?$basic_ios@GU?$char_traits@G@std@@@std@@")
553 DEFINE_RTTI_DATA0(basic_streambuf_char
, 0,
554 ".?AV?$basic_streambuf@DU?$char_traits@D@std@@@std@@")
555 DEFINE_RTTI_DATA0(basic_streambuf_wchar
, 0,
556 ".?AV?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@")
557 DEFINE_RTTI_DATA0(basic_streambuf_short
, 0,
558 ".?AV?$basic_streambuf@GU?$char_traits@G@std@@@std@@")
559 DEFINE_RTTI_DATA1(basic_filebuf_char
, 0, &basic_streambuf_char_rtti_base_descriptor
,
560 ".?AV?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@")
561 DEFINE_RTTI_DATA1(basic_filebuf_wchar
, 0, &basic_streambuf_wchar_rtti_base_descriptor
,
562 ".?AV?$basic_filebuf@GU?$char_traits@G@std@@@std@@")
563 DEFINE_RTTI_DATA1(basic_filebuf_short
, 0, &basic_streambuf_short_rtti_base_descriptor
,
564 ".?AV?$basic_filebuf@DU?$char_traits@D@std@@@std@@")
565 DEFINE_RTTI_DATA1(basic_stringbuf_char
, 0, &basic_streambuf_char_rtti_base_descriptor
,
566 ".?AV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
567 DEFINE_RTTI_DATA1(basic_stringbuf_wchar
, 0, &basic_streambuf_wchar_rtti_base_descriptor
,
568 ".?AV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
569 DEFINE_RTTI_DATA1(basic_stringbuf_short
, 0, &basic_streambuf_short_rtti_base_descriptor
,
570 ".?AV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
571 DEFINE_RTTI_DATA3(basic_ostream_char
, sizeof(basic_ostream_char
), &basic_ios_char_rtti_base_descriptor
,
572 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
573 ".?AV?$basic_ostream@DU?$char_traits@D@std@@@std@@")
574 DEFINE_RTTI_DATA3(basic_ostream_wchar
, sizeof(basic_ostream_wchar
), &basic_ios_wchar_rtti_base_descriptor
,
575 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
576 ".?AV?$basic_ostream@_WU?$char_traits@_W@std@@@std@@")
577 DEFINE_RTTI_DATA3(basic_ostream_short
, sizeof(basic_ostream_wchar
), &basic_ios_short_rtti_base_descriptor
,
578 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
579 ".?AV?$basic_ostream@GU?$char_traits@G@std@@@std@@")
580 DEFINE_RTTI_DATA3(basic_istream_char
, sizeof(basic_istream_char
), &basic_ios_char_rtti_base_descriptor
,
581 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
582 ".?AV?$basic_istream@DU?$char_traits@D@std@@@std@@")
583 DEFINE_RTTI_DATA3(basic_istream_wchar
, sizeof(basic_istream_wchar
), &basic_ios_wchar_rtti_base_descriptor
,
584 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
585 ".?AV?$basic_istream@_WU?$char_traits@_W@std@@@std@@")
586 DEFINE_RTTI_DATA3(basic_istream_short
, sizeof(basic_istream_wchar
), &basic_ios_short_rtti_base_descriptor
,
587 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
588 ".?AV?$basic_istream@GU?$char_traits@G@std@@@std@@")
589 DEFINE_RTTI_DATA8(basic_iostream_char
, sizeof(basic_iostream_char
),
590 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
591 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
592 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
593 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
594 ".?AV?$basic_iostream@DU?$char_traits@D@std@@@std@@")
595 DEFINE_RTTI_DATA8(basic_iostream_wchar
, sizeof(basic_iostream_wchar
),
596 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
597 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
598 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
599 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
600 ".?AV?$basic_iostream@_WU?$char_traits@_W@std@@@std@@")
601 DEFINE_RTTI_DATA8(basic_iostream_short
, sizeof(basic_iostream_wchar
),
602 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
603 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
604 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
605 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
606 ".?AV?$basic_iostream@GU?$char_traits@G@std@@@std@@")
607 DEFINE_RTTI_DATA4(basic_ofstream_char
, sizeof(basic_ofstream_char
),
608 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
609 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
610 ".?AV?$basic_ofstream@DU?$char_traits@D@std@@@std@@")
611 DEFINE_RTTI_DATA4(basic_ofstream_wchar
, sizeof(basic_ofstream_wchar
),
612 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
613 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
614 ".?AV?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@")
615 DEFINE_RTTI_DATA4(basic_ofstream_short
, sizeof(basic_ofstream_wchar
),
616 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
617 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
618 ".?AV?$basic_ofstream@GU?$char_traits@G@std@@@std@@")
619 DEFINE_RTTI_DATA4(basic_ifstream_char
, sizeof(basic_ifstream_char
),
620 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
621 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
622 ".?AV?$basic_ifstream@DU?$char_traits@D@std@@@std@@")
623 DEFINE_RTTI_DATA4(basic_ifstream_wchar
, sizeof(basic_ifstream_wchar
),
624 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
625 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
626 ".?AV?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@")
627 DEFINE_RTTI_DATA4(basic_ifstream_short
, sizeof(basic_ifstream_wchar
),
628 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
629 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
630 ".?AV?$basic_ifstream@GU?$char_traits@G@std@@@std@@")
631 DEFINE_RTTI_DATA8(basic_fstream_char
, sizeof(basic_fstream_char
),
632 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
633 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
634 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
635 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
636 ".?AV?$basic_fstream@DU?$char_traits@D@std@@@std@@")
637 DEFINE_RTTI_DATA8(basic_fstream_wchar
, sizeof(basic_fstream_wchar
),
638 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
639 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
640 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
641 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
642 ".?AV?$basic_fstream@_WU?$char_traits@_W@std@@@std@@")
643 DEFINE_RTTI_DATA8(basic_fstream_short
, sizeof(basic_fstream_wchar
),
644 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
645 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
646 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
647 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
648 ".?AV?$basic_fstream@GU?$char_traits@G@std@@@std@@")
649 DEFINE_RTTI_DATA4(basic_ostringstream_char
, sizeof(basic_ostringstream_char
),
650 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
651 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
652 ".?AV?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
653 DEFINE_RTTI_DATA4(basic_ostringstream_wchar
, sizeof(basic_ostringstream_wchar
),
654 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
655 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
656 ".?AV?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
657 DEFINE_RTTI_DATA4(basic_ostringstream_short
, sizeof(basic_ostringstream_wchar
),
658 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
659 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
660 ".?AV?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
661 DEFINE_RTTI_DATA4(basic_istringstream_char
, sizeof(basic_istringstream_char
),
662 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
663 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
664 ".?AV?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
665 DEFINE_RTTI_DATA4(basic_istringstream_wchar
, sizeof(basic_istringstream_wchar
),
666 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
667 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
668 ".?AV?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
669 DEFINE_RTTI_DATA4(basic_istringstream_short
, sizeof(basic_istringstream_wchar
),
670 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
671 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
672 ".?AV?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
673 DEFINE_RTTI_DATA8(basic_stringstream_char
, sizeof(basic_stringstream_char
),
674 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
675 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
676 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
677 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
678 ".?AV?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
679 DEFINE_RTTI_DATA8(basic_stringstream_wchar
, sizeof(basic_stringstream_wchar
),
680 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
681 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
682 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
683 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
684 ".?AV?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
685 DEFINE_RTTI_DATA8(basic_stringstream_short
, sizeof(basic_stringstream_wchar
),
686 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
687 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
688 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
689 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
690 ".?AV?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
691 DEFINE_RTTI_DATA1(strstreambuf
, sizeof(strstreambuf
),
692 &basic_streambuf_char_rtti_base_descriptor
, ".?AVstrstreambuf@std@@")
693 DEFINE_RTTI_DATA4(ostrstream
, sizeof(ostrstream
),
694 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
695 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
696 "?AVostrstream@std@@")
697 DEFINE_RTTI_DATA8(strstream
, sizeof(strstream
),
698 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
699 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
700 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
701 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
702 "?AVstrstream@std@@")
705 void __asm_dummy_vtables(void) {
708 VTABLE_ADD_FUNC(iosb_vector_dtor
));
709 __ASM_VTABLE(ios_base
,
710 VTABLE_ADD_FUNC(ios_base_vector_dtor
));
711 __ASM_VTABLE(basic_ios_char
,
712 VTABLE_ADD_FUNC(basic_ios_char_vector_dtor
));
713 __ASM_VTABLE(basic_ios_wchar
,
714 VTABLE_ADD_FUNC(basic_ios_wchar_vector_dtor
));
715 __ASM_VTABLE(basic_ios_short
,
716 VTABLE_ADD_FUNC(basic_ios_wchar_vector_dtor
));
717 __ASM_VTABLE(basic_streambuf_char
,
718 VTABLE_ADD_FUNC(basic_streambuf_char_vector_dtor
)
719 #if _MSVCP_VER >= 100
720 VTABLE_ADD_FUNC(basic_streambuf_char__Lock
)
721 VTABLE_ADD_FUNC(basic_streambuf_char__Unlock
)
723 VTABLE_ADD_FUNC(basic_streambuf_char_overflow
)
724 VTABLE_ADD_FUNC(basic_streambuf_char_pbackfail
)
725 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
726 VTABLE_ADD_FUNC(basic_streambuf_char_underflow
)
727 VTABLE_ADD_FUNC(basic_streambuf_char_uflow
)
728 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
729 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
730 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
732 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
733 VTABLE_ADD_FUNC(basic_streambuf_char_seekoff
)
734 VTABLE_ADD_FUNC(basic_streambuf_char_seekpos
)
735 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf
)
736 VTABLE_ADD_FUNC(basic_streambuf_char_sync
)
737 VTABLE_ADD_FUNC(basic_streambuf_char_imbue
));
738 __ASM_VTABLE(basic_streambuf_wchar
,
739 VTABLE_ADD_FUNC(basic_streambuf_wchar_vector_dtor
)
740 #if _MSVCP_VER >= 100
741 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
742 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
744 VTABLE_ADD_FUNC(basic_streambuf_wchar_overflow
)
745 VTABLE_ADD_FUNC(basic_streambuf_wchar_pbackfail
)
746 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
747 VTABLE_ADD_FUNC(basic_streambuf_wchar_underflow
)
748 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
749 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
750 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
751 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
753 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
754 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekoff
)
755 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekpos
)
756 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
757 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
758 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
759 __ASM_VTABLE(basic_streambuf_short
,
760 VTABLE_ADD_FUNC(basic_streambuf_wchar_vector_dtor
)
761 #if _MSVCP_VER >= 100
762 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
763 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
765 VTABLE_ADD_FUNC(basic_streambuf_wchar_overflow
)
766 VTABLE_ADD_FUNC(basic_streambuf_wchar_pbackfail
)
767 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
768 VTABLE_ADD_FUNC(basic_streambuf_wchar_underflow
)
769 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
770 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
771 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
772 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
774 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
775 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekoff
)
776 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekpos
)
777 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
778 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
779 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
780 __ASM_VTABLE(basic_filebuf_char
,
781 VTABLE_ADD_FUNC(basic_filebuf_char_vector_dtor
)
782 #if _MSVCP_VER >= 100
783 VTABLE_ADD_FUNC(basic_streambuf_char__Lock
)
784 VTABLE_ADD_FUNC(basic_streambuf_char__Unlock
)
786 VTABLE_ADD_FUNC(basic_filebuf_char_overflow
)
787 VTABLE_ADD_FUNC(basic_filebuf_char_pbackfail
)
788 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
789 VTABLE_ADD_FUNC(basic_filebuf_char_underflow
)
790 VTABLE_ADD_FUNC(basic_filebuf_char_uflow
)
791 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
792 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
793 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
795 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
796 VTABLE_ADD_FUNC(basic_filebuf_char_seekoff
)
797 VTABLE_ADD_FUNC(basic_filebuf_char_seekpos
)
798 VTABLE_ADD_FUNC(basic_filebuf_char_setbuf
)
799 VTABLE_ADD_FUNC(basic_filebuf_char_sync
)
800 VTABLE_ADD_FUNC(basic_filebuf_char_imbue
));
801 __ASM_VTABLE(basic_filebuf_wchar
,
802 VTABLE_ADD_FUNC(basic_filebuf_wchar_vector_dtor
)
803 #if _MSVCP_VER >= 100
804 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
805 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
807 VTABLE_ADD_FUNC(basic_filebuf_wchar_overflow
)
808 VTABLE_ADD_FUNC(basic_filebuf_wchar_pbackfail
)
809 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
810 VTABLE_ADD_FUNC(basic_filebuf_wchar_underflow
)
811 VTABLE_ADD_FUNC(basic_filebuf_wchar_uflow
)
812 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
813 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
814 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
816 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
817 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekoff
)
818 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekpos
)
819 VTABLE_ADD_FUNC(basic_filebuf_wchar_setbuf
)
820 VTABLE_ADD_FUNC(basic_filebuf_wchar_sync
)
821 VTABLE_ADD_FUNC(basic_filebuf_wchar_imbue
));
822 __ASM_VTABLE(basic_filebuf_short
,
823 VTABLE_ADD_FUNC(basic_filebuf_wchar_vector_dtor
)
824 #if _MSVCP_VER >= 100
825 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
826 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
828 VTABLE_ADD_FUNC(basic_filebuf_wchar_overflow
)
829 VTABLE_ADD_FUNC(basic_filebuf_wchar_pbackfail
)
830 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
831 VTABLE_ADD_FUNC(basic_filebuf_wchar_underflow
)
832 VTABLE_ADD_FUNC(basic_filebuf_wchar_uflow
)
833 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
834 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
835 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
837 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
838 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekoff
)
839 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekpos
)
840 VTABLE_ADD_FUNC(basic_filebuf_short_setbuf
)
841 VTABLE_ADD_FUNC(basic_filebuf_wchar_sync
)
842 VTABLE_ADD_FUNC(basic_filebuf_short_imbue
));
843 __ASM_VTABLE(basic_stringbuf_char
,
844 VTABLE_ADD_FUNC(basic_stringbuf_char_vector_dtor
)
845 VTABLE_ADD_FUNC(basic_stringbuf_char_overflow
)
846 VTABLE_ADD_FUNC(basic_stringbuf_char_pbackfail
)
847 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
848 VTABLE_ADD_FUNC(basic_stringbuf_char_underflow
)
849 VTABLE_ADD_FUNC(basic_streambuf_char_uflow
)
850 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
851 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
852 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
854 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
855 VTABLE_ADD_FUNC(basic_stringbuf_char_seekoff
)
856 VTABLE_ADD_FUNC(basic_stringbuf_char_seekpos
)
857 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf
)
858 VTABLE_ADD_FUNC(basic_streambuf_char_sync
)
859 VTABLE_ADD_FUNC(basic_streambuf_char_imbue
));
860 __ASM_VTABLE(basic_stringbuf_wchar
,
861 VTABLE_ADD_FUNC(basic_stringbuf_wchar_vector_dtor
)
862 VTABLE_ADD_FUNC(basic_stringbuf_wchar_overflow
)
863 VTABLE_ADD_FUNC(basic_stringbuf_wchar_pbackfail
)
864 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
865 VTABLE_ADD_FUNC(basic_stringbuf_wchar_underflow
)
866 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
867 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
868 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
869 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
871 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
872 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekoff
)
873 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekpos
)
874 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
875 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
876 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
877 __ASM_VTABLE(basic_stringbuf_short
,
878 VTABLE_ADD_FUNC(basic_stringbuf_wchar_vector_dtor
)
879 VTABLE_ADD_FUNC(basic_stringbuf_wchar_overflow
)
880 VTABLE_ADD_FUNC(basic_stringbuf_wchar_pbackfail
)
881 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
882 VTABLE_ADD_FUNC(basic_stringbuf_wchar_underflow
)
883 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
884 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
885 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
886 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
888 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
889 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekoff
)
890 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekpos
)
891 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
892 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
893 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
894 __ASM_VTABLE(basic_ostream_char
,
895 VTABLE_ADD_FUNC(basic_ostream_char_vector_dtor
));
896 __ASM_VTABLE(basic_ostream_wchar
,
897 VTABLE_ADD_FUNC(basic_ostream_wchar_vector_dtor
));
898 __ASM_VTABLE(basic_ostream_short
,
899 VTABLE_ADD_FUNC(basic_ostream_wchar_vector_dtor
));
900 __ASM_VTABLE(basic_istream_char
,
901 VTABLE_ADD_FUNC(basic_istream_char_vector_dtor
));
902 __ASM_VTABLE(basic_istream_wchar
,
903 VTABLE_ADD_FUNC(basic_istream_wchar_vector_dtor
));
904 __ASM_VTABLE(basic_istream_short
,
905 VTABLE_ADD_FUNC(basic_istream_wchar_vector_dtor
));
906 __ASM_VTABLE(basic_iostream_char
,
907 VTABLE_ADD_FUNC(basic_iostream_char_vector_dtor
));
908 __ASM_VTABLE(basic_iostream_wchar
,
909 VTABLE_ADD_FUNC(basic_iostream_wchar_vector_dtor
));
910 __ASM_VTABLE(basic_iostream_short
,
911 VTABLE_ADD_FUNC(basic_iostream_wchar_vector_dtor
));
912 __ASM_VTABLE(basic_ofstream_char
,
913 VTABLE_ADD_FUNC(basic_ofstream_char_vector_dtor
));
914 __ASM_VTABLE(basic_ofstream_wchar
,
915 VTABLE_ADD_FUNC(basic_ofstream_wchar_vector_dtor
));
916 __ASM_VTABLE(basic_ofstream_short
,
917 VTABLE_ADD_FUNC(basic_ofstream_wchar_vector_dtor
));
918 __ASM_VTABLE(basic_ifstream_char
,
919 VTABLE_ADD_FUNC(basic_ifstream_char_vector_dtor
));
920 __ASM_VTABLE(basic_ifstream_wchar
,
921 VTABLE_ADD_FUNC(basic_ifstream_wchar_vector_dtor
));
922 __ASM_VTABLE(basic_ifstream_short
,
923 VTABLE_ADD_FUNC(basic_ifstream_wchar_vector_dtor
));
924 __ASM_VTABLE(basic_fstream_char
,
925 VTABLE_ADD_FUNC(basic_fstream_char_vector_dtor
));
926 __ASM_VTABLE(basic_fstream_wchar
,
927 VTABLE_ADD_FUNC(basic_fstream_wchar_vector_dtor
));
928 __ASM_VTABLE(basic_fstream_short
,
929 VTABLE_ADD_FUNC(basic_fstream_wchar_vector_dtor
));
930 __ASM_VTABLE(basic_ostringstream_char
,
931 VTABLE_ADD_FUNC(basic_ostringstream_char_vector_dtor
));
932 __ASM_VTABLE(basic_ostringstream_wchar
,
933 VTABLE_ADD_FUNC(basic_ostringstream_wchar_vector_dtor
));
934 __ASM_VTABLE(basic_ostringstream_short
,
935 VTABLE_ADD_FUNC(basic_ostringstream_wchar_vector_dtor
));
936 __ASM_VTABLE(basic_istringstream_char
,
937 VTABLE_ADD_FUNC(basic_istringstream_char_vector_dtor
));
938 __ASM_VTABLE(basic_istringstream_wchar
,
939 VTABLE_ADD_FUNC(basic_istringstream_wchar_vector_dtor
));
940 __ASM_VTABLE(basic_istringstream_short
,
941 VTABLE_ADD_FUNC(basic_istringstream_wchar_vector_dtor
));
942 __ASM_VTABLE(basic_stringstream_char
,
943 VTABLE_ADD_FUNC(basic_stringstream_char_vector_dtor
));
944 __ASM_VTABLE(basic_stringstream_wchar
,
945 VTABLE_ADD_FUNC(basic_stringstream_wchar_vector_dtor
));
946 __ASM_VTABLE(basic_stringstream_short
,
947 VTABLE_ADD_FUNC(basic_stringstream_wchar_vector_dtor
));
948 __ASM_VTABLE(strstreambuf
,
949 VTABLE_ADD_FUNC(strstreambuf_vector_dtor
)
950 VTABLE_ADD_FUNC(strstreambuf_overflow
)
951 VTABLE_ADD_FUNC(strstreambuf_pbackfail
)
952 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
953 VTABLE_ADD_FUNC(strstreambuf_underflow
)
954 VTABLE_ADD_FUNC(basic_streambuf_char_uflow
)
955 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
956 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
957 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
959 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
960 VTABLE_ADD_FUNC(strstreambuf_seekoff
)
961 VTABLE_ADD_FUNC(strstreambuf_seekpos
)
962 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf
)
963 VTABLE_ADD_FUNC(basic_streambuf_char_sync
)
964 VTABLE_ADD_FUNC(basic_streambuf_char_imbue
));
965 __ASM_VTABLE(ostrstream
,
966 VTABLE_ADD_FUNC(ostrstream_vector_dtor
));
967 __ASM_VTABLE(strstream
,
968 VTABLE_ADD_FUNC(strstream_vector_dtor
));
973 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z */
974 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z */
975 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setp_next
, 16)
976 void __thiscall
basic_streambuf_char_setp_next(basic_streambuf_char
*this, char *first
, char *next
, char *last
)
978 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
982 this->wsize
= last
-next
;
985 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD0@Z */
986 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD0@Z */
987 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setp
, 12)
988 void __thiscall
basic_streambuf_char_setp(basic_streambuf_char
*this, char *first
, char *last
)
990 basic_streambuf_char_setp_next(this, first
, first
, last
);
993 /* ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z */
994 /* ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z */
995 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setg
, 16)
996 void __thiscall
basic_streambuf_char_setg(basic_streambuf_char
*this, char *first
, char *next
, char *last
)
998 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
1002 this->rsize
= last
-next
;
1005 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXXZ */
1006 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXXZ */
1007 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Init_empty
, 4)
1008 void __thiscall
basic_streambuf_char__Init_empty(basic_streambuf_char
*this)
1010 TRACE("(%p)\n", this);
1012 this->prbuf
= &this->rbuf
;
1013 this->pwbuf
= &this->wbuf
;
1014 this->prpos
= &this->rpos
;
1015 this->pwpos
= &this->wpos
;
1016 this->prsize
= &this->rsize
;
1017 this->pwsize
= &this->wsize
;
1019 basic_streambuf_char_setp(this, NULL
, NULL
);
1020 basic_streambuf_char_setg(this, NULL
, NULL
, NULL
);
1023 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@W4_Uninitialized@1@@Z */
1024 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
1025 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_ctor_uninitialized
, 8)
1026 basic_streambuf_char
* __thiscall
basic_streambuf_char_ctor_uninitialized(basic_streambuf_char
*this, int uninitialized
)
1028 TRACE("(%p %d)\n", this, uninitialized
);
1029 this->vtable
= &MSVCP_basic_streambuf_char_vtable
;
1030 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1031 mutex_ctor(&this->lock
);
1036 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@XZ */
1037 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@XZ */
1038 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_ctor
, 4)
1039 basic_streambuf_char
* __thiscall
basic_streambuf_char_ctor(basic_streambuf_char
*this)
1041 TRACE("(%p)\n", this);
1043 this->vtable
= &MSVCP_basic_streambuf_char_vtable
;
1044 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1045 mutex_ctor(&this->lock
);
1047 #if _MSVCP_VER >= 70
1048 this->loc
= MSVCRT_operator_new(sizeof(locale
));
1050 locale_ctor(IOS_LOCALE(this));
1051 basic_streambuf_char__Init_empty(this);
1056 /* ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAE@XZ */
1057 /* ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAA@XZ */
1058 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_dtor
, 4)
1059 void __thiscall
basic_streambuf_char_dtor(basic_streambuf_char
*this)
1061 TRACE("(%p)\n", this);
1063 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1064 mutex_dtor(&this->lock
);
1066 locale_dtor(IOS_LOCALE(this));
1067 #if _MSVCP_VER >= 70
1068 MSVCRT_operator_delete(this->loc
);
1072 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_vector_dtor
, 8)
1073 basic_streambuf_char
* __thiscall
basic_streambuf_char_vector_dtor(basic_streambuf_char
*this, unsigned int flags
)
1075 TRACE("(%p %x)\n", this, flags
);
1077 /* we have an array, with the number of elements stored before the first object */
1078 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
1080 for(i
=*ptr
-1; i
>=0; i
--)
1081 basic_streambuf_char_dtor(this+i
);
1082 MSVCRT_operator_delete(ptr
);
1084 basic_streambuf_char_dtor(this);
1086 MSVCRT_operator_delete(this);
1092 /* ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEHXZ */
1093 /* ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ */
1094 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gnavail
, 4)
1095 streamsize __thiscall
basic_streambuf_char__Gnavail(const basic_streambuf_char
*this)
1097 TRACE("(%p)\n", this);
1098 return *this->prpos
? *this->prsize
: 0;
1101 /* ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1102 /* ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1103 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gndec
, 4)
1104 char* __thiscall
basic_streambuf_char__Gndec(basic_streambuf_char
*this)
1106 TRACE("(%p)\n", this);
1109 return *this->prpos
;
1112 /* ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1113 /* ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1114 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gninc
, 4)
1115 char* __thiscall
basic_streambuf_char__Gninc(basic_streambuf_char
*this)
1117 TRACE("(%p)\n", this);
1119 return (*this->prpos
)++;
1122 /* ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1123 /* ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1124 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gnpreinc
, 4)
1125 char* __thiscall
basic_streambuf_char__Gnpreinc(basic_streambuf_char
*this)
1127 TRACE("(%p)\n", this);
1130 return *this->prpos
;
1133 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAPAD0PAH001@Z */
1134 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAPEAD0PEAH001@Z */
1135 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Init
, 28)
1136 void __thiscall
basic_streambuf_char__Init(basic_streambuf_char
*this, char **gf
, char **gn
, int *gc
, char **pf
, char **pn
, int *pc
)
1138 TRACE("(%p %p %p %p %p %p %p)\n", this, gf
, gn
, gc
, pf
, pn
, pc
);
1148 /* ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1149 /* ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1150 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Lock
, 4)
1151 #if _MSVCP_VER >= 100
1152 #define call_basic_streambuf_char__Lock(this) CALL_VTBL_FUNC(this, 4, void, (basic_streambuf_char*), (this))
1154 #define call_basic_streambuf_char__Lock(this) basic_streambuf_char__Lock(this)
1156 void __thiscall
basic_streambuf_char__Lock(basic_streambuf_char
*this)
1158 TRACE("(%p)\n", this);
1159 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1160 mutex_lock(&this->lock
);
1164 /* ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEHXZ */
1165 /* ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ */
1166 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Pnavail
, 4)
1167 streamsize __thiscall
basic_streambuf_char__Pnavail(const basic_streambuf_char
*this)
1169 TRACE("(%p)\n", this);
1170 return *this->pwpos
? *this->pwsize
: 0;
1173 /* ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1174 /* ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1175 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Pninc
, 4)
1176 char* __thiscall
basic_streambuf_char__Pninc(basic_streambuf_char
*this)
1178 TRACE("(%p)\n", this);
1180 return (*this->pwpos
)++;
1183 /* ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1184 /* ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1185 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_underflow
, 4)
1186 #if _MSVCP_VER >= 100
1187 #define call_basic_streambuf_char_underflow(this) CALL_VTBL_FUNC(this, 24, int, (basic_streambuf_char*), (this))
1189 #define call_basic_streambuf_char_underflow(this) CALL_VTBL_FUNC(this, 16, int, (basic_streambuf_char*), (this))
1191 int __thiscall
basic_streambuf_char_underflow(basic_streambuf_char
*this)
1193 TRACE("(%p)\n", this);
1197 /* ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1198 /* ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1199 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_uflow
, 4)
1200 #if _MSVCP_VER >= 100
1201 #define call_basic_streambuf_char_uflow(this) CALL_VTBL_FUNC(this, 28, int, (basic_streambuf_char*), (this))
1203 #define call_basic_streambuf_char_uflow(this) CALL_VTBL_FUNC(this, 20, int, (basic_streambuf_char*), (this))
1205 int __thiscall
basic_streambuf_char_uflow(basic_streambuf_char
*this)
1209 TRACE("(%p)\n", this);
1211 if(call_basic_streambuf_char_underflow(this)==EOF
)
1214 ret
= (unsigned char)**this->prpos
;
1220 /* ?_Xsgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPADIH@Z */
1221 /* ?_Xsgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_K_J@Z */
1222 #if STREAMSIZE_BITS == 64
1223 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Xsgetn_s
, 20)
1225 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Xsgetn_s
, 16)
1227 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
1228 #define call_basic_streambuf_char__Xsgetn_s(this, ptr, size, count) CALL_VTBL_FUNC(this, 28, \
1229 streamsize, (basic_streambuf_char*, char*, MSVCP_size_t, streamsize), (this, ptr, size, count))
1231 #define call_basic_streambuf_char__Xsgetn_s(this, ptr, size, count) basic_streambuf_char__Xsgetn_s(this, ptr, size, count)
1233 streamsize __thiscall
basic_streambuf_char__Xsgetn_s(basic_streambuf_char
*this, char *ptr
, MSVCP_size_t size
, streamsize count
)
1235 streamsize copied
, chunk
;
1238 TRACE("(%p %p %lu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
1240 for(copied
=0; copied
<count
&& size
;) {
1241 chunk
= basic_streambuf_char__Gnavail(this);
1242 if(chunk
> count
-copied
)
1243 chunk
= count
-copied
;
1246 memcpy_s(ptr
+copied
, size
, *this->prpos
, chunk
);
1247 *this->prpos
+= chunk
;
1248 *this->prsize
-= chunk
;
1251 }else if((c
= call_basic_streambuf_char_uflow(this)) != EOF
) {
1263 /* ?_Sgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPADIH@Z */
1264 /* ?_Sgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_K_J@Z */
1265 #if STREAMSIZE_BITS == 64
1266 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Sgetn_s
, 20)
1268 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Sgetn_s
, 16)
1270 streamsize __thiscall
basic_streambuf_char__Sgetn_s(basic_streambuf_char
*this, char *ptr
, MSVCP_size_t size
, streamsize count
)
1272 TRACE("(%p %p %lu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
1273 return call_basic_streambuf_char__Xsgetn_s(this, ptr
, size
, count
);
1276 /* ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1277 /* ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1278 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Unlock
, 4)
1279 #if _MSVCP_VER >= 100
1280 #define call_basic_streambuf_char__Unlock(this) CALL_VTBL_FUNC(this, 8, void, (basic_streambuf_char*), (this))
1282 #define call_basic_streambuf_char__Unlock(this) basic_streambuf_char__Unlock(this)
1284 void __thiscall
basic_streambuf_char__Unlock(basic_streambuf_char
*this)
1286 TRACE("(%p)\n", this);
1287 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1288 mutex_unlock(&this->lock
);
1292 /* ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1293 /* ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1294 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_eback
, 4)
1295 char* __thiscall
basic_streambuf_char_eback(const basic_streambuf_char
*this)
1297 TRACE("(%p)\n", this);
1298 return *this->prbuf
;
1301 /* ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1302 /* ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1303 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_gptr
, 4)
1304 char* __thiscall
basic_streambuf_char_gptr(const basic_streambuf_char
*this)
1306 TRACE("(%p)\n", this);
1307 return *this->prpos
;
1310 /* ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1311 /* ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1312 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_egptr
, 4)
1313 char* __thiscall
basic_streambuf_char_egptr(const basic_streambuf_char
*this)
1315 TRACE("(%p)\n", this);
1316 return *this->prpos
+*this->prsize
;
1319 /* ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1320 /* ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1321 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_epptr
, 4)
1322 char* __thiscall
basic_streambuf_char_epptr(const basic_streambuf_char
*this)
1324 TRACE("(%p)\n", this);
1325 return *this->pwpos
+*this->pwsize
;
1328 /* ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z */
1329 /* ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z */
1330 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_gbump
, 8)
1331 void __thiscall
basic_streambuf_char_gbump(basic_streambuf_char
*this, int off
)
1333 TRACE("(%p %d)\n", this, off
);
1334 *this->prpos
+= off
;
1335 *this->prsize
-= off
;
1338 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@XZ */
1339 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QBE?AVlocale@2@XZ */
1340 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@XZ */
1341 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEBA?AVlocale@2@XZ */
1342 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_getloc
, 8)
1343 locale
* __thiscall
basic_streambuf_char_getloc(const basic_streambuf_char
*this, locale
*ret
)
1345 TRACE("(%p)\n", this);
1346 return locale_copy_ctor(ret
, IOS_LOCALE(this));
1349 /* ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z */
1350 /* ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z */
1351 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_imbue
, 8)
1352 #if _MSVCP_VER >= 100
1353 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 56, void, (basic_streambuf_char*, const locale*), (this, loc))
1354 #elif _MSVCP_VER >= 80
1355 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 52, void, (basic_streambuf_char*, const locale*), (this, loc))
1357 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 48, void, (basic_streambuf_char*, const locale*), (this, loc))
1359 void __thiscall
basic_streambuf_char_imbue(basic_streambuf_char
*this, const locale
*loc
)
1361 TRACE("(%p %p)\n", this, loc
);
1364 /* ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
1365 /* ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
1366 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_overflow
, 8)
1367 #if _MSVCP_VER >= 100
1368 #define call_basic_streambuf_char_overflow(this, ch) CALL_VTBL_FUNC(this, 12, int, (basic_streambuf_char*, int), (this, ch))
1370 #define call_basic_streambuf_char_overflow(this, ch) CALL_VTBL_FUNC(this, 4, int, (basic_streambuf_char*, int), (this, ch))
1372 int __thiscall
basic_streambuf_char_overflow(basic_streambuf_char
*this, int ch
)
1374 TRACE("(%p %d)\n", this, ch
);
1378 /* ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
1379 /* ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
1380 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbackfail
, 8)
1381 #if _MSVCP_VER >= 100
1382 #define call_basic_streambuf_char_pbackfail(this, ch) CALL_VTBL_FUNC(this, 16, int, (basic_streambuf_char*, int), (this, ch))
1384 #define call_basic_streambuf_char_pbackfail(this, ch) CALL_VTBL_FUNC(this, 8, int, (basic_streambuf_char*, int), (this, ch))
1386 int __thiscall
basic_streambuf_char_pbackfail(basic_streambuf_char
*this, int ch
)
1388 TRACE("(%p %d)\n", this, ch
);
1392 /* ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1393 /* ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1394 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbase
, 4)
1395 char* __thiscall
basic_streambuf_char_pbase(const basic_streambuf_char
*this)
1397 TRACE("(%p)\n", this);
1398 return *this->pwbuf
;
1401 /* ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z */
1402 /* ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z */
1403 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbump
, 8)
1404 void __thiscall
basic_streambuf_char_pbump(basic_streambuf_char
*this, int off
)
1406 TRACE("(%p %d)\n", this, off
);
1407 *this->pwpos
+= off
;
1408 *this->pwsize
-= off
;
1411 /* ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1412 /* ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1413 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pptr
, 4)
1414 char* __thiscall
basic_streambuf_char_pptr(const basic_streambuf_char
*this)
1416 TRACE("(%p)\n", this);
1417 return *this->pwpos
;
1420 /* ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
1421 /* ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
1422 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubimbue
, 12)
1423 locale
* __thiscall
basic_streambuf_char_pubimbue(basic_streambuf_char
*this, locale
*ret
, const locale
*loc
)
1425 TRACE("(%p %p)\n", this, loc
);
1426 memcpy(ret
, IOS_LOCALE(this), sizeof(locale
));
1427 call_basic_streambuf_char_imbue(this, loc
);
1428 locale_copy_ctor(IOS_LOCALE(this), loc
);
1432 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
1433 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
1434 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
1435 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
1436 #if STREAMOFF_BITS == 64
1437 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekoff
, 24)
1439 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekoff
, 20)
1441 #if _MSVCP_VER >= 100
1442 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 40, fpos_int*, (basic_streambuf_char*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
1443 #elif _MSVCP_VER >= 80
1444 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 36, fpos_int*, (basic_streambuf_char*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
1446 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 32, fpos_int*, (basic_streambuf_char*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
1448 fpos_int
* __thiscall
basic_streambuf_char_seekoff(basic_streambuf_char
*this,
1449 fpos_int
*ret
, streamoff off
, int way
, int mode
)
1451 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
1458 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
1459 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
1460 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JFF@Z */
1461 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JFF@Z */
1462 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
1463 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
1464 #if STREAMOFF_BITS == 64
1465 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff
, 24)
1467 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff
, 20)
1469 fpos_int
* __thiscall
basic_streambuf_char_pubseekoff(basic_streambuf_char
*this,
1470 fpos_int
*ret
, streamoff off
, int way
, int mode
)
1472 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
1473 return call_basic_streambuf_char_seekoff(this, ret
, off
, way
, mode
);
1476 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
1477 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
1478 #if STREAMOFF_BITS == 64
1479 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff_old
, 24)
1481 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff_old
, 20)
1483 fpos_int
* __thiscall
basic_streambuf_char_pubseekoff_old(basic_streambuf_char
*this,
1484 fpos_int
*ret
, streamoff off
, unsigned int way
, unsigned int mode
)
1486 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
1487 return basic_streambuf_char_pubseekoff(this, ret
, off
, way
, mode
);
1490 /* ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
1491 /* ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
1492 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekpos
, 36)
1493 #if _MSVCP_VER >= 100
1494 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 44, fpos_int*, (basic_streambuf_char*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
1495 #elif _MSVCP_VER >= 80
1496 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 40, fpos_int*, (basic_streambuf_char*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
1498 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 36, fpos_int*, (basic_streambuf_char*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
1500 fpos_int
* __thiscall
basic_streambuf_char_seekpos(basic_streambuf_char
*this,
1501 fpos_int
*ret
, fpos_int pos
, int mode
)
1503 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos
), mode
);
1510 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
1511 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
1512 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekpos
, 36)
1513 fpos_int
* __thiscall
basic_streambuf_char_pubseekpos(basic_streambuf_char
*this,
1514 fpos_int
*ret
, fpos_int pos
, int mode
)
1516 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos
), mode
);
1517 return call_basic_streambuf_char_seekpos(this, ret
, pos
, mode
);
1520 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
1521 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
1522 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekpos_old
, 36)
1523 fpos_int
* __thiscall
basic_streambuf_char_pubseekpos_old(basic_streambuf_char
*this,
1524 fpos_int
*ret
, fpos_int pos
, unsigned int mode
)
1526 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos
), mode
);
1527 return basic_streambuf_char_pubseekpos(this, ret
, pos
, mode
);
1530 /* ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEPAV12@PADH@Z */
1531 /* ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAPEAV12@PEAD_J@Z */
1532 #if STREAMSIZE_BITS == 64
1533 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setbuf
, 16)
1535 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setbuf
, 12)
1537 #if _MSVCP_VER >= 100
1538 #define call_basic_streambuf_char_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 48, basic_streambuf_char*, (basic_streambuf_char*, char*, streamsize), (this, buf, count))
1539 #elif _MSVCP_VER >= 80
1540 #define call_basic_streambuf_char_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 44, basic_streambuf_char*, (basic_streambuf_char*, char*, streamsize), (this, buf, count))
1542 #define call_basic_streambuf_char_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 40, basic_streambuf_char*, (basic_streambuf_char*, char*, streamsize), (this, buf, count))
1544 basic_streambuf_char
* __thiscall
basic_streambuf_char_setbuf(basic_streambuf_char
*this, char *buf
, streamsize count
)
1546 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
1550 /* ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PADH@Z */
1551 /* ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEAD_J@Z */
1552 #if STREAMSIZE_BITS == 64
1553 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsetbuf
, 16)
1555 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsetbuf
, 12)
1557 basic_streambuf_char
* __thiscall
basic_streambuf_char_pubsetbuf(basic_streambuf_char
*this, char *buf
, streamsize count
)
1559 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
1560 return call_basic_streambuf_char_setbuf(this, buf
, count
);
1563 /* ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1564 /* ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1565 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sync
, 4)
1566 #if _MSVCP_VER >= 100
1567 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 52, int, (basic_streambuf_char*), (this))
1568 #elif _MSVCP_VER >= 80
1569 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 48, int, (basic_streambuf_char*), (this))
1571 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 44, int, (basic_streambuf_char*), (this))
1573 int __thiscall
basic_streambuf_char_sync(basic_streambuf_char
*this)
1575 TRACE("(%p)\n", this);
1579 /* ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1580 /* ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1581 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsync
, 4)
1582 int __thiscall
basic_streambuf_char_pubsync(basic_streambuf_char
*this)
1584 TRACE("(%p)\n", this);
1585 return call_basic_streambuf_char_sync(this);
1588 /* ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPADH@Z */
1589 /* ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z */
1590 #if STREAMSIZE_BITS == 64
1591 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetn
, 16)
1593 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetn
, 12)
1595 streamsize __thiscall
basic_streambuf_char_sgetn(basic_streambuf_char
*this, char *ptr
, streamsize count
)
1597 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1598 return call_basic_streambuf_char__Xsgetn_s(this, ptr
, -1, count
);
1601 /* ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1602 /* ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JXZ */
1603 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_showmanyc
, 4)
1604 #if _MSVCP_VER >= 100
1605 #define call_basic_streambuf_char_showmanyc(this) CALL_VTBL_FUNC(this, 20, streamsize, (basic_streambuf_char*), (this))
1607 #define call_basic_streambuf_char_showmanyc(this) CALL_VTBL_FUNC(this, 12, streamsize, (basic_streambuf_char*), (this))
1609 streamsize __thiscall
basic_streambuf_char_showmanyc(basic_streambuf_char
*this)
1611 TRACE("(%p)\n", this);
1615 /* ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1616 /* ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JXZ */
1617 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_in_avail
, 4)
1618 streamsize __thiscall
basic_streambuf_char_in_avail(basic_streambuf_char
*this)
1622 TRACE("(%p)\n", this);
1624 ret
= basic_streambuf_char__Gnavail(this);
1625 return ret
? ret
: call_basic_streambuf_char_showmanyc(this);
1628 /* ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z */
1629 /* ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z */
1630 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputbackc
, 8)
1631 int __thiscall
basic_streambuf_char_sputbackc(basic_streambuf_char
*this, char ch
)
1633 TRACE("(%p %d)\n", this, ch
);
1634 if(*this->prpos
&& *this->prpos
>*this->prbuf
&& (*this->prpos
)[-1]==ch
) {
1637 return (unsigned char)ch
;
1640 return call_basic_streambuf_char_pbackfail(this, (unsigned char)ch
);
1643 /* ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z */
1644 /* ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z */
1645 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputc
, 8)
1646 int __thiscall
basic_streambuf_char_sputc(basic_streambuf_char
*this, char ch
)
1648 TRACE("(%p %d)\n", this, ch
);
1649 return basic_streambuf_char__Pnavail(this) ?
1650 (unsigned char)(*basic_streambuf_char__Pninc(this) = ch
) :
1651 call_basic_streambuf_char_overflow(this, (unsigned char)ch
);
1654 /* ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1655 /* ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1656 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sungetc
, 4)
1657 int __thiscall
basic_streambuf_char_sungetc(basic_streambuf_char
*this)
1659 TRACE("(%p)\n", this);
1660 if(*this->prpos
&& *this->prpos
>*this->prbuf
) {
1663 return (unsigned char)**this->prpos
;
1666 return call_basic_streambuf_char_pbackfail(this, EOF
);
1669 /* ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1670 /* ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1671 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_stossc
, 4)
1672 void __thiscall
basic_streambuf_char_stossc(basic_streambuf_char
*this)
1674 TRACE("(%p)\n", this);
1675 if(basic_streambuf_char__Gnavail(this))
1676 basic_streambuf_char__Gninc(this);
1678 call_basic_streambuf_char_uflow(this);
1681 /* ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1682 /* ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1683 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sbumpc
, 4)
1684 int __thiscall
basic_streambuf_char_sbumpc(basic_streambuf_char
*this)
1686 TRACE("(%p)\n", this);
1687 return basic_streambuf_char__Gnavail(this) ?
1688 (int)(unsigned char)*basic_streambuf_char__Gninc(this) : call_basic_streambuf_char_uflow(this);
1691 /* ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1692 /* ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1693 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetc
, 4)
1694 int __thiscall
basic_streambuf_char_sgetc(basic_streambuf_char
*this)
1696 TRACE("(%p)\n", this);
1697 return basic_streambuf_char__Gnavail(this) ?
1698 (int)(unsigned char)*basic_streambuf_char_gptr(this) : call_basic_streambuf_char_underflow(this);
1701 /* ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1702 /* ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1703 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_snextc
, 4)
1704 int __thiscall
basic_streambuf_char_snextc(basic_streambuf_char
*this)
1706 TRACE("(%p)\n", this);
1708 if(basic_streambuf_char__Gnavail(this) > 1)
1709 return (unsigned char)*basic_streambuf_char__Gnpreinc(this);
1710 return basic_streambuf_char_sbumpc(this)==EOF
?
1711 EOF
: basic_streambuf_char_sgetc(this);
1714 /* ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPADH@Z */
1715 /* ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_J@Z */
1716 #if STREAMSIZE_BITS == 64
1717 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsgetn
, 16)
1719 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsgetn
, 12)
1721 #if _MSVCP_VER >= 100
1722 #define call_basic_streambuf_char_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_char*, char*, streamsize), (this, ptr, count))
1724 #define call_basic_streambuf_char_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 24, streamsize, (basic_streambuf_char*, char*, streamsize), (this, ptr, count))
1726 streamsize __thiscall
basic_streambuf_char_xsgetn(basic_streambuf_char
*this, char *ptr
, streamsize count
)
1728 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1729 return call_basic_streambuf_char__Xsgetn_s(this, ptr
, -1, count
);
1732 /* ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPBDH@Z */
1733 /* ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEBD_J@Z */
1734 #if STREAMSIZE_BITS == 64
1735 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsputn
, 16)
1737 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsputn
, 12)
1739 #if _MSVCP_VER >= 100
1740 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 36, streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1741 #elif _MSVCP_VER >= 80
1742 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1744 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 28, streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1746 streamsize __thiscall
basic_streambuf_char_xsputn(basic_streambuf_char
*this, const char *ptr
, streamsize count
)
1748 streamsize copied
, chunk
;
1750 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1752 for(copied
=0; copied
<count
;) {
1753 chunk
= basic_streambuf_char__Pnavail(this);
1754 if(chunk
> count
-copied
)
1755 chunk
= count
-copied
;
1758 memcpy(*this->pwpos
, ptr
+copied
, chunk
);
1759 *this->pwpos
+= chunk
;
1760 *this->pwsize
-= chunk
;
1762 }else if(call_basic_streambuf_char_overflow(this, (unsigned char)ptr
[copied
]) != EOF
) {
1772 /* ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPBDH@Z */
1773 /* ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEBD_J@Z */
1774 #if STREAMSIZE_BITS == 64
1775 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputn
, 16)
1777 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputn
, 12)
1779 streamsize __thiscall
basic_streambuf_char_sputn(basic_streambuf_char
*this, const char *ptr
, streamsize count
)
1781 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1782 return call_basic_streambuf_char_xsputn(this, ptr
, count
);
1785 /* ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z */
1786 /* ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z */
1787 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_swap
, 8)
1788 void __thiscall
basic_streambuf_char_swap(basic_streambuf_char
*this, basic_streambuf_char
*r
)
1790 basic_streambuf_char tmp
;
1792 TRACE("(%p %p)\n", this, r
);
1799 this->vtable
= tmp
.vtable
;
1800 tmp
.vtable
= r
->vtable
;
1804 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z */
1805 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z */
1806 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z */
1807 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z */
1808 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setp_next
, 16)
1809 void __thiscall
basic_streambuf_wchar_setp_next(basic_streambuf_wchar
*this, wchar_t *first
, wchar_t *next
, wchar_t *last
)
1811 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
1815 this->wsize
= last
-next
;
1818 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W0@Z */
1819 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W0@Z */
1820 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG0@Z */
1821 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG0@Z */
1822 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setp
, 12)
1823 void __thiscall
basic_streambuf_wchar_setp(basic_streambuf_wchar
*this, wchar_t *first
, wchar_t *last
)
1825 basic_streambuf_wchar_setp_next(this, first
, first
, last
);
1828 /* ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z */
1829 /* ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z */
1830 /* ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z */
1831 /* ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z */
1832 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setg
, 16)
1833 void __thiscall
basic_streambuf_wchar_setg(basic_streambuf_wchar
*this, wchar_t *first
, wchar_t *next
, wchar_t *last
)
1835 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
1839 this->rsize
= last
-next
;
1842 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXXZ */
1843 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXXZ */
1844 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXXZ */
1845 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXXZ */
1846 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Init_empty
, 4)
1847 void __thiscall
basic_streambuf_wchar__Init_empty(basic_streambuf_wchar
*this)
1849 TRACE("(%p)\n", this);
1851 this->prbuf
= &this->rbuf
;
1852 this->pwbuf
= &this->wbuf
;
1853 this->prpos
= &this->rpos
;
1854 this->pwpos
= &this->wpos
;
1855 this->prsize
= &this->rsize
;
1856 this->pwsize
= &this->wsize
;
1858 basic_streambuf_wchar_setp(this, NULL
, NULL
);
1859 basic_streambuf_wchar_setg(this, NULL
, NULL
, NULL
);
1862 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@W4_Uninitialized@1@@Z */
1863 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
1864 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_ctor_uninitialized
, 8)
1865 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_ctor_uninitialized(basic_streambuf_wchar
*this, int uninitialized
)
1867 TRACE("(%p %d)\n", this, uninitialized
);
1868 this->vtable
= &MSVCP_basic_streambuf_wchar_vtable
;
1869 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1870 mutex_ctor(&this->lock
);
1875 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@W4_Uninitialized@1@@Z */
1876 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
1877 DEFINE_THISCALL_WRAPPER(basic_streambuf_short_ctor_uninitialized
, 8)
1878 basic_streambuf_wchar
* __thiscall
basic_streambuf_short_ctor_uninitialized(basic_streambuf_wchar
*this, int uninitialized
)
1880 TRACE("(%p %d)\n", this, uninitialized
);
1881 basic_streambuf_wchar_ctor_uninitialized(this, uninitialized
);
1882 this->vtable
= &MSVCP_basic_streambuf_short_vtable
;
1886 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@XZ */
1887 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@XZ */
1888 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_ctor
, 4)
1889 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_ctor(basic_streambuf_wchar
*this)
1891 TRACE("(%p)\n", this);
1893 this->vtable
= &MSVCP_basic_streambuf_wchar_vtable
;
1894 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1895 mutex_ctor(&this->lock
);
1897 #if _MSVCP_VER >= 70
1898 this->loc
= MSVCRT_operator_new(sizeof(locale
));
1900 locale_ctor(IOS_LOCALE(this));
1901 basic_streambuf_wchar__Init_empty(this);
1906 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@XZ */
1907 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@XZ */
1908 DEFINE_THISCALL_WRAPPER(basic_streambuf_short_ctor
, 4)
1909 basic_streambuf_wchar
* __thiscall
basic_streambuf_short_ctor(basic_streambuf_wchar
*this)
1911 TRACE("(%p)\n", this);
1912 basic_streambuf_wchar_ctor(this);
1913 this->vtable
= &MSVCP_basic_streambuf_short_vtable
;
1917 /* ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
1918 /* ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
1919 /* ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAE@XZ */
1920 /* ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UEAA@XZ */
1921 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_dtor
, 4)
1922 void __thiscall
basic_streambuf_wchar_dtor(basic_streambuf_wchar
*this)
1924 TRACE("(%p)\n", this);
1926 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1927 mutex_dtor(&this->lock
);
1929 locale_dtor(IOS_LOCALE(this));
1930 #if _MSVCP_VER >= 70
1931 MSVCRT_operator_delete(this->loc
);
1935 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_vector_dtor
, 8)
1936 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_vector_dtor(basic_streambuf_wchar
*this, unsigned int flags
)
1938 TRACE("(%p %x)\n", this, flags
);
1940 /* we have an array, with the number of elements stored before the first object */
1941 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
1943 for(i
=*ptr
-1; i
>=0; i
--)
1944 basic_streambuf_wchar_dtor(this+i
);
1945 MSVCRT_operator_delete(ptr
);
1947 basic_streambuf_wchar_dtor(this);
1949 MSVCRT_operator_delete(this);
1955 /* ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
1956 /* ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ */
1957 /* ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEHXZ */
1958 /* ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ */
1959 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gnavail
, 4)
1960 streamsize __thiscall
basic_streambuf_wchar__Gnavail(const basic_streambuf_wchar
*this)
1962 TRACE("(%p)\n", this);
1963 return *this->prpos
? *this->prsize
: 0;
1966 /* ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1967 /* ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1968 /* ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1969 /* ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1970 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gndec
, 4)
1971 wchar_t* __thiscall
basic_streambuf_wchar__Gndec(basic_streambuf_wchar
*this)
1973 TRACE("(%p)\n", this);
1976 return *this->prpos
;
1979 /* ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1980 /* ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1981 /* ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1982 /* ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1983 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gninc
, 4)
1984 wchar_t* __thiscall
basic_streambuf_wchar__Gninc(basic_streambuf_wchar
*this)
1986 TRACE("(%p)\n", this);
1988 return (*this->prpos
)++;
1991 /* ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
1992 /* ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
1993 /* ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
1994 /* ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
1995 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gnpreinc
, 4)
1996 wchar_t* __thiscall
basic_streambuf_wchar__Gnpreinc(basic_streambuf_wchar
*this)
1998 TRACE("(%p)\n", this);
2001 return *this->prpos
;
2004 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPAPA_W0PAH001@Z */
2005 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAPEA_W0PEAH001@Z */
2006 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAPAG0PAH001@Z */
2007 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAPEAG0PEAH001@Z */
2008 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Init
, 28)
2009 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
)
2011 TRACE("(%p %p %p %p %p %p %p)\n", this, gf
, gn
, gc
, pf
, pn
, pc
);
2021 /* ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2022 /* ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2023 /* ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2024 /* ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2025 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Lock
, 4)
2026 void __thiscall
basic_streambuf_wchar__Lock(basic_streambuf_wchar
*this)
2028 TRACE("(%p)\n", this);
2029 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2030 mutex_lock(&this->lock
);
2034 /* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
2035 /* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ */
2036 /* ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEHXZ */
2037 /* ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ */
2038 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Pnavail
, 4)
2039 streamsize __thiscall
basic_streambuf_wchar__Pnavail(const basic_streambuf_wchar
*this)
2041 TRACE("(%p)\n", this);
2042 return *this->pwpos
? *this->pwsize
: 0;
2045 /* ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
2046 /* ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
2047 /* ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
2048 /* ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
2049 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Pninc
, 4)
2050 wchar_t* __thiscall
basic_streambuf_wchar__Pninc(basic_streambuf_wchar
*this)
2052 TRACE("(%p)\n", this);
2054 return (*this->pwpos
)++;
2057 /* ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
2058 /* ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
2059 /* ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
2060 /* ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
2061 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_underflow
, 4)
2062 #if _MSVCP_VER >= 100
2063 #define call_basic_streambuf_wchar_underflow(this) CALL_VTBL_FUNC(this, 24, unsigned short, (basic_streambuf_wchar*), (this))
2065 #define call_basic_streambuf_wchar_underflow(this) CALL_VTBL_FUNC(this, 16, unsigned short, (basic_streambuf_wchar*), (this))
2067 unsigned short __thiscall
basic_streambuf_wchar_underflow(basic_streambuf_wchar
*this)
2069 TRACE("(%p)\n", this);
2073 /* ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
2074 /* ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
2075 /* ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
2076 /* ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
2077 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_uflow
, 4)
2078 #if _MSVCP_VER >= 100
2079 #define call_basic_streambuf_wchar_uflow(this) CALL_VTBL_FUNC(this, 28, unsigned short, (basic_streambuf_wchar*), (this))
2081 #define call_basic_streambuf_wchar_uflow(this) CALL_VTBL_FUNC(this, 20, unsigned short, (basic_streambuf_wchar*), (this))
2083 unsigned short __thiscall
basic_streambuf_wchar_uflow(basic_streambuf_wchar
*this)
2087 TRACE("(%p)\n", this);
2089 if(call_basic_streambuf_wchar_underflow(this)==WEOF
)
2092 ret
= **this->prpos
;
2098 /* ?_Xsgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPA_WIH@Z */
2099 /* ?_Xsgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_K_J@Z */
2100 /* ?_Xsgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPAGIH@Z */
2101 /* ?_Xsgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_K_J@Z */
2102 #if STREAMSIZE_BITS == 64
2103 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Xsgetn_s
, 20)
2105 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Xsgetn_s
, 16)
2107 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
2108 #define call_basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count) CALL_VTBL_FUNC(this, 28, \
2109 streamsize, (basic_streambuf_wchar*, wchar_t*, MSVCP_size_t, streamsize), (this, ptr, size, count))
2111 #define call_basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count) basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count)
2113 streamsize __thiscall
basic_streambuf_wchar__Xsgetn_s(basic_streambuf_wchar
*this, wchar_t *ptr
, MSVCP_size_t size
, streamsize count
)
2115 streamsize copied
, chunk
;
2118 TRACE("(%p %p %lu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
2120 for(copied
=0; copied
<count
&& size
;) {
2121 chunk
= basic_streambuf_wchar__Gnavail(this);
2122 if(chunk
> count
-copied
)
2123 chunk
= count
-copied
;
2126 memcpy_s(ptr
+copied
, size
, *this->prpos
, chunk
*sizeof(wchar_t));
2127 *this->prpos
+= chunk
;
2128 *this->prsize
-= chunk
;
2130 size
-= chunk
*sizeof(wchar_t);
2131 }else if((c
= call_basic_streambuf_wchar_uflow(this)) != WEOF
) {
2143 /* ?_Sgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPA_WIH@Z */
2144 /* ?_Sgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_K_J@Z */
2145 /* ?_Sgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPAGIH@Z */
2146 /* ?_Sgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_K_J@Z */
2147 #if STREAMSIZE_BITS == 64
2148 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Sgetn_s
, 20)
2150 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Sgetn_s
, 16)
2152 streamsize __thiscall
basic_streambuf_wchar__Sgetn_s(basic_streambuf_wchar
*this, wchar_t *ptr
, MSVCP_size_t size
, streamsize count
)
2154 TRACE("(%p %p %lu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
2155 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr
, size
, count
);
2158 /* ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2159 /* ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2160 /* ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2161 /* ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2162 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Unlock
, 4)
2163 void __thiscall
basic_streambuf_wchar__Unlock(basic_streambuf_wchar
*this)
2165 TRACE("(%p)\n", this);
2166 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2167 mutex_unlock(&this->lock
);
2171 /* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2172 /* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2173 /* ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2174 /* ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2175 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_eback
, 4)
2176 wchar_t* __thiscall
basic_streambuf_wchar_eback(const basic_streambuf_wchar
*this)
2178 TRACE("(%p)\n", this);
2179 return *this->prbuf
;
2182 /* ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2183 /* ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2184 /* ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2185 /* ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2186 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_gptr
, 4)
2187 wchar_t* __thiscall
basic_streambuf_wchar_gptr(const basic_streambuf_wchar
*this)
2189 TRACE("(%p)\n", this);
2190 return *this->prpos
;
2193 /* ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2194 /* ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2195 /* ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2196 /* ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2197 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_egptr
, 4)
2198 wchar_t* __thiscall
basic_streambuf_wchar_egptr(const basic_streambuf_wchar
*this)
2200 TRACE("(%p)\n", this);
2201 return *this->prpos
+*this->prsize
;
2204 /* ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2205 /* ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2206 /* ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2207 /* ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2208 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_epptr
, 4)
2209 wchar_t* __thiscall
basic_streambuf_wchar_epptr(const basic_streambuf_wchar
*this)
2211 TRACE("(%p)\n", this);
2212 return *this->pwpos
+*this->pwsize
;
2215 /* ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z */
2216 /* ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z */
2217 /* ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z */
2218 /* ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z */
2219 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_gbump
, 8)
2220 void __thiscall
basic_streambuf_wchar_gbump(basic_streambuf_wchar
*this, int off
)
2222 TRACE("(%p %d)\n", this, off
);
2223 *this->prpos
+= off
;
2224 *this->prsize
-= off
;
2227 /* ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QBE?AVlocale@2@XZ */
2228 /* ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEBA?AVlocale@2@XZ */
2229 /* ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QBE?AVlocale@2@XZ */
2230 /* ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEBA?AVlocale@2@XZ */
2231 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_getloc
, 8)
2232 locale
* __thiscall
basic_streambuf_wchar_getloc(const basic_streambuf_wchar
*this, locale
*ret
)
2234 TRACE("(%p)\n", this);
2235 return locale_copy_ctor(ret
, IOS_LOCALE(this));
2238 /* ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z */
2239 /* ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z */
2240 /* ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z */
2241 /* ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z */
2242 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_imbue
, 8)
2243 #if _MSVCP_VER >= 100
2244 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 56, void, (basic_streambuf_wchar*, const locale*), (this, loc))
2245 #elif _MSVCP_VER >= 80
2246 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 52, void, (basic_streambuf_wchar*, const locale*), (this, loc))
2248 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 48, void, (basic_streambuf_wchar*, const locale*), (this, loc))
2250 void __thiscall
basic_streambuf_wchar_imbue(basic_streambuf_wchar
*this, const locale
*loc
)
2252 TRACE("(%p %p)\n", this, loc
);
2255 /* ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
2256 /* ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
2257 /* ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
2258 /* ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
2259 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_overflow
, 8)
2260 #if _MSVCP_VER >= 100
2261 #define call_basic_streambuf_wchar_overflow(this, ch) CALL_VTBL_FUNC(this, 12, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2263 #define call_basic_streambuf_wchar_overflow(this, ch) CALL_VTBL_FUNC(this, 4, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2265 unsigned short __thiscall
basic_streambuf_wchar_overflow(basic_streambuf_wchar
*this, unsigned short ch
)
2267 TRACE("(%p %d)\n", this, ch
);
2271 /* ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
2272 /* ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
2273 /* ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
2274 /* ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
2275 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbackfail
, 8)
2276 #if _MSVCP_VER >= 100
2277 #define call_basic_streambuf_wchar_pbackfail(this, ch) CALL_VTBL_FUNC(this, 16, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2279 #define call_basic_streambuf_wchar_pbackfail(this, ch) CALL_VTBL_FUNC(this, 8, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2281 unsigned short __thiscall
basic_streambuf_wchar_pbackfail(basic_streambuf_wchar
*this, unsigned short ch
)
2283 TRACE("(%p %d)\n", this, ch
);
2287 /* ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2288 /* ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2289 /* ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2290 /* ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2291 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbase
, 4)
2292 wchar_t* __thiscall
basic_streambuf_wchar_pbase(const basic_streambuf_wchar
*this)
2294 TRACE("(%p)\n", this);
2295 return *this->pwbuf
;
2298 /* ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z */
2299 /* ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z */
2300 /* ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z */
2301 /* ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z */
2302 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbump
, 8)
2303 void __thiscall
basic_streambuf_wchar_pbump(basic_streambuf_wchar
*this, int off
)
2305 TRACE("(%p %d)\n", this, off
);
2306 *this->pwpos
+= off
;
2307 *this->pwsize
-= off
;
2310 /* ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2311 /* ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2312 /* ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2313 /* ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2314 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pptr
, 4)
2315 wchar_t* __thiscall
basic_streambuf_wchar_pptr(const basic_streambuf_wchar
*this)
2317 TRACE("(%p)\n", this);
2318 return *this->pwpos
;
2321 /* ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
2322 /* ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
2323 /* ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
2324 /* ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
2325 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubimbue
, 12)
2326 locale
* __thiscall
basic_streambuf_wchar_pubimbue(basic_streambuf_wchar
*this, locale
*ret
, const locale
*loc
)
2328 TRACE("(%p %p)\n", this, loc
);
2329 memcpy(ret
, IOS_LOCALE(this), sizeof(locale
));
2330 call_basic_streambuf_wchar_imbue(this, loc
);
2331 locale_copy_ctor(IOS_LOCALE(this), loc
);
2335 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
2336 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
2337 /* ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2338 /* ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2339 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2340 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2341 #if STREAMOFF_BITS == 64
2342 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekoff
, 24)
2344 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekoff
, 20)
2346 #if _MSVCP_VER >= 100
2347 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 40, fpos_int*, (basic_streambuf_wchar*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
2348 #elif _MSVCP_VER >= 80
2349 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 36, fpos_int*, (basic_streambuf_wchar*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
2351 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) CALL_VTBL_FUNC(this, 32, fpos_int*, (basic_streambuf_wchar*, fpos_int*, streamoff, int, int), (this, ret, off, way, mode))
2353 fpos_int
* __thiscall
basic_streambuf_wchar_seekoff(basic_streambuf_wchar
*this,
2354 fpos_int
*ret
, streamoff off
, int way
, int mode
)
2356 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
2363 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
2364 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
2365 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
2366 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
2367 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JFF@Z */
2368 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JFF@Z */
2369 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
2370 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JW4seekdir@ioos_base@2@H@Z */
2371 #if STREAMOFF_BITS == 64
2372 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff
, 24)
2374 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff
, 20)
2376 fpos_int
* __thiscall
basic_streambuf_wchar_pubseekoff(basic_streambuf_wchar
*this,
2377 fpos_int
*ret
, streamoff off
, int way
, int mode
)
2379 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
2380 return call_basic_streambuf_wchar_seekoff(this, ret
, off
, way
, mode
);
2383 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
2384 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
2385 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
2386 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
2387 #if STREAMOFF_BITS == 64
2388 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff_old
, 24)
2390 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff_old
, 20)
2392 fpos_int
* __thiscall
basic_streambuf_wchar_pubseekoff_old(basic_streambuf_wchar
*this,
2393 fpos_int
*ret
, streamoff off
, unsigned int way
, unsigned int mode
)
2395 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
2396 return basic_streambuf_wchar_pubseekoff(this, ret
, off
, way
, mode
);
2399 /* ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2400 /* ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2401 /* ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2402 /* ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2403 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekpos
, 36)
2404 #if _MSVCP_VER >= 100
2405 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 44, fpos_int*, (basic_streambuf_wchar*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
2406 #elif _MSVCP_VER >= 80
2407 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 40, fpos_int*, (basic_streambuf_wchar*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
2409 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) CALL_VTBL_FUNC(this, 36, fpos_int*, (basic_streambuf_wchar*, fpos_int*, fpos_int, int), (this, ret, pos, mode))
2411 fpos_int
* __thiscall
basic_streambuf_wchar_seekpos(basic_streambuf_wchar
*this,
2412 fpos_int
*ret
, fpos_int pos
, int mode
)
2414 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos
), mode
);
2421 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
2422 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
2423 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
2424 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
2425 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekpos
, 36)
2426 fpos_int
* __thiscall
basic_streambuf_wchar_pubseekpos(basic_streambuf_wchar
*this,
2427 fpos_int
*ret
, fpos_int pos
, int mode
)
2429 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos
), mode
);
2430 return call_basic_streambuf_wchar_seekpos(this, ret
, pos
, mode
);
2433 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
2434 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
2435 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
2436 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
2437 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekpos_old
, 36)
2438 fpos_int
* __thiscall
basic_streambuf_wchar_pubseekpos_old(basic_streambuf_wchar
*this,
2439 fpos_int
*ret
, fpos_int pos
, unsigned int mode
)
2441 TRACE("(%p %s %d)\n", this, debugstr_fpos_int(&pos
), mode
);
2442 return basic_streambuf_wchar_pubseekpos(this, ret
, pos
, mode
);
2445 /* ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEPAV12@PA_WH@Z */
2446 /* ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV12@PEA_W_J@Z */
2447 /* ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEPAV12@PAGH@Z */
2448 /* ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAPEAV12@PEAG_J@Z */
2449 #if STREAMSIZE_BITS == 64
2450 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setbuf
, 16)
2452 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setbuf
, 12)
2454 #if _MSVCP_VER >= 100
2455 #define call_basic_streambuf_wchar_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 48, basic_streambuf_wchar*, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, buf, count))
2456 #elif _MSVCP_VER >= 80
2457 #define call_basic_streambuf_wchar_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 44, basic_streambuf_wchar*, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, buf, count))
2459 #define call_basic_streambuf_wchar_setbuf(this, buf, count) CALL_VTBL_FUNC(this, 40, basic_streambuf_wchar*, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, buf, count))
2461 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_setbuf(basic_streambuf_wchar
*this, wchar_t *buf
, streamsize count
)
2463 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
2467 /* ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PA_WH@Z */
2468 /* ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEA_W_J@Z */
2469 /* ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PAGH@Z */
2470 /* ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEAG_J@Z */
2471 #if STREAMSIZE_BITS == 64
2472 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsetbuf
, 16)
2474 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsetbuf
, 12)
2476 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_pubsetbuf(basic_streambuf_wchar
*this, wchar_t *buf
, streamsize count
)
2478 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
2479 return call_basic_streambuf_wchar_setbuf(this, buf
, count
);
2482 /* ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
2483 /* ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ */
2484 /* ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
2485 /* ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAHXZ */
2486 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sync
, 4)
2487 #if _MSVCP_VER >= 100
2488 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 52, int, (basic_streambuf_wchar*), (this))
2489 #elif _MSVCP_VER >= 80
2490 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 48, int, (basic_streambuf_wchar*), (this))
2492 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 44, int, (basic_streambuf_wchar*), (this))
2494 int __thiscall
basic_streambuf_wchar_sync(basic_streambuf_wchar
*this)
2496 TRACE("(%p)\n", this);
2500 /* ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
2501 /* ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAHXZ */
2502 /* ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ */
2503 /* ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHXZ */
2504 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsync
, 4)
2505 int __thiscall
basic_streambuf_wchar_pubsync(basic_streambuf_wchar
*this)
2507 TRACE("(%p)\n", this);
2508 return call_basic_streambuf_wchar_sync(this);
2511 /* ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPA_WH@Z */
2512 /* ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_J@Z */
2513 /* ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPAGH@Z */
2514 /* ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_J@Z */
2515 #if STREAMSIZE_BITS == 64
2516 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsgetn
, 16)
2518 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsgetn
, 12)
2520 #if _MSVCP_VER >= 100
2521 #define call_basic_streambuf_wchar_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, ptr, count))
2523 #define call_basic_streambuf_wchar_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 24, streamsize, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, ptr, count))
2525 streamsize __thiscall
basic_streambuf_wchar_xsgetn(basic_streambuf_wchar
*this, wchar_t *ptr
, streamsize count
)
2527 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2528 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr
, -1, count
);
2531 /* ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPA_WH@Z */
2532 /* ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z */
2533 /* ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPAGH@Z */
2534 /* ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z */
2535 #if STREAMSIZE_BITS == 64
2536 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetn
, 16)
2538 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetn
, 12)
2540 streamsize __thiscall
basic_streambuf_wchar_sgetn(basic_streambuf_wchar
*this, wchar_t *ptr
, streamsize count
)
2542 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2543 return call_basic_streambuf_wchar_xsgetn(this, ptr
, count
);
2546 /* ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
2547 /* ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JXZ */
2548 /* ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
2549 /* ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JXZ */
2550 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_showmanyc
, 4)
2551 #if _MSVCP_VER >= 100
2552 #define call_basic_streambuf_wchar_showmanyc(this) CALL_VTBL_FUNC(this, 20, streamsize, (basic_streambuf_wchar*), (this))
2554 #define call_basic_streambuf_wchar_showmanyc(this) CALL_VTBL_FUNC(this, 12, streamsize, (basic_streambuf_wchar*), (this))
2556 streamsize __thiscall
basic_streambuf_wchar_showmanyc(basic_streambuf_wchar
*this)
2558 TRACE("(%p)\n", this);
2562 /* ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
2563 /* ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JXZ */
2564 /* ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ */
2565 /* ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JXZ */
2566 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_in_avail
, 4)
2567 streamsize __thiscall
basic_streambuf_wchar_in_avail(basic_streambuf_wchar
*this)
2571 TRACE("(%p)\n", this);
2573 ret
= basic_streambuf_wchar__Gnavail(this);
2574 return ret
? ret
: call_basic_streambuf_wchar_showmanyc(this);
2577 /* ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z */
2578 /* ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z */
2579 /* ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z */
2580 /* ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGG@Z */
2581 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputbackc
, 8)
2582 unsigned short __thiscall
basic_streambuf_wchar_sputbackc(basic_streambuf_wchar
*this, wchar_t ch
)
2584 TRACE("(%p %d)\n", this, ch
);
2585 if(*this->prpos
&& *this->prpos
>*this->prbuf
&& (*this->prpos
)[-1]==ch
) {
2591 return call_basic_streambuf_wchar_pbackfail(this, ch
);
2594 /* ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z */
2595 /* ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z */
2596 /* ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z */
2597 /* ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHG@Z */
2598 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputc
, 8)
2599 unsigned short __thiscall
basic_streambuf_wchar_sputc(basic_streambuf_wchar
*this, wchar_t ch
)
2601 TRACE("(%p %d)\n", this, ch
);
2602 return basic_streambuf_wchar__Pnavail(this) ?
2603 (*basic_streambuf_wchar__Pninc(this) = ch
) :
2604 call_basic_streambuf_wchar_overflow(this, ch
);
2607 /* ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2608 /* ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2609 /* ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2610 /* ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2611 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sungetc
, 4)
2612 unsigned short __thiscall
basic_streambuf_wchar_sungetc(basic_streambuf_wchar
*this)
2614 TRACE("(%p)\n", this);
2615 if(*this->prpos
&& *this->prpos
>*this->prbuf
) {
2618 return **this->prpos
;
2621 return call_basic_streambuf_wchar_pbackfail(this, WEOF
);
2624 /* ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2625 /* ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2626 /* ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2627 /* ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2628 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_stossc
, 4)
2629 void __thiscall
basic_streambuf_wchar_stossc(basic_streambuf_wchar
*this)
2631 TRACE("(%p)\n", this);
2632 if(basic_streambuf_wchar__Gnavail(this))
2633 basic_streambuf_wchar__Gninc(this);
2635 call_basic_streambuf_wchar_uflow(this);
2638 /* ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2639 /* ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2640 /* ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2641 /* ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2642 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sbumpc
, 4)
2643 unsigned short __thiscall
basic_streambuf_wchar_sbumpc(basic_streambuf_wchar
*this)
2645 TRACE("(%p)\n", this);
2646 return basic_streambuf_wchar__Gnavail(this) ?
2647 *basic_streambuf_wchar__Gninc(this) : call_basic_streambuf_wchar_uflow(this);
2650 /* ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2651 /* ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2652 /* ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2653 /* ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2654 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetc
, 4)
2655 unsigned short __thiscall
basic_streambuf_wchar_sgetc(basic_streambuf_wchar
*this)
2657 TRACE("(%p)\n", this);
2658 return basic_streambuf_wchar__Gnavail(this) ?
2659 *basic_streambuf_wchar_gptr(this) : call_basic_streambuf_wchar_underflow(this);
2662 /* ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2663 /* ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2664 /* ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2665 /* ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2666 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_snextc
, 4)
2667 unsigned short __thiscall
basic_streambuf_wchar_snextc(basic_streambuf_wchar
*this)
2669 TRACE("(%p)\n", this);
2671 if(basic_streambuf_wchar__Gnavail(this) > 1)
2672 return *basic_streambuf_wchar__Gnpreinc(this);
2673 return basic_streambuf_wchar_sbumpc(this)==WEOF
?
2674 WEOF
: basic_streambuf_wchar_sgetc(this);
2677 /* ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPB_WH@Z */
2678 /* ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEB_W_J@Z */
2679 /* ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPBGH@Z */
2680 /* ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEBG_J@Z */
2681 #if STREAMSIZE_BITS == 64
2682 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsputn
, 16)
2684 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsputn
, 12)
2686 #if _MSVCP_VER >= 100
2687 #define call_basic_streambuf_wchar_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 36, streamsize, (basic_streambuf_wchar*, const wchar_t*, streamsize), (this, ptr, count))
2688 #elif _MSVCP_VER >= 80
2689 #define call_basic_streambuf_wchar_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_wchar*, const wchar_t*, streamsize), (this, ptr, count))
2691 #define call_basic_streambuf_wchar_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 28, streamsize, (basic_streambuf_wchar*, const wchar_t*, streamsize), (this, ptr, count))
2693 streamsize __thiscall
basic_streambuf_wchar_xsputn(basic_streambuf_wchar
*this, const wchar_t *ptr
, streamsize count
)
2695 streamsize copied
, chunk
;
2697 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2699 for(copied
=0; copied
<count
;) {
2700 chunk
= basic_streambuf_wchar__Pnavail(this);
2701 if(chunk
> count
-copied
)
2702 chunk
= count
-copied
;
2705 memcpy(*this->pwpos
, ptr
+copied
, chunk
*sizeof(wchar_t));
2706 *this->pwpos
+= chunk
;
2707 *this->pwsize
-= chunk
;
2709 }else if(call_basic_streambuf_wchar_overflow(this, ptr
[copied
]) != WEOF
) {
2719 /* ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPB_WH@Z */
2720 /* ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEB_W_J@Z */
2721 /* ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPBGH@Z */
2722 /* ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEBG_J@Z */
2723 #if STREAMSIZE_BITS == 64
2724 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputn
, 16)
2726 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputn
, 12)
2728 streamsize __thiscall
basic_streambuf_wchar_sputn(basic_streambuf_wchar
*this, const wchar_t *ptr
, streamsize count
)
2730 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2731 return call_basic_streambuf_wchar_xsputn(this, ptr
, count
);
2734 /* ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z */
2735 /* ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z */
2736 /* ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z */
2737 /* ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z */
2738 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_swap
, 8)
2739 void __thiscall
basic_streambuf_wchar_swap(basic_streambuf_wchar
*this, basic_streambuf_wchar
*r
)
2741 basic_streambuf_wchar tmp
;
2743 TRACE("(%p %p)\n", this, r
);
2750 this->vtable
= tmp
.vtable
;
2751 tmp
.vtable
= r
->vtable
;
2755 /* ?_Stinit@?1??_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
2756 /* ?_Stinit@?1??_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
2757 int basic_filebuf_char__Init__Stinit
= 0;
2759 /* ?_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
2760 /* ?_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
2761 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Init
, 12)
2762 void __thiscall
basic_filebuf_char__Init(basic_filebuf_char
*this, FILE *file
, basic_filebuf__Initfl which
)
2764 TRACE("(%p %p %d)\n", this, file
, which
);
2767 this->wrotesome
= FALSE
;
2768 this->state
= basic_filebuf_char__Init__Stinit
;
2769 this->close
= (which
== INITFL_open
);
2772 basic_streambuf_char__Init_empty(&this->base
);
2774 basic_streambuf_char__Init(&this->base
, &file
->_base
, &file
->_ptr
,
2775 &file
->_cnt
, &file
->_base
, &file
->_ptr
, &file
->_cnt
);
2778 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAV?$codecvt@DDH@2@@Z */
2779 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$codecvt@DDH@2@@Z */
2780 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Initcvt_cvt
, 8)
2781 void __thiscall
basic_filebuf_char__Initcvt_cvt(basic_filebuf_char
*this, codecvt_char
*cvt
)
2783 TRACE("(%p %p)\n", this, cvt
);
2785 if(codecvt_base_always_noconv(&cvt
->base
)) {
2788 basic_streambuf_char__Init_empty(&this->base
);
2793 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXXZ */
2794 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXXZ */
2795 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Initcvt
, 4)
2796 void __thiscall
basic_filebuf_char__Initcvt(basic_filebuf_char
*this)
2798 codecvt_char
*cvt
= codecvt_char_use_facet(IOS_LOCALE(&this->base
));
2799 basic_filebuf_char__Initcvt_cvt( this, cvt
);
2802 /* ?_Endwrite@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAE_NXZ */
2803 /* ?_Endwrite@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAA_NXZ */
2804 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Endwrite
, 4)
2805 MSVCP_bool __thiscall
basic_filebuf_char__Endwrite(basic_filebuf_char
*this)
2807 TRACE("(%p)\n", this);
2809 if(!this->wrotesome
|| !this->cvt
)
2813 if(call_basic_streambuf_char_overflow(&this->base
, EOF
) == EOF
)
2817 /* TODO: check if we need a dynamic buffer here */
2822 ret
= codecvt_char_unshift(this->cvt
, &this->state
, buf
, buf
+sizeof(buf
), &next
);
2825 this->wrotesome
= FALSE
;
2827 case CODECVT_partial
:
2828 if(!fwrite(buf
, next
-buf
, 1, this->file
))
2833 case CODECVT_noconv
:
2834 if(call_basic_streambuf_char_overflow(&this->base
, EOF
) == EOF
)
2843 /* ?close@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@XZ */
2844 /* ?close@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@XZ */
2845 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_close
, 4)
2846 basic_filebuf_char
* __thiscall
basic_filebuf_char_close(basic_filebuf_char
*this)
2848 basic_filebuf_char
*ret
= this;
2850 TRACE("(%p)\n", this);
2855 /* TODO: handle exceptions */
2856 if(!basic_filebuf_char__Endwrite(this))
2858 if(fclose(this->file
))
2861 basic_filebuf_char__Init(this, NULL
, INITFL_close
);
2865 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
2866 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
2867 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor_file
, 8)
2868 basic_filebuf_char
* __thiscall
basic_filebuf_char_ctor_file(basic_filebuf_char
*this, FILE *file
)
2870 TRACE("(%p %p)\n", this, file
);
2872 basic_streambuf_char_ctor(&this->base
);
2873 this->base
.vtable
= &MSVCP_basic_filebuf_char_vtable
;
2875 basic_filebuf_char__Init(this, file
, INITFL_new
);
2879 /* ??_F?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
2880 /* ??_F?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
2881 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor
, 4)
2882 basic_filebuf_char
* __thiscall
basic_filebuf_char_ctor(basic_filebuf_char
*this)
2884 return basic_filebuf_char_ctor_file(this, NULL
);
2887 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z */
2888 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
2889 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor_uninitialized
, 8)
2890 basic_filebuf_char
* __thiscall
basic_filebuf_char_ctor_uninitialized(basic_filebuf_char
*this, int uninitialized
)
2892 TRACE("(%p %d)\n", this, uninitialized
);
2894 basic_streambuf_char_ctor(&this->base
);
2895 this->base
.vtable
= &MSVCP_basic_filebuf_char_vtable
;
2899 /* ??1?$basic_filebuf@DU?$char_traits@D@std@@@std@@UAE@XZ */
2900 /* ??1?$basic_filebuf@DU?$char_traits@D@std@@@std@@UEAA@XZ */
2901 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_dtor
, 4)
2902 void __thiscall
basic_filebuf_char_dtor(basic_filebuf_char
*this)
2904 TRACE("(%p)\n", this);
2907 basic_filebuf_char_close(this);
2908 basic_streambuf_char_dtor(&this->base
);
2911 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_vector_dtor
, 8)
2912 basic_filebuf_char
* __thiscall
basic_filebuf_char_vector_dtor(basic_filebuf_char
*this, unsigned int flags
)
2914 TRACE("(%p %x)\n", this, flags
);
2916 /* we have an array, with the number of elements stored before the first object */
2917 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
2919 for(i
=*ptr
-1; i
>=0; i
--)
2920 basic_filebuf_char_dtor(this+i
);
2921 MSVCRT_operator_delete(ptr
);
2923 basic_filebuf_char_dtor(this);
2925 MSVCRT_operator_delete(this);
2931 /* ?is_open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QBE_NXZ */
2932 /* ?is_open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
2933 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_is_open
, 4)
2934 MSVCP_bool __thiscall
basic_filebuf_char_is_open(const basic_filebuf_char
*this)
2936 TRACE("(%p)\n", this);
2937 return this->file
!= NULL
;
2940 /* ?_Fiopen@std@@YAPAU_iobuf@@PB_WHH@Z */
2941 /* ?_Fiopen@std@@YAPEAU_iobuf@@PEB_WHH@Z */
2942 FILE* __cdecl
_Fiopen_wchar(const wchar_t *name
, int mode
, int prot
)
2944 static const wchar_t rW
[] = {'r',0};
2945 static const struct {
2947 const wchar_t str
[4];
2948 const wchar_t str_bin
[4];
2950 {OPENMODE_out
, {'w',0}, {'w','b',0}},
2951 {OPENMODE_out
|OPENMODE_app
, {'a',0}, {'a','b',0}},
2952 {OPENMODE_app
, {'a',0}, {'a','b',0}},
2953 {OPENMODE_out
|OPENMODE_trunc
, {'w',0}, {'w','b',0}},
2954 {OPENMODE_in
, {'r',0}, {'r','b',0}},
2955 {OPENMODE_in
|OPENMODE_out
, {'r','+',0}, {'r','+','b',0}},
2956 {OPENMODE_in
|OPENMODE_out
|OPENMODE_trunc
, {'w','+',0}, {'w','+','b',0}},
2957 {OPENMODE_in
|OPENMODE_out
|OPENMODE_app
, {'a','+',0}, {'a','+','b',0}},
2958 {OPENMODE_in
|OPENMODE_app
, {'a','+',0}, {'a','+','b',0}}
2961 int real_mode
= mode
& ~(OPENMODE_ate
|OPENMODE__Nocreate
|OPENMODE__Noreplace
|OPENMODE_binary
);
2965 TRACE("(%s %d %d)\n", debugstr_w(name
), mode
, prot
);
2967 for(mode_idx
=0; mode_idx
<sizeof(str_mode
)/sizeof(str_mode
[0]); mode_idx
++)
2968 if(str_mode
[mode_idx
].mode
== real_mode
)
2970 if(mode_idx
== sizeof(str_mode
)/sizeof(str_mode
[0]))
2973 if((mode
& OPENMODE__Nocreate
) && !(f
= _wfopen(name
, rW
)))
2978 if((mode
& OPENMODE__Noreplace
) && (mode
& (OPENMODE_out
|OPENMODE_app
))
2979 && (f
= _wfopen(name
, rW
))) {
2984 #if _MSVCP_VER < 80 /* msvcp60 - msvcp71 are ignoring prot argument */
2988 f
= _wfsopen(name
, (mode
& OPENMODE_binary
) ? str_mode
[mode_idx
].str_bin
2989 : str_mode
[mode_idx
].str
, prot
);
2993 if((mode
& OPENMODE_ate
) && fseek(f
, 0, SEEK_END
)) {
3001 /* ?_Fiopen@std@@YAPAU_iobuf@@PBDHH@Z */
3002 /* ?_Fiopen@std@@YAPEAU_iobuf@@PEBDHH@Z */
3003 FILE* __cdecl
_Fiopen(const char *name
, int mode
, int prot
)
3005 wchar_t nameW
[FILENAME_MAX
];
3007 TRACE("(%s %d %d)\n", name
, mode
, prot
);
3009 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3011 return _Fiopen_wchar(nameW
, mode
, prot
);
3014 /* ?__Fiopen@std@@YAPAU_iobuf@@PBDH@Z */
3015 /* ?__Fiopen@std@@YAPEAU_iobuf@@PEBDH@Z */
3016 FILE* __cdecl
___Fiopen(const char *name
, int mode
)
3018 TRACE("(%p %d)\n", name
, mode
);
3019 return _Fiopen(name
, mode
, _SH_DENYNO
);
3022 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PB_WHH@Z */
3023 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3024 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBGHH@Z */
3025 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3026 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_wchar
, 16)
3027 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_wchar(basic_filebuf_char
*this, const wchar_t *name
, int mode
, int prot
)
3031 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
3033 if(basic_filebuf_char_is_open(this))
3036 if(!(f
= _Fiopen_wchar(name
, mode
, prot
)))
3039 basic_filebuf_char__Init(this, f
, INITFL_open
);
3040 basic_filebuf_char__Initcvt_cvt(this, codecvt_char_use_facet(IOS_LOCALE(&this->base
)));
3044 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PB_WI@Z */
3045 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3046 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBGI@Z */
3047 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBGI@Z */
3048 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_wchar_mode
, 12)
3049 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_wchar_mode(basic_filebuf_char
*this, const wchar_t *name
, unsigned int mode
)
3051 return basic_filebuf_char_open_wchar(this, name
, mode
, SH_DENYNO
);
3054 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDHH@Z */
3055 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3056 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open
, 16)
3057 basic_filebuf_char
* __thiscall
basic_filebuf_char_open(basic_filebuf_char
*this, const char *name
, int mode
, int prot
)
3059 wchar_t nameW
[FILENAME_MAX
];
3061 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
3063 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3065 return basic_filebuf_char_open_wchar(this, nameW
, mode
, prot
);
3068 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDF@Z */
3069 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDF@Z */
3070 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_mode_old
, 12)
3071 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_mode_old(basic_filebuf_char
*this, const char *name
, short mode
)
3073 TRACE("(%p %p %d)\n", this, name
, mode
);
3074 return basic_filebuf_char_open(this, name
, mode
, SH_DENYNO
);
3077 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDH@Z */
3078 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDH@Z */
3079 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDI@Z */
3080 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDI@Z */
3081 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_mode
, 12)
3082 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_mode(basic_filebuf_char
*this, const char *name
, unsigned int mode
)
3084 return basic_filebuf_char_open(this, name
, mode
, SH_DENYNO
);
3087 /* ?overflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
3088 /* ?overflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
3089 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_overflow
, 8)
3090 int __thiscall
basic_filebuf_char_overflow(basic_filebuf_char
*this, int c
)
3092 char buf
[8], *dyn_buf
;
3093 char ch
= c
, *to_next
;
3094 const char *from_next
;
3098 TRACE("(%p %d)\n", this, c
);
3100 if(!basic_filebuf_char_is_open(this))
3106 return fwrite(&ch
, sizeof(char), 1, this->file
) ? c
: EOF
;
3110 ret
= codecvt_char_out(this->cvt
, &this->state
, from_next
, &ch
+1,
3111 &from_next
, buf
, buf
+sizeof(buf
), &to_next
);
3114 case CODECVT_partial
:
3119 if(!fwrite(buf
, to_next
-buf
, 1, this->file
))
3121 if(ret
== CODECVT_partial
)
3124 case CODECVT_noconv
:
3125 return fwrite(&ch
, sizeof(char), 1, this->file
) ? c
: EOF
;
3133 max_size
= codecvt_base_max_length(&this->cvt
->base
);
3134 dyn_buf
= malloc(max_size
);
3138 ret
= codecvt_char_out(this->cvt
, &this->state
, from_next
, &ch
+1,
3139 &from_next
, dyn_buf
, dyn_buf
+max_size
, &to_next
);
3143 ret
= fwrite(dyn_buf
, to_next
-dyn_buf
, 1, this->file
);
3145 return ret
? c
: EOF
;
3146 case CODECVT_partial
:
3147 ERR("buffer should be big enough to store all output\n");
3155 /* ?pbackfail@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
3156 /* ?pbackfail@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
3157 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_pbackfail
, 8)
3158 int __thiscall
basic_filebuf_char_pbackfail(basic_filebuf_char
*this, int c
)
3160 TRACE("(%p %d)\n", this, c
);
3162 if(!basic_filebuf_char_is_open(this))
3165 if(basic_streambuf_char_gptr(&this->base
)>basic_streambuf_char_eback(&this->base
)
3166 && (c
==EOF
|| (int)(unsigned char)basic_streambuf_char_gptr(&this->base
)[-1]==c
)) {
3167 basic_streambuf_char__Gndec(&this->base
);
3168 return c
==EOF
? !c
: c
;
3169 }else if(c
!=EOF
&& !this->cvt
) {
3170 return ungetc(c
, this->file
);
3176 /* ?uflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
3177 /* ?uflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
3178 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_uflow
, 4)
3179 int __thiscall
basic_filebuf_char_uflow(basic_filebuf_char
*this)
3181 char ch
, buf
[128], *to_next
;
3182 const char *buf_next
;
3186 TRACE("(%p)\n", this);
3188 if(!basic_filebuf_char_is_open(this))
3191 if(basic_streambuf_char_gptr(&this->base
) < basic_streambuf_char_egptr(&this->base
))
3192 return (unsigned char)*basic_streambuf_char__Gninc(&this->base
);
3194 c
= fgetc(this->file
);
3195 if(!this->cvt
|| c
==EOF
)
3199 for(i
=0; i
< sizeof(buf
)/sizeof(buf
[0]); i
++) {
3202 switch(codecvt_char_in(this->cvt
, &this->state
, buf_next
,
3203 buf
+i
+1, &buf_next
, &ch
, &ch
+1, &to_next
)) {
3204 case CODECVT_partial
:
3206 if(to_next
== &ch
) {
3207 c
= fgetc(this->file
);
3213 for(j
= --i
; j
>= buf_next
-buf
; j
--)
3214 ungetc(buf
[j
], this->file
);
3216 case CODECVT_noconv
:
3217 return (unsigned char)buf
[0];
3223 FIXME("buffer is too small\n");
3227 /* ?underflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
3228 /* ?underflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
3229 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_underflow
, 4)
3230 int __thiscall
basic_filebuf_char_underflow(basic_filebuf_char
*this)
3234 TRACE("(%p)\n", this);
3236 if(basic_streambuf_char_gptr(&this->base
) < basic_streambuf_char_egptr(&this->base
))
3237 return (unsigned char)*basic_streambuf_char_gptr(&this->base
);
3239 ret
= call_basic_streambuf_char_uflow(&this->base
);
3241 ret
= call_basic_streambuf_char_pbackfail(&this->base
, ret
);
3245 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
3246 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
3247 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3248 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3249 #if STREAMOFF_BITS == 64
3250 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekoff
, 24)
3252 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekoff
, 20)
3254 fpos_int
* __thiscall
basic_filebuf_char_seekoff(basic_filebuf_char
*this,
3255 fpos_int
*ret
, streamoff off
, int way
, int mode
)
3259 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
3261 if(!basic_filebuf_char_is_open(this) || !basic_filebuf_char__Endwrite(this)
3262 || fseek(this->file
, off
, way
)) {
3269 fgetpos(this->file
, &pos
);
3272 ret
->state
= this->state
;
3276 /* ?seekpos@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3277 /* ?seekpos@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3278 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekpos
, 36)
3279 fpos_int
* __thiscall
basic_filebuf_char_seekpos(basic_filebuf_char
*this,
3280 fpos_int
*ret
, fpos_int pos
, int mode
)
3284 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_int(&pos
), mode
);
3286 if(!basic_filebuf_char_is_open(this) || !basic_filebuf_char__Endwrite(this)
3287 || fseek(this->file
, (LONG
)pos
.pos
, SEEK_SET
)
3288 || (pos
.off
&& fseek(this->file
, pos
.off
, SEEK_CUR
))) {
3295 fgetpos(this->file
, &fpos
);
3298 ret
->state
= this->state
;
3302 /* ?setbuf@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PADH@Z */
3303 /* ?setbuf@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAD_J@Z */
3304 #if STREAMSIZE_BITS == 64
3305 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_setbuf
, 16)
3307 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_setbuf
, 12)
3309 basic_streambuf_char
* __thiscall
basic_filebuf_char_setbuf(basic_filebuf_char
*this, char *buf
, streamsize count
)
3311 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
3313 if(!basic_filebuf_char_is_open(this))
3316 if(setvbuf(this->file
, buf
, (buf
==NULL
&& count
==0) ? _IONBF
: _IOFBF
, count
))
3319 basic_filebuf_char__Init(this, this->file
, INITFL_open
);
3323 /* ?sync@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
3324 /* ?sync@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
3325 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_sync
, 4)
3326 int __thiscall
basic_filebuf_char_sync(basic_filebuf_char
*this)
3328 TRACE("(%p)\n", this);
3330 if(!basic_filebuf_char_is_open(this))
3333 if(call_basic_streambuf_char_overflow(&this->base
, EOF
) == EOF
)
3335 return fflush(this->file
);
3338 /* ?imbue@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z */
3339 /* ?imbue@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z */
3340 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_imbue
, 8)
3341 void __thiscall
basic_filebuf_char_imbue(basic_filebuf_char
*this, const locale
*loc
)
3343 TRACE("(%p %p)\n", this, loc
);
3344 basic_filebuf_char__Initcvt_cvt(this, codecvt_char_use_facet(loc
));
3347 /* ?_Stinit@?1??_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
3348 /* ?_Stinit@?1??_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
3349 int basic_filebuf_wchar__Init__Stinit
= 0;
3351 /* ?_Stinit@?1??_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
3352 /* ?_Stinit@?1??_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
3353 int basic_filebuf_short__Init__Stinit
= 0;
3355 /* ?_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
3356 /* ?_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
3357 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Init
, 12)
3358 void __thiscall
basic_filebuf_wchar__Init(basic_filebuf_wchar
*this, FILE *file
, basic_filebuf__Initfl which
)
3360 TRACE("(%p %p %d)\n", this, file
, which
);
3363 this->wrotesome
= FALSE
;
3364 this->state
= basic_filebuf_wchar__Init__Stinit
;
3365 this->close
= (which
== INITFL_open
);
3368 basic_streambuf_wchar__Init_empty(&this->base
);
3371 /* ?_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
3372 /* ?_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
3373 DEFINE_THISCALL_WRAPPER(basic_filebuf_short__Init
, 12)
3374 void __thiscall
basic_filebuf_short__Init(basic_filebuf_wchar
*this, FILE *file
, basic_filebuf__Initfl which
)
3376 TRACE("(%p %p %d)\n", this, file
, which
);
3379 this->wrotesome
= FALSE
;
3380 this->state
= basic_filebuf_short__Init__Stinit
;
3381 this->close
= (which
== INITFL_open
);
3384 basic_streambuf_wchar__Init_empty(&this->base
);
3387 /* ?_Initcvt@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$codecvt@_WDH@2@@Z */
3388 /* ?_Initcvt@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$codecvt@_WDH@2@@Z */
3389 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAV?$codecvt@GDH@2@@Z */
3390 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$codecvt@GDH@2@@Z */
3391 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Initcvt_cvt
, 8)
3392 void __thiscall
basic_filebuf_wchar__Initcvt_cvt(basic_filebuf_wchar
*this, codecvt_wchar
*cvt
)
3394 TRACE("(%p %p)\n", this, cvt
);
3396 if(codecvt_base_always_noconv(&cvt
->base
)) {
3399 basic_streambuf_wchar__Init_empty(&this->base
);
3404 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXXZ */
3405 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXXZ */
3406 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Initcvt
, 4)
3407 void __thiscall
basic_filebuf_wchar__Initcvt(basic_filebuf_wchar
*this)
3409 codecvt_wchar
*cvt
= codecvt_wchar_use_facet(IOS_LOCALE(&this->base
));
3410 basic_filebuf_wchar__Initcvt_cvt( this, cvt
);
3413 /* ?_Endwrite@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAE_NXZ */
3414 /* ?_Endwrite@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAA_NXZ */
3415 /* ?_Endwrite@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAE_NXZ */
3416 /* ?_Endwrite@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAA_NXZ */
3417 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Endwrite
, 4)
3418 MSVCP_bool __thiscall
basic_filebuf_wchar__Endwrite(basic_filebuf_wchar
*this)
3420 TRACE("(%p)\n", this);
3422 if(!this->wrotesome
|| !this->cvt
)
3425 if(call_basic_streambuf_wchar_overflow(&this->base
, WEOF
) == WEOF
)
3429 /* TODO: check if we need a dynamic buffer here */
3434 ret
= codecvt_wchar_unshift(this->cvt
, &this->state
, buf
, buf
+sizeof(buf
), &next
);
3437 this->wrotesome
= FALSE
;
3439 case CODECVT_partial
:
3440 if(!fwrite(buf
, next
-buf
, 1, this->file
))
3445 case CODECVT_noconv
:
3446 if(call_basic_streambuf_wchar_overflow(&this->base
, WEOF
) == WEOF
)
3455 /* ?close@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@XZ */
3456 /* ?close@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@XZ */
3457 /* ?close@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@XZ */
3458 /* ?close@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@XZ */
3459 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_close
, 4)
3460 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_close(basic_filebuf_wchar
*this)
3462 basic_filebuf_wchar
*ret
= this;
3464 TRACE("(%p)\n", this);
3469 /* TODO: handle exceptions */
3470 if(!basic_filebuf_wchar__Endwrite(this))
3472 if(fclose(this->file
))
3475 basic_filebuf_wchar__Init(this, NULL
, INITFL_close
);
3479 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
3480 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3481 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor_file
, 8)
3482 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_ctor_file(basic_filebuf_wchar
*this, FILE *file
)
3484 TRACE("(%p %p)\n", this, file
);
3486 basic_streambuf_wchar_ctor(&this->base
);
3487 this->base
.vtable
= &MSVCP_basic_filebuf_wchar_vtable
;
3489 basic_filebuf_wchar__Init(this, file
, INITFL_new
);
3493 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
3494 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3495 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor_file
, 8)
3496 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_ctor_file(basic_filebuf_wchar
*this, FILE *file
)
3498 TRACE("(%p %p)\n", this, file
);
3500 basic_streambuf_short_ctor(&this->base
);
3501 this->base
.vtable
= &MSVCP_basic_filebuf_short_vtable
;
3503 basic_filebuf_short__Init(this, file
, INITFL_new
);
3507 /* ??_F?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
3508 /* ??_F?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
3509 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor
, 4)
3510 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_ctor(basic_filebuf_wchar
*this)
3512 return basic_filebuf_wchar_ctor_file(this, NULL
);
3515 /* ??_F?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
3516 /* ??_F?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
3517 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor
, 4)
3518 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_ctor(basic_filebuf_wchar
*this)
3520 return basic_filebuf_short_ctor_file(this, NULL
);
3523 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3524 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3525 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor_uninitialized
, 8)
3526 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_ctor_uninitialized(basic_filebuf_wchar
*this, int uninitialized
)
3528 TRACE("(%p %d)\n", this, uninitialized
);
3530 basic_streambuf_wchar_ctor(&this->base
);
3531 this->base
.vtable
= &MSVCP_basic_filebuf_wchar_vtable
;
3535 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3536 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3537 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor_uninitialized
, 8)
3538 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_ctor_uninitialized(basic_filebuf_wchar
*this, int uninitialized
)
3540 TRACE("(%p %d)\n", this, uninitialized
);
3542 basic_streambuf_short_ctor(&this->base
);
3543 this->base
.vtable
= &MSVCP_basic_filebuf_short_vtable
;
3547 /* ??1?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
3548 /* ??1?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
3549 /* ??1?$basic_filebuf@GU?$char_traits@G@std@@@std@@UAE@XZ */
3550 /* ??1?$basic_filebuf@GU?$char_traits@G@std@@@std@@UEAA@XZ */
3551 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_dtor
, 4)
3552 void __thiscall
basic_filebuf_wchar_dtor(basic_filebuf_wchar
*this)
3554 TRACE("(%p)\n", this);
3557 basic_filebuf_wchar_close(this);
3558 basic_streambuf_wchar_dtor(&this->base
);
3561 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_vector_dtor
, 8)
3562 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_vector_dtor(basic_filebuf_wchar
*this, unsigned int flags
)
3564 TRACE("(%p %x)\n", this, flags
);
3566 /* we have an array, with the number of elements stored before the first object */
3567 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
3569 for(i
=*ptr
-1; i
>=0; i
--)
3570 basic_filebuf_wchar_dtor(this+i
);
3571 MSVCRT_operator_delete(ptr
);
3573 basic_filebuf_wchar_dtor(this);
3575 MSVCRT_operator_delete(this);
3581 /* ?is_open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
3582 /* ?is_open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
3583 /* ?is_open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QBE_NXZ */
3584 /* ?is_open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
3585 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_is_open
, 4)
3586 MSVCP_bool __thiscall
basic_filebuf_wchar_is_open(const basic_filebuf_wchar
*this)
3588 TRACE("(%p)\n", this);
3589 return this->file
!= NULL
;
3592 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PB_WHH@Z */
3593 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3594 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBGHH@Z */
3595 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3596 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_wchar
, 16)
3597 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_wchar(basic_filebuf_wchar
*this, const wchar_t *name
, int mode
, int prot
)
3601 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
3603 if(basic_filebuf_wchar_is_open(this))
3606 if(!(f
= _Fiopen_wchar(name
, mode
, prot
)))
3609 basic_filebuf_wchar__Init(this, f
, INITFL_open
);
3610 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_wchar_use_facet(IOS_LOCALE(&this->base
)));
3614 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PB_WHH@Z */
3615 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3616 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBGHH@Z */
3617 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3618 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_wchar
, 16)
3619 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open_wchar(basic_filebuf_wchar
*this, const wchar_t *name
, int mode
, int prot
)
3623 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
3625 if(basic_filebuf_wchar_is_open(this))
3628 if(!(f
= _Fiopen_wchar(name
, mode
, prot
)))
3631 basic_filebuf_short__Init(this, f
, INITFL_open
);
3632 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_short_use_facet(IOS_LOCALE(&this->base
)));
3636 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PB_WI@Z */
3637 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3638 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBGI@Z */
3639 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBGI@Z */
3640 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_wchar_mode
, 12)
3641 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_wchar_mode(basic_filebuf_wchar
*this, const wchar_t *name
, unsigned int mode
)
3643 return basic_filebuf_wchar_open_wchar(this, name
, mode
, SH_DENYNO
);
3646 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PB_WI@Z */
3647 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3648 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBGI@Z */
3649 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBGI@Z */
3650 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_wchar_mode
, 12)
3651 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open_wchar_mode(basic_filebuf_wchar
*this, const wchar_t *name
, unsigned int mode
)
3653 return basic_filebuf_short_open_wchar(this, name
, mode
, SH_DENYNO
);
3656 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBDHH@Z */
3657 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3658 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open
, 16)
3659 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open(basic_filebuf_wchar
*this, const char *name
, int mode
, int prot
)
3661 wchar_t nameW
[FILENAME_MAX
];
3663 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
3665 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3667 return basic_filebuf_wchar_open_wchar(this, nameW
, mode
, prot
);
3670 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDHH@Z */
3671 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3672 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open
, 16)
3673 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open(basic_filebuf_wchar
*this, const char *name
, int mode
, int prot
)
3675 wchar_t nameW
[FILENAME_MAX
];
3677 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
3679 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3681 return basic_filebuf_short_open_wchar(this, nameW
, mode
, prot
);
3684 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDF@Z */
3685 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDF@Z */
3686 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_mode_old
, 12)
3687 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_mode_old(basic_filebuf_wchar
*this, const char *name
, short mode
)
3689 TRACE("(%p %p %d)\n", this, name
, mode
);
3690 return basic_filebuf_wchar_open(this, name
, mode
, SH_DENYNO
);
3693 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDH@Z */
3694 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDH@Z */
3695 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBDI@Z */
3696 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBDI@Z */
3697 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_mode
, 12)
3698 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_mode(basic_filebuf_wchar
*this, const char *name
, unsigned int mode
)
3700 return basic_filebuf_wchar_open(this, name
, mode
, SH_DENYNO
);
3703 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDI@Z */
3704 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDI@Z */
3705 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_mode
, 12)
3706 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open_mode(basic_filebuf_wchar
*this, const char *name
, unsigned int mode
)
3708 return basic_filebuf_short_open(this, name
, mode
, SH_DENYNO
);
3711 /* ?overflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
3712 /* ?overflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
3713 /* ?overflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
3714 /* ?overflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
3715 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_overflow
, 8)
3716 unsigned short __thiscall
basic_filebuf_wchar_overflow(basic_filebuf_wchar
*this, unsigned short c
)
3718 char buf
[8], *dyn_buf
, *to_next
;
3720 const wchar_t *from_next
;
3725 TRACE("(%p %d)\n", this, c
);
3727 if(!basic_filebuf_wchar_is_open(this))
3733 return fwrite(&ch
, sizeof(wchar_t), 1, this->file
) ? c
: WEOF
;
3737 ret
= codecvt_wchar_out(this->cvt
, &this->state
, from_next
, &ch
+1,
3738 &from_next
, buf
, buf
+sizeof(buf
), &to_next
);
3741 case CODECVT_partial
:
3746 if(!fwrite(buf
, to_next
-buf
, 1, this->file
))
3748 if(ret
== CODECVT_partial
)
3751 case CODECVT_noconv
:
3752 return fwrite(&ch
, sizeof(wchar_t), 1, this->file
) ? c
: WEOF
;
3760 max_size
= codecvt_base_max_length(&this->cvt
->base
);
3761 dyn_buf
= malloc(max_size
);
3765 ret
= codecvt_wchar_out(this->cvt
, &this->state
, from_next
, &ch
+1,
3766 &from_next
, dyn_buf
, dyn_buf
+max_size
, &to_next
);
3770 ret
= fwrite(dyn_buf
, to_next
-dyn_buf
, 1, this->file
);
3772 return ret
? c
: WEOF
;
3773 case CODECVT_partial
:
3774 ERR("buffer should be big enough to store all output\n");
3782 /* ?pbackfail@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
3783 /* ?pbackfail@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
3784 /* ?pbackfail@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
3785 /* ?pbackfail@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
3786 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_pbackfail
, 8)
3787 unsigned short __thiscall
basic_filebuf_wchar_pbackfail(basic_filebuf_wchar
*this, unsigned short c
)
3789 TRACE("(%p %d)\n", this, c
);
3791 if(!basic_filebuf_wchar_is_open(this))
3794 if(basic_streambuf_wchar_gptr(&this->base
)>basic_streambuf_wchar_eback(&this->base
)
3795 && (c
==WEOF
|| basic_streambuf_wchar_gptr(&this->base
)[-1]==c
)) {
3796 basic_streambuf_wchar__Gndec(&this->base
);
3797 return c
==WEOF
? !c
: c
;
3798 }else if(c
!=WEOF
&& !this->cvt
) {
3799 return ungetwc(c
, this->file
);
3800 }else if(c
!=WEOF
&& basic_streambuf_wchar_gptr(&this->base
)!=&this->putback
) {
3802 basic_streambuf_wchar_setg(&this->base
, &this->putback
, &this->putback
, &this->putback
+1);
3809 /* ?uflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
3810 /* ?uflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
3811 /* ?uflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
3812 /* ?uflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
3813 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_uflow
, 4)
3814 unsigned short __thiscall
basic_filebuf_wchar_uflow(basic_filebuf_wchar
*this)
3816 wchar_t ch
, *to_next
;
3818 const char *buf_next
;
3822 TRACE("(%p)\n", this);
3824 if(!basic_filebuf_wchar_is_open(this))
3827 if(basic_streambuf_wchar_gptr(&this->base
) < basic_streambuf_wchar_egptr(&this->base
))
3828 return *basic_streambuf_wchar__Gninc(&this->base
);
3831 return fgetwc(this->file
);
3834 for(i
=0; i
< sizeof(buf
)/sizeof(buf
[0]); i
++) {
3835 if((c
= fgetc(this->file
)) == EOF
)
3839 switch(codecvt_wchar_in(this->cvt
, &this->state
, buf_next
,
3840 buf
+i
+1, &buf_next
, &ch
, &ch
+1, &to_next
)) {
3841 case CODECVT_partial
:
3846 for(j
= --i
; j
>= buf_next
-buf
; j
--)
3847 ungetc(buf
[j
], this->file
);
3849 case CODECVT_noconv
:
3850 if(i
+1 < sizeof(wchar_t))
3853 memcpy(&ch
, buf
, sizeof(wchar_t));
3860 FIXME("buffer is too small\n");
3864 /* ?underflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
3865 /* ?underflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
3866 /* ?underflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
3867 /* ?underflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
3868 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_underflow
, 4)
3869 unsigned short __thiscall
basic_filebuf_wchar_underflow(basic_filebuf_wchar
*this)
3873 TRACE("(%p)\n", this);
3875 if(basic_streambuf_wchar_gptr(&this->base
) < basic_streambuf_wchar_egptr(&this->base
))
3876 return *basic_streambuf_wchar_gptr(&this->base
);
3878 ret
= call_basic_streambuf_wchar_uflow(&this->base
);
3880 ret
= call_basic_streambuf_wchar_pbackfail(&this->base
, ret
);
3884 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
3885 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
3886 /* ?seekoff@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3887 /* ?seekoff@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3888 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3889 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3890 #if STREAMOFF_BITS == 64
3891 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekoff
, 24)
3893 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekoff
, 20)
3895 fpos_int
* __thiscall
basic_filebuf_wchar_seekoff(basic_filebuf_wchar
*this,
3896 fpos_int
*ret
, streamoff off
, int way
, int mode
)
3900 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
3902 if(basic_streambuf_wchar_gptr(&this->base
) == &this->putback
) {
3903 if(way
== SEEKDIR_cur
)
3904 off
-= sizeof(wchar_t);
3906 basic_streambuf_wchar_setg(&this->base
, &this->putback
, &this->putback
+1, &this->putback
+1);
3909 if(!basic_filebuf_wchar_is_open(this) || !basic_filebuf_wchar__Endwrite(this)
3910 || fseek(this->file
, off
, way
)) {
3917 fgetpos(this->file
, &pos
);
3920 ret
->state
= this->state
;
3924 /* ?seekpos@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3925 /* ?seekpos@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3926 /* ?seekpos@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3927 /* ?seekpos@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3928 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekpos
, 36)
3929 fpos_int
* __thiscall
basic_filebuf_wchar_seekpos(basic_filebuf_wchar
*this,
3930 fpos_int
*ret
, fpos_int pos
, int mode
)
3934 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_int(&pos
), mode
);
3936 if(!basic_filebuf_wchar_is_open(this) || !basic_filebuf_wchar__Endwrite(this)
3937 || fseek(this->file
, (LONG
)pos
.pos
, SEEK_SET
)
3938 || (pos
.off
&& fseek(this->file
, pos
.off
, SEEK_CUR
))) {
3945 if(basic_streambuf_wchar_gptr(&this->base
) == &this->putback
)
3946 basic_streambuf_wchar_setg(&this->base
, &this->putback
, &this->putback
+1, &this->putback
+1);
3948 fgetpos(this->file
, &fpos
);
3951 ret
->state
= this->state
;
3955 /* ?setbuf@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PA_WH@Z */
3956 /* ?setbuf@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEA_W_J@Z */
3957 #if STREAMSIZE_BITS == 64
3958 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_setbuf
, 16)
3960 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_setbuf
, 12)
3962 basic_streambuf_wchar
* __thiscall
basic_filebuf_wchar_setbuf(basic_filebuf_wchar
*this, wchar_t *buf
, streamsize count
)
3964 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
3966 if(!basic_filebuf_wchar_is_open(this))
3969 if(setvbuf(this->file
, (char*)buf
, (buf
==NULL
&& count
==0) ? _IONBF
: _IOFBF
, count
*sizeof(wchar_t)))
3972 basic_filebuf_wchar__Init(this, this->file
, INITFL_open
);
3976 /* ?setbuf@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAGH@Z */
3977 /* ?setbuf@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAG_J@Z */
3978 #if STREAMSIZE_BITS == 64
3979 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_setbuf
, 16)
3981 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_setbuf
, 12)
3983 basic_streambuf_wchar
* __thiscall
basic_filebuf_short_setbuf(basic_filebuf_wchar
*this, wchar_t *buf
, streamsize count
)
3985 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
3987 if(!basic_filebuf_wchar_is_open(this))
3990 if(setvbuf(this->file
, (char*)buf
, (buf
==NULL
&& count
==0) ? _IONBF
: _IOFBF
, count
*sizeof(wchar_t)))
3993 basic_filebuf_short__Init(this, this->file
, INITFL_open
);
3997 /* ?sync@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
3998 /* ?sync@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ */
3999 /* ?sync@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
4000 /* ?sync@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAHXZ */
4001 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_sync
, 4)
4002 int __thiscall
basic_filebuf_wchar_sync(basic_filebuf_wchar
*this)
4004 TRACE("(%p)\n", this);
4006 if(!basic_filebuf_wchar_is_open(this))
4009 if(call_basic_streambuf_wchar_overflow(&this->base
, WEOF
) == WEOF
)
4011 return fflush(this->file
);
4014 /* ?imbue@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z */
4015 /* ?imbue@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z */
4016 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_imbue
, 8)
4017 void __thiscall
basic_filebuf_wchar_imbue(basic_filebuf_wchar
*this, const locale
*loc
)
4019 TRACE("(%p %p)\n", this, loc
);
4020 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_wchar_use_facet(loc
));
4023 /* ?imbue@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z */
4024 /* ?imbue@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z */
4025 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_imbue
, 8)
4026 void __thiscall
basic_filebuf_short_imbue(basic_filebuf_wchar
*this, const locale
*loc
)
4028 TRACE("(%p %p)\n", this, loc
);
4029 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_short_use_facet(loc
));
4032 /* ?_Getstate@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AAEHH@Z */
4033 /* ?_Getstate@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEAAHH@Z */
4034 /* ?_Mode@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AAEHH@Z */
4035 /* ?_Mode@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEAAHH@Z */
4036 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Getstate
, 8)
4037 int __thiscall
basic_stringbuf_char__Getstate(basic_stringbuf_char
*this, IOSB_openmode mode
)
4041 if(!(mode
& OPENMODE_in
))
4042 state
|= STRINGBUF_no_read
;
4044 if(!(mode
& OPENMODE_out
))
4045 state
|= STRINGBUF_no_write
;
4047 if(mode
& OPENMODE_ate
)
4048 state
|= STRINGBUF_at_end
;
4050 if(mode
& OPENMODE_app
)
4051 state
|= STRINGBUF_append
;
4056 /* ?_Init@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEXPBDIH@Z */
4057 /* ?_Init@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IEAAXPEBD_KH@Z */
4058 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Init
, 16)
4059 void __thiscall
basic_stringbuf_char__Init(basic_stringbuf_char
*this, const char *str
, MSVCP_size_t count
, int state
)
4061 TRACE("(%p, %p, %ld, %d)\n", this, str
, count
, state
);
4063 basic_streambuf_char__Init_empty(&this->base
);
4065 this->state
= state
;
4066 this->seekhigh
= NULL
;
4069 char *buf
= MSVCRT_operator_new(count
);
4071 ERR("Out of memory\n");
4072 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4075 memcpy(buf
, str
, count
);
4076 this->seekhigh
= buf
+ count
;
4078 this->state
|= STRINGBUF_allocated
;
4080 if(!(state
& STRINGBUF_no_read
))
4081 basic_streambuf_char_setg(&this->base
, buf
, buf
, buf
+ count
);
4083 if(!(state
& STRINGBUF_no_write
)) {
4084 basic_streambuf_char_setp_next(&this->base
, buf
, (state
& STRINGBUF_at_end
) ? buf
+ count
: buf
, buf
+ count
);
4086 if(!basic_streambuf_char_gptr(&this->base
))
4087 basic_streambuf_char_setg(&this->base
, buf
, 0, buf
);
4092 /* ??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 */
4093 /* ??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 */
4094 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor_str
, 12)
4095 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_ctor_str(basic_stringbuf_char
*this,
4096 const basic_string_char
*str
, IOSB_openmode mode
)
4098 TRACE("(%p %p %d)\n", this, str
, mode
);
4100 basic_streambuf_char_ctor(&this->base
);
4101 this->base
.vtable
= &MSVCP_basic_stringbuf_char_vtable
;
4103 basic_stringbuf_char__Init(this, MSVCP_basic_string_char_c_str(str
),
4104 str
->size
, basic_stringbuf_char__Getstate(this, mode
));
4108 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
4109 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
4110 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor_mode
, 8)
4111 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_ctor_mode(
4112 basic_stringbuf_char
*this, IOSB_openmode mode
)
4114 TRACE("(%p %d)\n", this, mode
);
4116 basic_streambuf_char_ctor(&this->base
);
4117 this->base
.vtable
= &MSVCP_basic_stringbuf_char_vtable
;
4119 basic_stringbuf_char__Init(this, NULL
, 0, basic_stringbuf_char__Getstate(this, mode
));
4123 /* ??_F?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
4124 /* ??_F?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
4125 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor
, 4)
4126 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_ctor(basic_stringbuf_char
*this)
4128 return basic_stringbuf_char_ctor_mode(this, OPENMODE_in
|OPENMODE_out
);
4131 /* ?_Tidy@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEXXZ */
4132 /* ?_Tidy@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IEAAXXZ */
4133 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Tidy
, 4)
4134 void __thiscall
basic_stringbuf_char__Tidy(basic_stringbuf_char
*this)
4136 TRACE("(%p)\n", this);
4138 if(this->state
& STRINGBUF_allocated
) {
4139 MSVCRT_operator_delete(basic_streambuf_char_eback(&this->base
));
4140 this->seekhigh
= NULL
;
4141 this->state
&= ~STRINGBUF_allocated
;
4144 basic_streambuf_char__Init_empty(&this->base
);
4147 /* ??1?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
4148 /* ??1?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
4149 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_dtor
, 4)
4150 void __thiscall
basic_stringbuf_char_dtor(basic_stringbuf_char
*this)
4152 TRACE("(%p)\n", this);
4154 basic_stringbuf_char__Tidy(this);
4155 basic_streambuf_char_dtor(&this->base
);
4158 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_vector_dtor
, 8)
4159 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_vector_dtor(basic_stringbuf_char
*this, unsigned int flags
)
4161 TRACE("(%p %x)\n", this, flags
);
4164 /* we have an array, with the number of elements stored before the first object */
4165 INT_PTR i
, *ptr
= (INT_PTR
*) this - 1;
4167 for (i
= *ptr
- 1; i
>= 0; i
--)
4168 basic_stringbuf_char_dtor(this+i
);
4170 MSVCRT_operator_delete(ptr
);
4172 basic_stringbuf_char_dtor(this);
4175 MSVCRT_operator_delete(this);
4181 /* ?overflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHH@Z */
4182 /* ?overflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z */
4183 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_overflow
, 8)
4184 int __thiscall
basic_stringbuf_char_overflow(basic_stringbuf_char
*this, int meta
)
4186 MSVCP_size_t oldsize
, size
;
4189 TRACE("(%p %x)\n", this, meta
);
4193 if(this->state
& STRINGBUF_no_write
)
4196 ptr
= basic_streambuf_char_pptr(&this->base
);
4197 if((this->state
&STRINGBUF_append
) && ptr
<this->seekhigh
)
4198 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
),
4199 this->seekhigh
, basic_streambuf_char_epptr(&this->base
));
4201 if(ptr
&& ptr
<basic_streambuf_char_epptr(&this->base
))
4202 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = meta
);
4204 oldsize
= (ptr
? basic_streambuf_char_epptr(&this->base
)-basic_streambuf_char_eback(&this->base
): 0);
4207 buf
= MSVCRT_operator_new(size
);
4209 ERR("Out of memory\n");
4210 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4214 this->seekhigh
= buf
;
4215 basic_streambuf_char_setp(&this->base
, buf
, buf
+size
);
4216 if(this->state
& STRINGBUF_no_read
)
4217 basic_streambuf_char_setg(&this->base
, buf
, NULL
, buf
);
4219 basic_streambuf_char_setg(&this->base
, buf
, buf
, buf
+1);
4221 this->state
|= STRINGBUF_allocated
;
4223 ptr
= basic_streambuf_char_eback(&this->base
);
4224 memcpy(buf
, ptr
, oldsize
);
4226 this->seekhigh
= buf
+(this->seekhigh
-ptr
);
4227 basic_streambuf_char_setp_next(&this->base
, buf
,
4228 buf
+(basic_streambuf_char_pptr(&this->base
)-ptr
), buf
+size
);
4229 if(this->state
& STRINGBUF_no_read
)
4230 basic_streambuf_char_setg(&this->base
, buf
, NULL
, buf
);
4232 basic_streambuf_char_setg(&this->base
, buf
,
4233 buf
+(basic_streambuf_char_gptr(&this->base
)-ptr
),
4234 basic_streambuf_char_pptr(&this->base
)+1);
4236 MSVCRT_operator_delete(ptr
);
4239 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = meta
);
4242 /* ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHH@Z */
4243 /* ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z */
4244 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_pbackfail
, 8)
4245 int __thiscall
basic_stringbuf_char_pbackfail(basic_stringbuf_char
*this, int c
)
4249 TRACE("(%p %x)\n", this, c
);
4251 cur
= basic_streambuf_char_gptr(&this->base
);
4252 if(!cur
|| cur
==basic_streambuf_char_eback(&this->base
)
4253 || (c
!=EOF
&& c
!=cur
[-1] && this->state
&STRINGBUF_no_write
))
4258 basic_streambuf_char_gbump(&this->base
, -1);
4259 return c
==EOF
? !EOF
: c
;
4262 /* ?underflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHXZ */
4263 /* ?underflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHXZ */
4264 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_underflow
, 4)
4265 int __thiscall
basic_stringbuf_char_underflow(basic_stringbuf_char
*this)
4269 TRACE("(%p)\n", this);
4271 cur
= basic_streambuf_char_gptr(&this->base
);
4272 if(!cur
|| this->state
&STRINGBUF_no_read
)
4275 ptr
= basic_streambuf_char_pptr(&this->base
);
4276 if(this->seekhigh
< ptr
)
4277 this->seekhigh
= ptr
;
4279 ptr
= basic_streambuf_char_egptr(&this->base
);
4280 if(this->seekhigh
> ptr
)
4281 basic_streambuf_char_setg(&this->base
, basic_streambuf_char_eback(&this->base
), cur
, this->seekhigh
);
4283 if(cur
< this->seekhigh
)
4284 return (unsigned char)*cur
;
4288 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
4289 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
4290 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4291 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4292 #if STREAMOFF_BITS == 64
4293 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekoff
, 24)
4295 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekoff
, 20)
4297 fpos_int
* __thiscall
basic_stringbuf_char_seekoff(basic_stringbuf_char
*this,
4298 fpos_int
*ret
, streamoff off
, int way
, int mode
)
4300 char *beg
, *cur_r
, *cur_w
;
4302 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
4304 cur_w
= basic_streambuf_char_pptr(&this->base
);
4305 if(cur_w
> this->seekhigh
)
4306 this->seekhigh
= cur_w
;
4312 beg
= basic_streambuf_char_eback(&this->base
);
4313 cur_r
= basic_streambuf_char_gptr(&this->base
);
4314 if((mode
& OPENMODE_in
) && cur_r
) {
4315 if(way
==SEEKDIR_cur
&& !(mode
& OPENMODE_out
))
4317 else if(way
== SEEKDIR_end
)
4318 off
+= this->seekhigh
-beg
;
4319 else if(way
!= SEEKDIR_beg
)
4322 if(off
<0 || off
>this->seekhigh
-beg
) {
4325 basic_streambuf_char_gbump(&this->base
, beg
-cur_r
+off
);
4326 if((mode
& OPENMODE_out
) && cur_w
) {
4327 basic_streambuf_char_setp_next(&this->base
, beg
,
4328 basic_streambuf_char_gptr(&this->base
),
4329 basic_streambuf_char_epptr(&this->base
));
4332 }else if((mode
& OPENMODE_out
) && cur_w
) {
4333 if(way
== SEEKDIR_cur
)
4335 else if(way
== SEEKDIR_end
)
4336 off
+= this->seekhigh
-beg
;
4337 else if(way
!= SEEKDIR_beg
)
4340 if(off
<0 || off
>this->seekhigh
-beg
)
4343 basic_streambuf_char_pbump(&this->base
, beg
-cur_w
+off
);
4352 /* ?seekpos@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4353 /* ?seekpos@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4354 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekpos
, 36)
4355 fpos_int
* __thiscall
basic_stringbuf_char_seekpos(basic_stringbuf_char
*this,
4356 fpos_int
*ret
, fpos_int pos
, int mode
)
4358 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_int(&pos
), mode
);
4360 if(pos
.off
==-1 && pos
.pos
==0 && pos
.state
==0) {
4365 return basic_stringbuf_char_seekoff(this, ret
, pos
.pos
+pos
.off
, SEEKDIR_beg
, mode
);
4368 /* ?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 */
4369 /* ?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 */
4370 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_str_set
, 8)
4371 void __thiscall
basic_stringbuf_char_str_set(basic_stringbuf_char
*this, const basic_string_char
*str
)
4373 TRACE("(%p %p)\n", this, str
);
4375 basic_stringbuf_char__Tidy(this);
4376 basic_stringbuf_char__Init(this, MSVCP_basic_string_char_c_str(str
), str
->size
, this->state
);
4379 /* ?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 */
4380 /* ?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 */
4381 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_str_get
, 8)
4382 basic_string_char
* __thiscall
basic_stringbuf_char_str_get(const basic_stringbuf_char
*this, basic_string_char
*ret
)
4386 TRACE("(%p)\n", this);
4388 if(!(this->state
& STRINGBUF_no_write
) && basic_streambuf_char_pptr(&this->base
)) {
4391 ptr
= basic_streambuf_char_pbase(&this->base
);
4392 pptr
= basic_streambuf_char_pptr(&this->base
);
4394 return MSVCP_basic_string_char_ctor_cstr_len(ret
, ptr
, (this->seekhigh
< pptr
? pptr
: this->seekhigh
) - ptr
);
4397 if(!(this->state
& STRINGBUF_no_read
) && basic_streambuf_char_gptr(&this->base
)) {
4398 ptr
= basic_streambuf_char_eback(&this->base
);
4399 return MSVCP_basic_string_char_ctor_cstr_len(ret
, ptr
, basic_streambuf_char_egptr(&this->base
) - ptr
);
4402 return MSVCP_basic_string_char_ctor(ret
);
4405 /* ?_Getstate@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@AAEHH@Z */
4406 /* ?_Getstate@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@AEAAHH@Z */
4407 /* ?_Getstate@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AAEHH@Z */
4408 /* ?_Getstate@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AEAAHH@Z */
4409 /* ?_Mode@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AAEHH@Z */
4410 /* ?_Mode@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AEAAHH@Z */
4411 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Getstate
, 8)
4412 int __thiscall
basic_stringbuf_wchar__Getstate(basic_stringbuf_wchar
*this, IOSB_openmode mode
)
4416 if(!(mode
& OPENMODE_in
))
4417 state
|= STRINGBUF_no_read
;
4419 if(!(mode
& OPENMODE_out
))
4420 state
|= STRINGBUF_no_write
;
4422 if(mode
& OPENMODE_ate
)
4423 state
|= STRINGBUF_at_end
;
4425 if(mode
& OPENMODE_app
)
4426 state
|= STRINGBUF_append
;
4431 /* ?_Init@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEXPB_WIH@Z */
4432 /* ?_Init@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IEAAXPEB_W_KH@Z */
4433 /* ?_Init@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IAEXPBGIH@Z */
4434 /* ?_Init@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IEAAXPEBG_KH@Z */
4435 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Init
, 16)
4436 void __thiscall
basic_stringbuf_wchar__Init(basic_stringbuf_wchar
*this, const wchar_t *str
, MSVCP_size_t count
, int state
)
4438 TRACE("(%p, %p, %lu, %d)\n", this, str
, count
, state
);
4440 basic_streambuf_wchar__Init_empty(&this->base
);
4442 this->state
= state
;
4443 this->seekhigh
= NULL
;
4446 wchar_t *buf
= MSVCRT_operator_new(count
*sizeof(wchar_t));
4448 ERR("Out of memory\n");
4449 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4452 memcpy(buf
, str
, count
*sizeof(wchar_t));
4453 this->seekhigh
= buf
+ count
;
4455 this->state
|= STRINGBUF_allocated
;
4457 if(!(state
& STRINGBUF_no_read
))
4458 basic_streambuf_wchar_setg(&this->base
, buf
, buf
, buf
+ count
);
4460 if(!(state
& STRINGBUF_no_write
)) {
4461 basic_streambuf_wchar_setp_next(&this->base
, buf
, (state
& STRINGBUF_at_end
) ? buf
+ count
: buf
, buf
+ count
);
4463 if(!basic_streambuf_wchar_gptr(&this->base
))
4464 basic_streambuf_wchar_setg(&this->base
, buf
, 0, buf
);
4469 /* ??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 */
4470 /* ??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 */
4471 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor_str
, 12)
4472 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_ctor_str(basic_stringbuf_wchar
*this,
4473 const basic_string_wchar
*str
, IOSB_openmode mode
)
4475 TRACE("(%p %p %d)\n", this, str
, mode
);
4477 basic_streambuf_wchar_ctor(&this->base
);
4478 this->base
.vtable
= &MSVCP_basic_stringbuf_wchar_vtable
;
4480 basic_stringbuf_wchar__Init(this, MSVCP_basic_string_wchar_c_str(str
),
4481 str
->size
, basic_stringbuf_wchar__Getstate(this, mode
));
4485 /* ??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 */
4486 /* ??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 */
4487 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor_str
, 12)
4488 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_short_ctor_str(basic_stringbuf_wchar
*this,
4489 const basic_string_wchar
*str
, IOSB_openmode mode
)
4491 basic_stringbuf_wchar_ctor_str(this, str
, mode
);
4492 this->base
.vtable
= &MSVCP_basic_stringbuf_short_vtable
;
4496 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
4497 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
4498 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor_mode
, 8)
4499 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_ctor_mode(
4500 basic_stringbuf_wchar
*this, IOSB_openmode mode
)
4502 TRACE("(%p %d)\n", this, mode
);
4504 basic_streambuf_wchar_ctor(&this->base
);
4505 this->base
.vtable
= &MSVCP_basic_stringbuf_wchar_vtable
;
4507 basic_stringbuf_wchar__Init(this, NULL
, 0, basic_stringbuf_wchar__Getstate(this, mode
));
4511 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
4512 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
4513 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor_mode
, 8)
4514 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_short_ctor_mode(
4515 basic_stringbuf_wchar
*this, IOSB_openmode mode
)
4517 basic_stringbuf_wchar_ctor_mode(this, mode
);
4518 this->base
.vtable
= &MSVCP_basic_stringbuf_short_vtable
;
4522 /* ??_F?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
4523 /* ??_F?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
4524 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor
, 4)
4525 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_ctor(basic_stringbuf_wchar
*this)
4527 return basic_stringbuf_wchar_ctor_mode(this, OPENMODE_in
|OPENMODE_out
);
4530 /* ??_F?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
4531 /* ??_F?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
4532 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor
, 4)
4533 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_short_ctor(basic_stringbuf_wchar
*this)
4535 return basic_stringbuf_short_ctor_mode(this, OPENMODE_in
|OPENMODE_out
);
4538 /* ?_Tidy@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEXXZ */
4539 /* ?_Tidy@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IEAAXXZ */
4540 /* ?_Tidy@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IAEXXZ */
4541 /* ?_Tidy@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IEAAXXZ */
4542 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Tidy
, 4)
4543 void __thiscall
basic_stringbuf_wchar__Tidy(basic_stringbuf_wchar
*this)
4545 TRACE("(%p)\n", this);
4547 if(this->state
& STRINGBUF_allocated
) {
4548 MSVCRT_operator_delete(basic_streambuf_wchar_eback(&this->base
));
4549 this->seekhigh
= NULL
;
4550 this->state
&= ~STRINGBUF_allocated
;
4553 basic_streambuf_wchar__Init_empty(&this->base
);
4556 /* ??1?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
4557 /* ??1?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
4558 /* ??1?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
4559 /* ??1?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
4560 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_dtor
, 4)
4561 void __thiscall
basic_stringbuf_wchar_dtor(basic_stringbuf_wchar
*this)
4563 TRACE("(%p)\n", this);
4565 basic_stringbuf_wchar__Tidy(this);
4566 basic_streambuf_wchar_dtor(&this->base
);
4569 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_vector_dtor
, 8)
4570 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_vector_dtor(basic_stringbuf_wchar
*this, unsigned int flags
)
4572 TRACE("(%p %x)\n", this, flags
);
4575 /* we have an array, with the number of elements stored before the first object */
4576 INT_PTR i
, *ptr
= (INT_PTR
*) this - 1;
4578 for (i
= *ptr
- 1; i
>= 0; i
--)
4579 basic_stringbuf_wchar_dtor(this+i
);
4581 MSVCRT_operator_delete(ptr
);
4583 basic_stringbuf_wchar_dtor(this);
4586 MSVCRT_operator_delete(this);
4592 /* ?overflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGG@Z */
4593 /* ?overflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGG@Z */
4594 /* ?overflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGG@Z */
4595 /* ?overflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGG@Z */
4596 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_overflow
, 8)
4597 unsigned short __thiscall
basic_stringbuf_wchar_overflow(basic_stringbuf_wchar
*this, unsigned short meta
)
4599 MSVCP_size_t oldsize
, size
;
4602 TRACE("(%p %x)\n", this, meta
);
4606 if(this->state
& STRINGBUF_no_write
)
4609 ptr
= basic_streambuf_wchar_pptr(&this->base
);
4610 if((this->state
&STRINGBUF_append
) && ptr
<this->seekhigh
)
4611 basic_streambuf_wchar_setp_next(&this->base
, basic_streambuf_wchar_pbase(&this->base
),
4612 this->seekhigh
, basic_streambuf_wchar_epptr(&this->base
));
4614 if(ptr
&& ptr
<basic_streambuf_wchar_epptr(&this->base
))
4615 return (*basic_streambuf_wchar__Pninc(&this->base
) = meta
);
4617 oldsize
= (ptr
? basic_streambuf_wchar_epptr(&this->base
)-basic_streambuf_wchar_eback(&this->base
): 0);
4620 buf
= MSVCRT_operator_new(size
*sizeof(wchar_t));
4622 ERR("Out of memory\n");
4623 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4627 this->seekhigh
= buf
;
4628 basic_streambuf_wchar_setp(&this->base
, buf
, buf
+size
);
4629 if(this->state
& STRINGBUF_no_read
)
4630 basic_streambuf_wchar_setg(&this->base
, buf
, NULL
, buf
);
4632 basic_streambuf_wchar_setg(&this->base
, buf
, buf
, buf
+1);
4634 this->state
|= STRINGBUF_allocated
;
4636 ptr
= basic_streambuf_wchar_eback(&this->base
);
4637 memcpy(buf
, ptr
, oldsize
*sizeof(wchar_t));
4639 this->seekhigh
= buf
+(this->seekhigh
-ptr
);
4640 basic_streambuf_wchar_setp_next(&this->base
, buf
,
4641 buf
+(basic_streambuf_wchar_pptr(&this->base
)-ptr
), buf
+size
);
4642 if(this->state
& STRINGBUF_no_read
)
4643 basic_streambuf_wchar_setg(&this->base
, buf
, NULL
, buf
);
4645 basic_streambuf_wchar_setg(&this->base
, buf
,
4646 buf
+(basic_streambuf_wchar_gptr(&this->base
)-ptr
),
4647 basic_streambuf_wchar_pptr(&this->base
)+1);
4649 MSVCRT_operator_delete(ptr
);
4652 return (*basic_streambuf_wchar__Pninc(&this->base
) = meta
);
4655 /* ?pbackfail@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGG@Z */
4656 /* ?pbackfail@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGG@Z */
4657 /* ?pbackfail@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGG@Z */
4658 /* ?pbackfail@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGG@Z */
4659 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_pbackfail
, 8)
4660 unsigned short __thiscall
basic_stringbuf_wchar_pbackfail(basic_stringbuf_wchar
*this, unsigned short c
)
4664 TRACE("(%p %x)\n", this, c
);
4666 cur
= basic_streambuf_wchar_gptr(&this->base
);
4667 if(!cur
|| cur
==basic_streambuf_wchar_eback(&this->base
)
4668 || (c
!=WEOF
&& c
!=cur
[-1] && this->state
&STRINGBUF_no_write
))
4673 basic_streambuf_wchar_gbump(&this->base
, -1);
4674 return c
==WEOF
? !WEOF
: c
;
4677 /* ?underflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGXZ */
4678 /* ?underflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGXZ */
4679 /* ?underflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGXZ */
4680 /* ?underflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGXZ */
4681 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_underflow
, 4)
4682 unsigned short __thiscall
basic_stringbuf_wchar_underflow(basic_stringbuf_wchar
*this)
4686 TRACE("(%p)\n", this);
4688 cur
= basic_streambuf_wchar_gptr(&this->base
);
4689 if(!cur
|| this->state
&STRINGBUF_no_read
)
4692 ptr
= basic_streambuf_wchar_pptr(&this->base
);
4693 if(this->seekhigh
< ptr
)
4694 this->seekhigh
= ptr
;
4696 ptr
= basic_streambuf_wchar_egptr(&this->base
);
4697 if(this->seekhigh
> ptr
)
4698 basic_streambuf_wchar_setg(&this->base
, basic_streambuf_wchar_eback(&this->base
), cur
, this->seekhigh
);
4700 if(cur
< this->seekhigh
)
4705 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
4706 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
4707 /* ?seekoff@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4708 /* ?seekoff@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4709 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4710 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4711 #if STREAMOFF_BITS == 64
4712 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekoff
, 24)
4714 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekoff
, 20)
4716 fpos_int
* __thiscall
basic_stringbuf_wchar_seekoff(basic_stringbuf_wchar
*this,
4717 fpos_int
*ret
, streamoff off
, int way
, int mode
)
4719 wchar_t *beg
, *cur_r
, *cur_w
;
4721 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
4723 cur_w
= basic_streambuf_wchar_pptr(&this->base
);
4724 if(cur_w
> this->seekhigh
)
4725 this->seekhigh
= cur_w
;
4731 beg
= basic_streambuf_wchar_eback(&this->base
);
4732 cur_r
= basic_streambuf_wchar_gptr(&this->base
);
4733 if((mode
& OPENMODE_in
) && cur_r
) {
4734 if(way
==SEEKDIR_cur
&& !(mode
& OPENMODE_out
))
4736 else if(way
== SEEKDIR_end
)
4737 off
+= this->seekhigh
-beg
;
4738 else if(way
!= SEEKDIR_beg
)
4741 if(off
<0 || off
>this->seekhigh
-beg
) {
4744 basic_streambuf_wchar_gbump(&this->base
, beg
-cur_r
+off
);
4745 if((mode
& OPENMODE_out
) && cur_w
) {
4746 basic_streambuf_wchar_setp_next(&this->base
, beg
,
4747 basic_streambuf_wchar_gptr(&this->base
),
4748 basic_streambuf_wchar_epptr(&this->base
));
4751 }else if((mode
& OPENMODE_out
) && cur_w
) {
4752 if(way
== SEEKDIR_cur
)
4754 else if(way
== SEEKDIR_end
)
4755 off
+= this->seekhigh
-beg
;
4756 else if(way
!= SEEKDIR_beg
)
4759 if(off
<0 || off
>this->seekhigh
-beg
)
4762 basic_streambuf_wchar_pbump(&this->base
, beg
-cur_w
+off
);
4771 /* ?seekpos@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4772 /* ?seekpos@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4773 /* ?seekpos@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4774 /* ?seekpos@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4775 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekpos
, 36)
4776 fpos_int
* __thiscall
basic_stringbuf_wchar_seekpos(basic_stringbuf_wchar
*this,
4777 fpos_int
*ret
, fpos_int pos
, int mode
)
4779 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_int(&pos
), mode
);
4781 if(pos
.off
==-1 && pos
.pos
==0 && pos
.state
==0) {
4786 return basic_stringbuf_wchar_seekoff(this, ret
, pos
.pos
+pos
.off
, SEEKDIR_beg
, mode
);
4789 /* ?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 */
4790 /* ?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 */
4791 /* ?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 */
4792 /* ?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 */
4793 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_str_set
, 8)
4794 void __thiscall
basic_stringbuf_wchar_str_set(basic_stringbuf_wchar
*this, const basic_string_wchar
*str
)
4796 TRACE("(%p %p)\n", this, str
);
4798 basic_stringbuf_wchar__Tidy(this);
4799 basic_stringbuf_wchar__Init(this, MSVCP_basic_string_wchar_c_str(str
), str
->size
, this->state
);
4802 /* ?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 */
4803 /* ?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 */
4804 /* ?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 */
4805 /* ?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 */
4806 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_str_get
, 8)
4807 basic_string_wchar
* __thiscall
basic_stringbuf_wchar_str_get(const basic_stringbuf_wchar
*this, basic_string_wchar
*ret
)
4811 TRACE("(%p)\n", this);
4813 if(!(this->state
& STRINGBUF_no_write
) && basic_streambuf_wchar_pptr(&this->base
)) {
4816 ptr
= basic_streambuf_wchar_pbase(&this->base
);
4817 pptr
= basic_streambuf_wchar_pptr(&this->base
);
4819 return MSVCP_basic_string_wchar_ctor_cstr_len(ret
, ptr
, (this->seekhigh
< pptr
? pptr
: this->seekhigh
) - ptr
);
4822 if(!(this->state
& STRINGBUF_no_read
) && basic_streambuf_wchar_gptr(&this->base
)) {
4823 ptr
= basic_streambuf_wchar_eback(&this->base
);
4824 return MSVCP_basic_string_wchar_ctor_cstr_len(ret
, ptr
, basic_streambuf_wchar_egptr(&this->base
) - ptr
);
4827 return MSVCP_basic_string_wchar_ctor(ret
);
4830 /* ??0ios_base@std@@IAE@XZ */
4831 /* ??0ios_base@std@@IEAA@XZ */
4832 DEFINE_THISCALL_WRAPPER(ios_base_ctor
, 4)
4833 ios_base
* __thiscall
ios_base_ctor(ios_base
*this)
4835 TRACE("(%p)\n", this);
4836 this->vtable
= &MSVCP_ios_base_vtable
;
4840 /* ??0ios_base@std@@QAE@ABV01@@Z */
4841 /* ??0ios_base@std@@QEAA@AEBV01@@Z */
4842 DEFINE_THISCALL_WRAPPER(ios_base_copy_ctor
, 8)
4843 ios_base
* __thiscall
ios_base_copy_ctor(ios_base
*this, const ios_base
*copy
)
4845 TRACE("(%p %p)\n", this, copy
);
4847 this->vtable
= &MSVCP_ios_base_vtable
;
4851 /* ?_Callfns@ios_base@std@@AAEXW4event@12@@Z */
4852 /* ?_Callfns@ios_base@std@@AEAAXW4event@12@@Z */
4853 DEFINE_THISCALL_WRAPPER(ios_base_Callfns
, 8)
4854 void __thiscall
ios_base_Callfns(ios_base
*this, IOS_BASE_event event
)
4856 IOS_BASE_fnarray
*cur
;
4858 TRACE("(%p %x)\n", this, event
);
4860 for(cur
=this->calls
; cur
; cur
=cur
->next
)
4861 cur
->event_handler(event
, this, cur
->index
);
4864 /* ?_Tidy@ios_base@std@@AAAXXZ */
4865 /* ?_Tidy@ios_base@std@@AEAAXXZ */
4866 void __cdecl
ios_base_Tidy(ios_base
*this)
4868 IOS_BASE_iosarray
*arr_cur
, *arr_next
;
4869 IOS_BASE_fnarray
*event_cur
, *event_next
;
4871 TRACE("(%p)\n", this);
4873 ios_base_Callfns(this, EVENT_erase_event
);
4875 for(arr_cur
=this->arr
; arr_cur
; arr_cur
=arr_next
) {
4876 arr_next
= arr_cur
->next
;
4877 MSVCRT_operator_delete(arr_cur
);
4881 for(event_cur
=this->calls
; event_cur
; event_cur
=event_next
) {
4882 event_next
= event_cur
->next
;
4883 MSVCRT_operator_delete(event_cur
);
4888 /* ?_Ios_base_dtor@ios_base@std@@CAXPAV12@@Z */
4889 /* ?_Ios_base_dtor@ios_base@std@@CAXPEAV12@@Z */
4890 void __cdecl
ios_base_Ios_base_dtor(ios_base
*obj
)
4892 TRACE("(%p)\n", obj
);
4893 locale_dtor(IOS_LOCALE(obj
));
4894 #if _MSVCP_VER >= 70
4895 MSVCRT_operator_delete(obj
->loc
);
4900 /* ??1ios_base@std@@UAE@XZ */
4901 /* ??1ios_base@std@@UEAA@XZ */
4902 DEFINE_THISCALL_WRAPPER(ios_base_dtor
, 4)
4903 void __thiscall
ios_base_dtor(ios_base
*this)
4905 ios_base_Ios_base_dtor(this);
4908 DEFINE_THISCALL_WRAPPER(ios_base_vector_dtor
, 8)
4909 ios_base
* __thiscall
ios_base_vector_dtor(ios_base
*this, unsigned int flags
)
4911 TRACE("(%p %x)\n", this, flags
);
4913 /* we have an array, with the number of elements stored before the first object */
4914 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
4916 for(i
=*ptr
-1; i
>=0; i
--)
4917 ios_base_dtor(this+i
);
4918 MSVCRT_operator_delete(ptr
);
4920 ios_base_dtor(this);
4922 MSVCRT_operator_delete(this);
4928 DEFINE_THISCALL_WRAPPER(iosb_vector_dtor
, 8)
4929 void* __thiscall
iosb_vector_dtor(void *this, unsigned int flags
)
4931 TRACE("(%p %x)\n", this, flags
);
4933 INT_PTR
*ptr
= (INT_PTR
*)this-1;
4934 MSVCRT_operator_delete(ptr
);
4937 MSVCRT_operator_delete(this);
4943 /* ?_Findarr@ios_base@std@@AAEAAU_Iosarray@12@H@Z */
4944 /* ?_Findarr@ios_base@std@@AEAAAEAU_Iosarray@12@H@Z */
4945 DEFINE_THISCALL_WRAPPER(ios_base_Findarr
, 8)
4946 IOS_BASE_iosarray
* __thiscall
ios_base_Findarr(ios_base
*this, int index
)
4948 IOS_BASE_iosarray
*p
;
4950 TRACE("(%p %d)\n", this, index
);
4952 for(p
=this->arr
; p
; p
=p
->next
) {
4953 if(p
->index
== index
)
4957 for(p
=this->arr
; p
; p
=p
->next
) {
4958 if(!p
->long_val
&& !p
->ptr_val
) {
4964 p
= MSVCRT_operator_new(sizeof(IOS_BASE_iosarray
));
4965 p
->next
= this->arr
;
4973 /* ?iword@ios_base@std@@QAEAAJH@Z */
4974 /* ?iword@ios_base@std@@QEAAAEAJH@Z */
4975 DEFINE_THISCALL_WRAPPER(ios_base_iword
, 8)
4976 LONG
* __thiscall
ios_base_iword(ios_base
*this, int index
)
4978 TRACE("(%p %d)\n", this, index
);
4979 return &ios_base_Findarr(this, index
)->long_val
;
4982 /* ?pword@ios_base@std@@QAEAAPAXH@Z */
4983 /* ?pword@ios_base@std@@QEAAAEAPEAXH@Z */
4984 DEFINE_THISCALL_WRAPPER(ios_base_pword
, 8)
4985 void** __thiscall
ios_base_pword(ios_base
*this, int index
)
4987 TRACE("(%p %d)\n", this, index
);
4988 return &ios_base_Findarr(this, index
)->ptr_val
;
4991 /* ?register_callback@ios_base@std@@QAEXP6AXW4event@12@AAV12@H@ZH@Z */
4992 /* ?register_callback@ios_base@std@@QEAAXP6AXW4event@12@AEAV12@H@ZH@Z */
4993 DEFINE_THISCALL_WRAPPER(ios_base_register_callback
, 12)
4994 void __thiscall
ios_base_register_callback(ios_base
*this, IOS_BASE_event_callback callback
, int index
)
4996 IOS_BASE_fnarray
*event
;
4998 TRACE("(%p %p %d)\n", this, callback
, index
);
5000 event
= MSVCRT_operator_new(sizeof(IOS_BASE_fnarray
));
5001 event
->next
= this->calls
;
5002 event
->index
= index
;
5003 event
->event_handler
= callback
;
5004 this->calls
= event
;
5007 /* ?clear@ios_base@std@@QAEXH_N@Z */
5008 /* ?clear@ios_base@std@@QEAAXH_N@Z */
5009 DEFINE_THISCALL_WRAPPER(ios_base_clear_reraise
, 12)
5010 void __thiscall
ios_base_clear_reraise(ios_base
*this, IOSB_iostate state
, MSVCP_bool reraise
)
5012 TRACE("(%p %x %x)\n", this, state
, reraise
);
5014 this->state
= state
& IOSTATE_mask
;
5015 if(!(this->state
& this->except
))
5019 throw_exception(EXCEPTION_RERAISE
, NULL
);
5020 else if(this->state
& this->except
& IOSTATE_eofbit
)
5021 throw_exception(EXCEPTION_FAILURE
, "eofbit is set");
5022 else if(this->state
& this->except
& IOSTATE_failbit
)
5023 throw_exception(EXCEPTION_FAILURE
, "failbit is set");
5024 else if(this->state
& this->except
& IOSTATE_badbit
)
5025 throw_exception(EXCEPTION_FAILURE
, "badbit is set");
5026 else if(this->state
& this->except
& IOSTATE__Hardfail
)
5027 throw_exception(EXCEPTION_FAILURE
, "_Hardfail is set");
5030 /* ?clear@ios_base@std@@QAEXH@Z */
5031 /* ?clear@ios_base@std@@QEAAXH@Z */
5032 DEFINE_THISCALL_WRAPPER(ios_base_clear
, 8)
5033 void __thiscall
ios_base_clear(ios_base
*this, IOSB_iostate state
)
5035 ios_base_clear_reraise(this, state
, FALSE
);
5038 /* ?clear@ios_base@std@@QAEXI@Z */
5039 /* ?clear@ios_base@std@@QEAAXI@Z */
5040 DEFINE_THISCALL_WRAPPER(ios_base_clear_unsigned
, 8)
5041 void __thiscall
ios_base_clear_unsigned(ios_base
*this, unsigned int state
)
5043 ios_base_clear_reraise(this, (IOSB_iostate
)state
, FALSE
);
5046 /* ?exceptions@ios_base@std@@QAEXH@Z */
5047 /* ?exceptions@ios_base@std@@QEAAXH@Z */
5048 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_set
, 8)
5049 void __thiscall
ios_base_exceptions_set(ios_base
*this, IOSB_iostate state
)
5051 TRACE("(%p %x)\n", this, state
);
5052 this->except
= state
& IOSTATE_mask
;
5053 ios_base_clear(this, this->state
);
5056 /* ?exceptions@ios_base@std@@QAEXI@Z */
5057 /* ?exceptions@ios_base@std@@QEAAXI@Z */
5058 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_set_unsigned
, 8)
5059 void __thiscall
ios_base_exceptions_set_unsigned(ios_base
*this, unsigned int state
)
5061 TRACE("(%p %x)\n", this, state
);
5062 ios_base_exceptions_set(this, state
);
5065 /* ?exceptions@ios_base@std@@QBEHXZ */
5066 /* ?exceptions@ios_base@std@@QEBAHXZ */
5067 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_get
, 4)
5068 IOSB_iostate __thiscall
ios_base_exceptions_get(ios_base
*this)
5070 TRACE("(%p)\n", this);
5071 return this->except
;
5074 /* ?copyfmt@ios_base@std@@QAEAAV12@ABV12@@Z */
5075 /* ?copyfmt@ios_base@std@@QEAAAEAV12@AEBV12@@Z */
5076 DEFINE_THISCALL_WRAPPER(ios_base_copyfmt
, 8)
5077 ios_base
* __thiscall
ios_base_copyfmt(ios_base
*this, const ios_base
*rhs
)
5079 TRACE("(%p %p)\n", this, rhs
);
5082 IOS_BASE_iosarray
*arr_cur
;
5083 IOS_BASE_fnarray
*event_cur
;
5085 ios_base_Tidy(this);
5087 for(arr_cur
=rhs
->arr
; arr_cur
; arr_cur
=arr_cur
->next
) {
5088 if(arr_cur
->long_val
)
5089 *ios_base_iword(this, arr_cur
->index
) = arr_cur
->long_val
;
5090 if(arr_cur
->ptr_val
)
5091 *ios_base_pword(this, arr_cur
->index
) = arr_cur
->ptr_val
;
5093 this->stdstr
= rhs
->stdstr
;
5094 this->fmtfl
= rhs
->fmtfl
;
5095 this->prec
= rhs
->prec
;
5096 this->wide
= rhs
->wide
;
5097 locale_operator_assign(IOS_LOCALE(this), IOS_LOCALE(rhs
));
5099 for(event_cur
=rhs
->calls
; event_cur
; event_cur
=event_cur
->next
)
5100 ios_base_register_callback(this, event_cur
->event_handler
, event_cur
->index
);
5102 ios_base_Callfns(this, EVENT_copyfmt_event
);
5103 ios_base_exceptions_set(this, rhs
->except
);
5109 /* ??4ios_base@std@@QAEAAV01@ABV01@@Z */
5110 /* ??4ios_base@std@@QEAAAEAV01@AEBV01@@Z */
5111 DEFINE_THISCALL_WRAPPER(ios_base_assign
, 8)
5112 ios_base
* __thiscall
ios_base_assign(ios_base
*this, const ios_base
*right
)
5114 TRACE("(%p %p)\n", this, right
);
5117 this->state
= right
->state
;
5118 ios_base_copyfmt(this, right
);
5124 /* ?fail@ios_base@std@@QBE_NXZ */
5125 /* ?fail@ios_base@std@@QEBA_NXZ */
5126 DEFINE_THISCALL_WRAPPER(ios_base_fail
, 4)
5127 MSVCP_bool __thiscall
ios_base_fail(const ios_base
*this)
5129 TRACE("(%p)\n", this);
5130 return (this->state
& (IOSTATE_failbit
|IOSTATE_badbit
)) != 0;
5133 /* ??7ios_base@std@@QBE_NXZ */
5134 /* ??7ios_base@std@@QEBA_NXZ */
5135 DEFINE_THISCALL_WRAPPER(ios_base_op_succ
, 4)
5136 MSVCP_bool __thiscall
ios_base_op_succ(const ios_base
*this)
5138 TRACE("(%p)\n", this);
5139 return ios_base_fail(this);
5142 /* ??Bios_base@std@@QBEPAXXZ */
5143 /* ??Bios_base@std@@QEBAPEAXXZ */
5144 DEFINE_THISCALL_WRAPPER(ios_base_op_fail
, 4)
5145 void* __thiscall
ios_base_op_fail(const ios_base
*this)
5147 TRACE("(%p)\n", this);
5148 return ios_base_fail(this) ? NULL
: (void*)this;
5151 /* ??Bios_base@std@@QBA_NXZ */
5152 /* ??Bios_base@std@@QBE_NXZ */
5153 /* ??Bios_base@std@@QEBA_NXZ */
5154 DEFINE_THISCALL_WRAPPER(ios_base_operator_bool
, 4)
5155 MSVCP_bool __thiscall
ios_base_operator_bool(const ios_base
*this)
5157 TRACE("(%p)\n", this);
5158 return (this->state
& (IOSTATE_failbit
|IOSTATE_badbit
)) == 0;
5161 /* ?_Addstd@ios_base@std@@SAXPAV12@@Z */
5162 /* ?_Addstd@ios_base@std@@SAXPEAV12@@Z */
5163 void __cdecl
ios_base_Addstd(ios_base
*add
)
5165 FIXME("(%p) stub\n", add
);
5168 /* ?_Index_func@ios_base@std@@CAAAHXZ */
5169 /* ?_Index_func@ios_base@std@@CAAEAHXZ */
5170 int* __cdecl
ios_base_Index_func(void)
5173 return &ios_base_Index
;
5176 /* ?_Init@ios_base@std@@IAEXXZ */
5177 /* ?_Init@ios_base@std@@IEAAXXZ */
5178 DEFINE_THISCALL_WRAPPER(ios_base__Init
, 4)
5179 void __thiscall
ios_base__Init(ios_base
*this)
5181 TRACE("(%p)\n", this);
5184 this->state
= this->except
= IOSTATE_goodbit
;
5185 this->fmtfl
= FMTFLAG_skipws
| FMTFLAG_dec
;
5190 #if _MSVCP_VER >= 70
5191 this->loc
= MSVCRT_operator_new(sizeof(locale
));
5193 locale_ctor(IOS_LOCALE(this));
5196 /* ?_Sync_func@ios_base@std@@CAAA_NXZ */
5197 /* ?_Sync_func@ios_base@std@@CAAEA_NXZ */
5198 MSVCP_bool
* __cdecl
ios_base_Sync_func(void)
5201 return &ios_base_Sync
;
5204 /* ?bad@ios_base@std@@QBE_NXZ */
5205 /* ?bad@ios_base@std@@QEBA_NXZ */
5206 DEFINE_THISCALL_WRAPPER(ios_base_bad
, 4)
5207 MSVCP_bool __thiscall
ios_base_bad(const ios_base
*this)
5209 TRACE("(%p)\n", this);
5210 return (this->state
& IOSTATE_badbit
) != 0;
5213 /* ?eof@ios_base@std@@QBE_NXZ */
5214 /* ?eof@ios_base@std@@QEBA_NXZ */
5215 DEFINE_THISCALL_WRAPPER(ios_base_eof
, 4)
5216 MSVCP_bool __thiscall
ios_base_eof(const ios_base
*this)
5218 TRACE("(%p)\n", this);
5219 return (this->state
& IOSTATE_eofbit
) != 0;
5222 /* ?flags@ios_base@std@@QAEHH@Z */
5223 /* ?flags@ios_base@std@@QEAAHH@Z */
5224 DEFINE_THISCALL_WRAPPER(ios_base_flags_set
, 8)
5225 IOSB_fmtflags __thiscall
ios_base_flags_set(ios_base
*this, IOSB_fmtflags flags
)
5227 IOSB_fmtflags ret
= this->fmtfl
;
5229 TRACE("(%p %x)\n", this, flags
);
5231 this->fmtfl
= flags
& FMTFLAG_mask
;
5235 /* ?flags@ios_base@std@@QBEHXZ */
5236 /* ?flags@ios_base@std@@QEBAHXZ */
5237 DEFINE_THISCALL_WRAPPER(ios_base_flags_get
, 4)
5238 IOSB_fmtflags __thiscall
ios_base_flags_get(const ios_base
*this)
5240 TRACE("(%p)\n", this);
5244 /* ?getloc@ios_base@std@@QBE?AVlocale@2@XZ */
5245 /* ?getloc@ios_base@std@@QEBA?AVlocale@2@XZ */
5246 DEFINE_THISCALL_WRAPPER(ios_base_getloc
, 8)
5247 locale
* __thiscall
ios_base_getloc(const ios_base
*this, locale
*ret
)
5249 TRACE("(%p)\n", this);
5250 return locale_copy_ctor(ret
, IOS_LOCALE(this));
5253 /* ?good@ios_base@std@@QBE_NXZ */
5254 /* ?good@ios_base@std@@QEBA_NXZ */
5255 DEFINE_THISCALL_WRAPPER(ios_base_good
, 4)
5256 MSVCP_bool __thiscall
ios_base_good(const ios_base
*this)
5258 TRACE("(%p)\n", this);
5259 return this->state
== IOSTATE_goodbit
;
5262 /* ?imbue@ios_base@std@@QAE?AVlocale@2@ABV32@@Z */
5263 /* ?imbue@ios_base@std@@QEAA?AVlocale@2@AEBV32@@Z */
5264 DEFINE_THISCALL_WRAPPER(ios_base_imbue
, 12)
5265 locale
* __thiscall
ios_base_imbue(ios_base
*this, locale
*ret
, const locale
*loc
)
5267 TRACE("(%p %p)\n", this, loc
);
5268 *ret
= *IOS_LOCALE(this);
5269 locale_copy_ctor(IOS_LOCALE(this), loc
);
5273 /* ?precision@ios_base@std@@QAEHH@Z */
5274 /* ?precision@ios_base@std@@QEAA_J_J@Z */
5275 #if STREAMSIZE_BITS == 64
5276 DEFINE_THISCALL_WRAPPER(ios_base_precision_set
, 12)
5278 DEFINE_THISCALL_WRAPPER(ios_base_precision_set
, 8)
5280 streamsize __thiscall
ios_base_precision_set(ios_base
*this, streamsize precision
)
5282 streamsize ret
= this->prec
;
5284 TRACE("(%p %s)\n", this, wine_dbgstr_longlong(precision
));
5286 this->prec
= precision
;
5290 /* ?precision@ios_base@std@@QBEHXZ */
5291 /* ?precision@ios_base@std@@QEBA_JXZ */
5292 DEFINE_THISCALL_WRAPPER(ios_base_precision_get
, 4)
5293 streamsize __thiscall
ios_base_precision_get(const ios_base
*this)
5295 TRACE("(%p)\n", this);
5299 /* ?rdstate@ios_base@std@@QBEHXZ */
5300 /* ?rdstate@ios_base@std@@QEBAHXZ */
5301 DEFINE_THISCALL_WRAPPER(ios_base_rdstate
, 4)
5302 IOSB_iostate __thiscall
ios_base_rdstate(const ios_base
*this)
5304 TRACE("(%p)\n", this);
5308 /* ?setf@ios_base@std@@QAEHHH@Z */
5309 /* ?setf@ios_base@std@@QEAAHHH@Z */
5310 DEFINE_THISCALL_WRAPPER(ios_base_setf_mask
, 12)
5311 IOSB_fmtflags __thiscall
ios_base_setf_mask(ios_base
*this, IOSB_fmtflags flags
, IOSB_fmtflags mask
)
5313 IOSB_fmtflags ret
= this->fmtfl
;
5315 TRACE("(%p %x %x)\n", this, flags
, mask
);
5317 this->fmtfl
= (this->fmtfl
& (~mask
)) | (flags
& mask
& FMTFLAG_mask
);
5321 /* ?setf@ios_base@std@@QAEHH@Z */
5322 /* ?setf@ios_base@std@@QEAAHH@Z */
5323 DEFINE_THISCALL_WRAPPER(ios_base_setf
, 8)
5324 IOSB_fmtflags __thiscall
ios_base_setf(ios_base
*this, IOSB_fmtflags flags
)
5326 IOSB_fmtflags ret
= this->fmtfl
;
5328 TRACE("(%p %x)\n", this, flags
);
5330 this->fmtfl
|= flags
& FMTFLAG_mask
;
5334 /* ?setstate@ios_base@std@@QAEXH_N@Z */
5335 /* ?setstate@ios_base@std@@QEAAXH_N@Z */
5336 DEFINE_THISCALL_WRAPPER(ios_base_setstate_reraise
, 12)
5337 void __thiscall
ios_base_setstate_reraise(ios_base
*this, IOSB_iostate state
, MSVCP_bool reraise
)
5339 TRACE("(%p %x %x)\n", this, state
, reraise
);
5341 if(state
!= IOSTATE_goodbit
)
5342 ios_base_clear_reraise(this, this->state
| state
, reraise
);
5345 /* ?setstate@ios_base@std@@QAEXH@Z */
5346 /* ?setstate@ios_base@std@@QEAAXH@Z */
5347 DEFINE_THISCALL_WRAPPER(ios_base_setstate
, 8)
5348 void __thiscall
ios_base_setstate(ios_base
*this, IOSB_iostate state
)
5350 ios_base_setstate_reraise(this, state
, FALSE
);
5353 /* ?setstate@ios_base@std@@QAEXI@Z */
5354 /* ?setstate@ios_base@std@@QEAAXI@Z */
5355 DEFINE_THISCALL_WRAPPER(ios_base_setstate_unsigned
, 8)
5356 void __thiscall
ios_base_setstate_unsigned(ios_base
*this, unsigned int state
)
5358 ios_base_setstate_reraise(this, (IOSB_iostate
)state
, FALSE
);
5361 /* ?sync_with_stdio@ios_base@std@@SA_N_N@Z */
5362 MSVCP_bool __cdecl
ios_base_sync_with_stdio(MSVCP_bool sync
)
5367 TRACE("(%x)\n", sync
);
5369 _Lockit_ctor_locktype(&lock
, _LOCK_STREAM
);
5370 ret
= ios_base_Sync
;
5371 ios_base_Sync
= sync
;
5372 _Lockit_dtor(&lock
);
5376 /* ?unsetf@ios_base@std@@QAEXH@Z */
5377 /* ?unsetf@ios_base@std@@QEAAXH@Z */
5378 DEFINE_THISCALL_WRAPPER(ios_base_unsetf
, 8)
5379 void __thiscall
ios_base_unsetf(ios_base
*this, IOSB_fmtflags flags
)
5381 TRACE("(%p %x)\n", this, flags
);
5382 this->fmtfl
&= ~flags
;
5385 /* ?width@ios_base@std@@QAEHH@Z */
5386 /* ?width@ios_base@std@@QEAA_J_J@Z */
5387 #if STREAMSIZE_BITS == 64
5388 DEFINE_THISCALL_WRAPPER(ios_base_width_set
, 12)
5390 DEFINE_THISCALL_WRAPPER(ios_base_width_set
, 8)
5392 streamsize __thiscall
ios_base_width_set(ios_base
*this, streamsize width
)
5394 streamsize ret
= this->wide
;
5396 TRACE("(%p %s)\n", this, wine_dbgstr_longlong(width
));
5402 /* ?width@ios_base@std@@QBEHXZ */
5403 /* ?width@ios_base@std@@QEBA_JXZ */
5404 DEFINE_THISCALL_WRAPPER(ios_base_width_get
, 4)
5405 streamsize __thiscall
ios_base_width_get(ios_base
*this)
5407 TRACE("(%p)\n", this);
5411 /* ?xalloc@ios_base@std@@SAHXZ */
5412 int __cdecl
ios_base_xalloc(void)
5419 _Lockit_ctor_locktype(&lock
, _LOCK_STREAM
);
5420 ret
= ios_base_Index
++;
5421 _Lockit_dtor(&lock
);
5425 /* ?swap@ios_base@std@@QAEXAAV12@@Z */
5426 /* ?swap@ios_base@std@@QEAAXAEAV12@@Z */
5427 DEFINE_THISCALL_WRAPPER(ios_base_swap
, 8)
5428 void __thiscall
ios_base_swap(ios_base
*this, ios_base
*r
)
5432 TRACE("(%p %p)\n", this, r
);
5439 this->vtable
= tmp
.vtable
;
5440 tmp
.vtable
= r
->vtable
;
5444 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IAE@XZ */
5445 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IEAA@XZ */
5446 DEFINE_THISCALL_WRAPPER(basic_ios_char_ctor
, 4)
5447 basic_ios_char
* __thiscall
basic_ios_char_ctor(basic_ios_char
*this)
5449 TRACE("(%p)\n", this);
5451 ios_base_ctor(&this->base
);
5452 this->base
.vtable
= &MSVCP_basic_ios_char_vtable
;
5456 /* ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IAEXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z */
5457 /* ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z */
5458 DEFINE_THISCALL_WRAPPER(basic_ios_char_init
, 12)
5459 void __thiscall
basic_ios_char_init(basic_ios_char
*this, basic_streambuf_char
*streambuf
, MSVCP_bool isstd
)
5461 TRACE("(%p %p %x)\n", this, streambuf
, isstd
);
5462 ios_base__Init(&this->base
);
5463 this->strbuf
= streambuf
;
5464 this->stream
= NULL
;
5468 ios_base_setstate(&this->base
, IOSTATE_badbit
);
5471 FIXME("standard streams not handled yet\n");
5474 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
5475 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
5476 DEFINE_THISCALL_WRAPPER(basic_ios_char_ctor_streambuf
, 8)
5477 basic_ios_char
* __thiscall
basic_ios_char_ctor_streambuf(basic_ios_char
*this, basic_streambuf_char
*strbuf
)
5479 TRACE("(%p %p)\n", this, strbuf
);
5481 basic_ios_char_ctor(this);
5482 basic_ios_char_init(this, strbuf
, FALSE
);
5486 /* ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UAE@XZ */
5487 /* ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UEAA@XZ */
5488 DEFINE_THISCALL_WRAPPER(basic_ios_char_dtor
, 4)
5489 void __thiscall
basic_ios_char_dtor(basic_ios_char
*this)
5491 TRACE("(%p)\n", this);
5492 ios_base_dtor(&this->base
);
5495 DEFINE_THISCALL_WRAPPER(basic_ios_char_vector_dtor
, 8)
5496 basic_ios_char
* __thiscall
basic_ios_char_vector_dtor(basic_ios_char
*this, unsigned int flags
)
5498 TRACE("(%p %x)\n", this, flags
);
5500 /* we have an array, with the number of elements stored before the first object */
5501 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
5503 for(i
=*ptr
-1; i
>=0; i
--)
5504 basic_ios_char_dtor(this+i
);
5505 MSVCRT_operator_delete(ptr
);
5507 basic_ios_char_dtor(this);
5509 MSVCRT_operator_delete(this);
5515 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z */
5516 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z */
5517 DEFINE_THISCALL_WRAPPER(basic_ios_char_clear_reraise
, 12)
5518 void __thiscall
basic_ios_char_clear_reraise(basic_ios_char
*this, IOSB_iostate state
, MSVCP_bool reraise
)
5520 TRACE("(%p %x %x)\n", this, state
, reraise
);
5521 ios_base_clear_reraise(&this->base
, state
| (this->strbuf
? IOSTATE_goodbit
: IOSTATE_badbit
), reraise
);
5524 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z */
5525 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z */
5526 DEFINE_THISCALL_WRAPPER(basic_ios_char_clear
, 8)
5527 void __thiscall
basic_ios_char_clear(basic_ios_char
*this, unsigned int state
)
5529 basic_ios_char_clear_reraise(this, (IOSB_iostate
)state
, FALSE
);
5532 /* ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEAAV12@ABV12@@Z */
5533 /* ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEBV12@@Z */
5534 DEFINE_THISCALL_WRAPPER(basic_ios_char_copyfmt
, 8)
5535 basic_ios_char
* __thiscall
basic_ios_char_copyfmt(basic_ios_char
*this, basic_ios_char
*copy
)
5537 TRACE("(%p %p)\n", this, copy
);
5541 this->stream
= copy
->stream
;
5542 this->fillch
= copy
->fillch
;
5543 ios_base_copyfmt(&this->base
, ©
->base
);
5547 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEDD@Z */
5548 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAADD@Z */
5549 DEFINE_THISCALL_WRAPPER(basic_ios_char_fill_set
, 8)
5550 char __thiscall
basic_ios_char_fill_set(basic_ios_char
*this, char fill
)
5552 char ret
= this->fillch
;
5554 TRACE("(%p %c)\n", this, fill
);
5556 this->fillch
= fill
;
5560 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDXZ */
5561 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADXZ */
5562 DEFINE_THISCALL_WRAPPER(basic_ios_char_fill_get
, 4)
5563 char __thiscall
basic_ios_char_fill_get(basic_ios_char
*this)
5565 TRACE("(%p)\n", this);
5566 return this->fillch
;
5569 /* ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5570 /* ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5571 DEFINE_THISCALL_WRAPPER(basic_ios_char_imbue
, 12)
5572 locale
*__thiscall
basic_ios_char_imbue(basic_ios_char
*this, locale
*ret
, const locale
*loc
)
5574 TRACE("(%p %p %p)\n", this, ret
, loc
);
5577 basic_streambuf_char_pubimbue(this->strbuf
, ret
, loc
);
5581 return ios_base_imbue(&this->base
, ret
, loc
);
5584 /* ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDDD@Z */
5585 /* ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADDD@Z */
5586 DEFINE_THISCALL_WRAPPER(basic_ios_char_narrow
, 12)
5587 char __thiscall
basic_ios_char_narrow(basic_ios_char
*this, char ch
, char def
)
5589 TRACE("(%p %c %c)\n", this, ch
, def
);
5590 return ctype_char_narrow_ch(ctype_char_use_facet(IOS_LOCALE(this->strbuf
)), ch
, def
);
5593 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PAV32@@Z */
5594 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAV32@@Z */
5595 DEFINE_THISCALL_WRAPPER(basic_ios_char_rdbuf_set
, 8)
5596 basic_streambuf_char
* __thiscall
basic_ios_char_rdbuf_set(basic_ios_char
*this, basic_streambuf_char
*streambuf
)
5598 basic_streambuf_char
*ret
= this->strbuf
;
5600 TRACE("(%p %p)\n", this, streambuf
);
5602 this->strbuf
= streambuf
;
5603 basic_ios_char_clear(this, IOSTATE_goodbit
);
5607 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ */
5608 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ */
5609 DEFINE_THISCALL_WRAPPER(basic_ios_char_rdbuf_get
, 4)
5610 basic_streambuf_char
* __thiscall
basic_ios_char_rdbuf_get(const basic_ios_char
*this)
5612 TRACE("(%p)\n", this);
5613 return this->strbuf
;
5616 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z */
5617 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z */
5618 DEFINE_THISCALL_WRAPPER(basic_ios_char_setstate_reraise
, 12)
5619 void __thiscall
basic_ios_char_setstate_reraise(basic_ios_char
*this, IOSB_iostate state
, MSVCP_bool reraise
)
5621 TRACE("(%p %x %x)\n", this, state
, reraise
);
5623 if(state
!= IOSTATE_goodbit
)
5624 basic_ios_char_clear_reraise(this, this->base
.state
| state
, reraise
);
5627 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z */
5628 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z */
5629 DEFINE_THISCALL_WRAPPER(basic_ios_char_setstate
, 8)
5630 void __thiscall
basic_ios_char_setstate(basic_ios_char
*this, unsigned int state
)
5632 basic_ios_char_setstate_reraise(this, (IOSB_iostate
)state
, FALSE
);
5635 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@PAV32@@Z */
5636 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@PEAV32@@Z */
5637 DEFINE_THISCALL_WRAPPER(basic_ios_char_tie_set
, 8)
5638 basic_ostream_char
* __thiscall
basic_ios_char_tie_set(basic_ios_char
*this, basic_ostream_char
*ostream
)
5640 basic_ostream_char
*ret
= this->stream
;
5642 TRACE("(%p %p)\n", this, ostream
);
5644 this->stream
= ostream
;
5648 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ */
5649 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ */
5650 DEFINE_THISCALL_WRAPPER(basic_ios_char_tie_get
, 4)
5651 basic_ostream_char
* __thiscall
basic_ios_char_tie_get(const basic_ios_char
*this)
5653 TRACE("(%p)\n", this);
5654 return this->stream
;
5657 /* ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDD@Z */
5658 /* ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADD@Z */
5659 DEFINE_THISCALL_WRAPPER(basic_ios_char_widen
, 8)
5660 char __thiscall
basic_ios_char_widen(basic_ios_char
*this, char ch
)
5662 TRACE("(%p %c)\n", this, ch
);
5663 return ctype_char_widen_ch(ctype_char_use_facet(IOS_LOCALE(this->strbuf
)), ch
);
5666 /* ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z */
5667 /* ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z */
5668 DEFINE_THISCALL_WRAPPER(basic_ios_char_swap
, 8)
5669 void __thiscall
basic_ios_char_swap(basic_ios_char
*this, basic_ios_char
*r
)
5673 TRACE("(%p %p)\n", this, r
);
5678 ios_base_swap(&this->base
, &r
->base
);
5679 swap_ptr
= this->stream
;
5680 this->stream
= r
->stream
;
5681 r
->stream
= swap_ptr
;
5682 this->fillch
^= r
->fillch
;
5683 r
->fillch
^= this->fillch
;
5684 this->fillch
^= r
->fillch
;
5687 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAE@XZ */
5688 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAA@XZ */
5689 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_ctor
, 4)
5690 basic_ios_wchar
* __thiscall
basic_ios_wchar_ctor(basic_ios_wchar
*this)
5692 TRACE("(%p)\n", this);
5694 ios_base_ctor(&this->base
);
5695 this->base
.vtable
= &MSVCP_basic_ios_wchar_vtable
;
5699 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IAE@XZ */
5700 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IEAA@XZ */
5701 DEFINE_THISCALL_WRAPPER(basic_ios_short_ctor
, 4)
5702 basic_ios_wchar
* __thiscall
basic_ios_short_ctor(basic_ios_wchar
*this)
5704 basic_ios_wchar_ctor(this);
5705 this->base
.vtable
= &MSVCP_basic_ios_short_vtable
;
5709 /* ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z */
5710 /* ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z */
5711 /* ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IAEXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z */
5712 /* ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z */
5713 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_init
, 12)
5714 void __thiscall
basic_ios_wchar_init(basic_ios_wchar
*this, basic_streambuf_wchar
*streambuf
, MSVCP_bool isstd
)
5716 TRACE("(%p %p %x)\n", this, streambuf
, isstd
);
5717 ios_base__Init(&this->base
);
5718 this->strbuf
= streambuf
;
5719 this->stream
= NULL
;
5723 ios_base_setstate(&this->base
, IOSTATE_badbit
);
5726 FIXME("standard streams not handled yet\n");
5729 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
5730 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
5731 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_ctor_streambuf
, 8)
5732 basic_ios_wchar
* __thiscall
basic_ios_wchar_ctor_streambuf(basic_ios_wchar
*this, basic_streambuf_wchar
*strbuf
)
5734 TRACE("(%p %p)\n", this, strbuf
);
5736 basic_ios_wchar_ctor(this);
5737 basic_ios_wchar_init(this, strbuf
, FALSE
);
5741 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
5742 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
5743 DEFINE_THISCALL_WRAPPER(basic_ios_short_ctor_streambuf
, 8)
5744 basic_ios_wchar
* __thiscall
basic_ios_short_ctor_streambuf(basic_ios_wchar
*this, basic_streambuf_wchar
*strbuf
)
5746 basic_ios_wchar_ctor_streambuf(this, strbuf
);
5747 this->base
.vtable
= &MSVCP_basic_ios_short_vtable
;
5751 /* ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
5752 /* ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
5753 /* ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UAE@XZ */
5754 /* ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UEAA@XZ */
5755 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_dtor
, 4)
5756 void __thiscall
basic_ios_wchar_dtor(basic_ios_wchar
*this)
5758 TRACE("(%p)\n", this);
5759 ios_base_dtor(&this->base
);
5762 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_vector_dtor
, 8)
5763 basic_ios_wchar
* __thiscall
basic_ios_wchar_vector_dtor(basic_ios_wchar
*this, unsigned int flags
)
5765 TRACE("(%p %x)\n", this, flags
);
5767 /* we have an array, with the number of elements stored before the first object */
5768 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
5770 for(i
=*ptr
-1; i
>=0; i
--)
5771 basic_ios_wchar_dtor(this+i
);
5772 MSVCRT_operator_delete(ptr
);
5774 basic_ios_wchar_dtor(this);
5776 MSVCRT_operator_delete(this);
5782 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z */
5783 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z */
5784 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z */
5785 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z */
5786 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_clear_reraise
, 12)
5787 void __thiscall
basic_ios_wchar_clear_reraise(basic_ios_wchar
*this, IOSB_iostate state
, MSVCP_bool reraise
)
5789 TRACE("(%p %x %x)\n", this, state
, reraise
);
5790 ios_base_clear_reraise(&this->base
, state
| (this->strbuf
? IOSTATE_goodbit
: IOSTATE_badbit
), reraise
);
5793 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z */
5794 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z */
5795 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z */
5796 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z */
5797 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_clear
, 8)
5798 void __thiscall
basic_ios_wchar_clear(basic_ios_wchar
*this, unsigned int state
)
5800 basic_ios_wchar_clear_reraise(this, (IOSB_iostate
)state
, FALSE
);
5803 /* ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEAAV12@ABV12@@Z */
5804 /* ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEBV12@@Z */
5805 /* ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEAAV12@ABV12@@Z */
5806 /* ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEBV12@@Z */
5807 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_copyfmt
, 8)
5808 basic_ios_wchar
* __thiscall
basic_ios_wchar_copyfmt(basic_ios_wchar
*this, basic_ios_wchar
*copy
)
5810 TRACE("(%p %p)\n", this, copy
);
5814 this->stream
= copy
->stream
;
5815 this->fillch
= copy
->fillch
;
5816 ios_base_copyfmt(&this->base
, ©
->base
);
5820 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE_W_W@Z */
5821 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA_W_W@Z */
5822 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEGG@Z */
5823 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAGG@Z */
5824 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_fill_set
, 8)
5825 wchar_t __thiscall
basic_ios_wchar_fill_set(basic_ios_wchar
*this, wchar_t fill
)
5827 wchar_t ret
= this->fillch
;
5829 TRACE("(%p %c)\n", this, fill
);
5831 this->fillch
= fill
;
5835 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WXZ */
5836 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WXZ */
5837 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGXZ */
5838 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGXZ */
5839 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_fill_get
, 4)
5840 wchar_t __thiscall
basic_ios_wchar_fill_get(basic_ios_wchar
*this)
5842 TRACE("(%p)\n", this);
5843 return this->fillch
;
5846 /* ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5847 /* ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5848 /* ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5849 /* ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5850 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_imbue
, 12)
5851 locale
*__thiscall
basic_ios_wchar_imbue(basic_ios_wchar
*this, locale
*ret
, const locale
*loc
)
5853 TRACE("(%p %p %p)\n", this, ret
, loc
);
5856 basic_streambuf_wchar_pubimbue(this->strbuf
, ret
, loc
);
5860 return ios_base_imbue(&this->base
, ret
, loc
);
5863 /* ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBED_WD@Z */
5864 /* ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAD_WD@Z */
5865 /* ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEDGD@Z */
5866 /* ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBADGD@Z */
5867 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_narrow
, 12)
5868 char __thiscall
basic_ios_wchar_narrow(basic_ios_wchar
*this, wchar_t ch
, char def
)
5870 TRACE("(%p %c %c)\n", this, ch
, def
);
5871 return ctype_wchar_narrow_ch(ctype_wchar_use_facet(IOS_LOCALE(this->strbuf
)), ch
, def
);
5874 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PAV32@@Z */
5875 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEAV32@@Z */
5876 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAV32@@Z */
5877 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAV32@@Z */
5878 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_rdbuf_set
, 8)
5879 basic_streambuf_wchar
* __thiscall
basic_ios_wchar_rdbuf_set(basic_ios_wchar
*this, basic_streambuf_wchar
*streambuf
)
5881 basic_streambuf_wchar
*ret
= this->strbuf
;
5883 TRACE("(%p %p)\n", this, streambuf
);
5885 this->strbuf
= streambuf
;
5886 basic_ios_wchar_clear(this, IOSTATE_goodbit
);
5890 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ */
5891 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ */
5892 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ */
5893 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ */
5894 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_rdbuf_get
, 4)
5895 basic_streambuf_wchar
* __thiscall
basic_ios_wchar_rdbuf_get(const basic_ios_wchar
*this)
5897 TRACE("(%p)\n", this);
5898 return this->strbuf
;
5901 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z */
5902 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z */
5903 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z */
5904 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z */
5905 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_setstate_reraise
, 12)
5906 void __thiscall
basic_ios_wchar_setstate_reraise(basic_ios_wchar
*this, IOSB_iostate state
, MSVCP_bool reraise
)
5908 TRACE("(%p %x %x)\n", this, state
, reraise
);
5910 if(state
!= IOSTATE_goodbit
)
5911 basic_ios_wchar_clear_reraise(this, this->base
.state
| state
, reraise
);
5914 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z */
5915 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z */
5916 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z */
5917 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z */
5918 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_setstate
, 8)
5919 void __thiscall
basic_ios_wchar_setstate(basic_ios_wchar
*this, IOSB_iostate state
)
5921 basic_ios_wchar_setstate_reraise(this, state
, FALSE
);
5924 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PAV32@@Z */
5925 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PEAV32@@Z */
5926 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@PAV32@@Z */
5927 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@PEAV32@@Z */
5928 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_tie_set
, 8)
5929 basic_ostream_wchar
* __thiscall
basic_ios_wchar_tie_set(basic_ios_wchar
*this, basic_ostream_wchar
*ostream
)
5931 basic_ostream_wchar
*ret
= this->stream
;
5933 TRACE("(%p %p)\n", this, ostream
);
5935 this->stream
= ostream
;
5939 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ */
5940 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ */
5941 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ */
5942 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ */
5943 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_tie_get
, 4)
5944 basic_ostream_wchar
* __thiscall
basic_ios_wchar_tie_get(const basic_ios_wchar
*this)
5946 TRACE("(%p)\n", this);
5947 return this->stream
;
5950 /* ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WD@Z */
5951 /* ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WD@Z */
5952 /* ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGD@Z */
5953 /* ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGD@Z */
5954 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_widen
, 8)
5955 wchar_t __thiscall
basic_ios_wchar_widen(basic_ios_wchar
*this, char ch
)
5957 TRACE("(%p %c)\n", this, ch
);
5958 return ctype_wchar_widen_ch(ctype_wchar_use_facet(IOS_LOCALE(this->strbuf
)), ch
);
5961 /* ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z */
5962 /* ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z */
5963 /* ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z */
5964 /* ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z */
5965 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_swap
, 8)
5966 void __thiscall
basic_ios_wchar_swap(basic_ios_wchar
*this, basic_ios_wchar
*r
)
5970 TRACE("(%p %p)\n", this, r
);
5975 ios_base_swap(&this->base
, &r
->base
);
5976 swap_ptr
= this->stream
;
5977 this->stream
= r
->stream
;
5978 r
->stream
= swap_ptr
;
5979 this->fillch
^= r
->fillch
;
5980 r
->fillch
^= this->fillch
;
5981 this->fillch
^= r
->fillch
;
5984 /* Caution: basic_ostream uses virtual inheritance.
5985 * All constructors have additional parameter that says if base class should be initialized.
5986 * Base class needs to be accessed using vbtable.
5988 static inline basic_ios_char
* basic_ostream_char_get_basic_ios(basic_ostream_char
*this)
5990 return (basic_ios_char
*)((char*)this+this->vbtable
[1]);
5993 static inline basic_ios_char
* basic_ostream_char_to_basic_ios(basic_ostream_char
*ptr
)
5995 return (basic_ios_char
*)((char*)ptr
+basic_ostream_char_vbtable
[1]);
5998 static inline basic_ostream_char
* basic_ostream_char_from_basic_ios(basic_ios_char
*ptr
)
6000 return (basic_ostream_char
*)((char*)ptr
-basic_ostream_char_vbtable
[1]);
6003 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
6004 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
6005 DEFINE_THISCALL_WRAPPER(basic_ostream_char_ctor
, 16)
6006 basic_ostream_char
* __thiscall
basic_ostream_char_ctor(basic_ostream_char
*this,
6007 basic_streambuf_char
*strbuf
, MSVCP_bool isstd
, MSVCP_bool virt_init
)
6009 basic_ios_char
*base
;
6011 TRACE("(%p %p %d %d)\n", this, strbuf
, isstd
, virt_init
);
6014 this->vbtable
= basic_ostream_char_vbtable
;
6015 base
= basic_ostream_char_get_basic_ios(this);
6016 basic_ios_char_ctor(base
);
6018 base
= basic_ostream_char_get_basic_ios(this);
6021 base
->base
.vtable
= &MSVCP_basic_ostream_char_vtable
;
6022 basic_ios_char_init(base
, strbuf
, isstd
);
6026 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
6027 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
6028 DEFINE_THISCALL_WRAPPER(basic_ostream_char_ctor_uninitialized
, 16)
6029 basic_ostream_char
* __thiscall
basic_ostream_char_ctor_uninitialized(basic_ostream_char
*this,
6030 int uninitialized
, MSVCP_bool addstd
, MSVCP_bool virt_init
)
6032 basic_ios_char
*base
;
6034 TRACE("(%p %d %x)\n", this, uninitialized
, addstd
);
6037 this->vbtable
= basic_ostream_char_vbtable
;
6038 base
= basic_ostream_char_get_basic_ios(this);
6039 basic_ios_char_ctor(base
);
6041 base
= basic_ostream_char_get_basic_ios(this);
6044 base
->base
.vtable
= &MSVCP_basic_ostream_char_vtable
;
6046 ios_base_Addstd(&base
->base
);
6050 /* ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UAE@XZ */
6051 /* ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
6052 DEFINE_THISCALL_WRAPPER(basic_ostream_char_dtor
, 4)
6053 void __thiscall
basic_ostream_char_dtor(basic_ios_char
*base
)
6055 basic_ostream_char
*this = basic_ostream_char_from_basic_ios(base
);
6057 /* don't destroy virtual base here */
6058 TRACE("(%p)\n", this);
6061 /* ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
6062 /* ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
6063 DEFINE_THISCALL_WRAPPER(basic_ostream_char_vbase_dtor
, 4)
6064 void __thiscall
basic_ostream_char_vbase_dtor(basic_ostream_char
*this)
6066 TRACE("(%p)\n", this);
6067 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(this));
6068 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(this));
6071 DEFINE_THISCALL_WRAPPER(basic_ostream_char_vector_dtor
, 8)
6072 basic_ostream_char
* __thiscall
basic_ostream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
6074 basic_ostream_char
*this = basic_ostream_char_from_basic_ios(base
);
6076 TRACE("(%p %x)\n", this, flags
);
6079 /* we have an array, with the number of elements stored before the first object */
6080 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
6082 for(i
=*ptr
-1; i
>=0; i
--)
6083 basic_ostream_char_vbase_dtor(this+i
);
6084 MSVCRT_operator_delete(ptr
);
6086 basic_ostream_char_vbase_dtor(this);
6088 MSVCRT_operator_delete(this);
6094 /* ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ */
6095 /* ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ */
6096 DEFINE_THISCALL_WRAPPER(basic_ostream_char_flush
, 4)
6097 basic_ostream_char
* __thiscall
basic_ostream_char_flush(basic_ostream_char
*this)
6099 /* this function is not matching C++ specification */
6100 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6102 TRACE("(%p)\n", this);
6104 if(basic_ios_char_rdbuf_get(base
) && ios_base_good(&base
->base
)
6105 && basic_streambuf_char_pubsync(basic_ios_char_rdbuf_get(base
))==-1)
6106 basic_ios_char_setstate(base
, IOSTATE_badbit
);
6110 /* ?flush@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
6111 /* ?flush@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
6112 basic_ostream_char
* __cdecl
flush_ostream_char(basic_ostream_char
*ostream
)
6114 return basic_ostream_char_flush(ostream
);
6117 /* ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
6118 /* ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
6119 DEFINE_THISCALL_WRAPPER(basic_ostream_char__Osfx
, 4)
6120 void __thiscall
basic_ostream_char__Osfx(basic_ostream_char
*this)
6122 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6124 TRACE("(%p)\n", this);
6126 if(base
->base
.fmtfl
& FMTFLAG_unitbuf
)
6127 basic_ostream_char_flush(this);
6130 /* ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
6131 /* ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
6132 DEFINE_THISCALL_WRAPPER(basic_ostream_char_osfx
, 4)
6133 void __thiscall
basic_ostream_char_osfx(basic_ostream_char
*this)
6135 TRACE("(%p)\n", this);
6136 basic_ostream_char__Osfx(this);
6139 static BOOL
basic_ostream_char_sentry_create(basic_ostream_char
*ostr
)
6141 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6143 if(basic_ios_char_rdbuf_get(base
))
6144 call_basic_streambuf_char__Lock(base
->strbuf
);
6146 if(ios_base_good(&base
->base
) && base
->stream
)
6147 basic_ostream_char_flush(base
->stream
);
6149 return ios_base_good(&base
->base
);
6152 static void basic_ostream_char_sentry_destroy(basic_ostream_char
*ostr
)
6154 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6156 if(ios_base_good(&base
->base
) && !__uncaught_exception())
6157 basic_ostream_char_osfx(ostr
);
6159 if(basic_ios_char_rdbuf_get(base
))
6160 call_basic_streambuf_char__Unlock(base
->strbuf
);
6163 /* ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE_NXZ */
6164 /* ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA_NXZ */
6165 DEFINE_THISCALL_WRAPPER(basic_ostream_char_opfx
, 4)
6166 MSVCP_bool __thiscall
basic_ostream_char_opfx(basic_ostream_char
*this)
6168 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6170 TRACE("(%p)\n", this);
6172 if(ios_base_good(&base
->base
) && base
->stream
)
6173 basic_ostream_char_flush(base
->stream
);
6174 return ios_base_good(&base
->base
);
6177 /* ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z */
6178 /* ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z */
6179 DEFINE_THISCALL_WRAPPER(basic_ostream_char_put
, 8)
6180 basic_ostream_char
* __thiscall
basic_ostream_char_put(basic_ostream_char
*this, char ch
)
6182 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6184 TRACE("(%p %c)\n", this, ch
);
6186 if(!basic_ostream_char_sentry_create(this)
6187 || basic_streambuf_char_sputc(base
->strbuf
, ch
)==EOF
) {
6188 basic_ostream_char_sentry_destroy(this);
6189 basic_ios_char_setstate(base
, IOSTATE_badbit
);
6193 basic_ostream_char_sentry_destroy(this);
6197 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@JH@Z */
6198 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
6199 #if STREAMOFF_BITS == 64
6200 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp
, 16)
6202 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp
, 12)
6204 basic_ostream_char
* __thiscall
basic_ostream_char_seekp(basic_ostream_char
*this, streamoff off
, int way
)
6206 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6208 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), way
);
6210 if(!ios_base_fail(&base
->base
)) {
6213 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
6214 &seek
, off
, way
, OPENMODE_out
);
6215 if(seek
.off
==-1 && seek
.pos
==0 && seek
.state
==0)
6216 basic_ios_char_setstate(base
, IOSTATE_failbit
);
6221 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
6222 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
6223 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp_fpos
, 28)
6224 basic_ostream_char
* __thiscall
basic_ostream_char_seekp_fpos(basic_ostream_char
*this, fpos_int pos
)
6226 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6228 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos
));
6230 if(!ios_base_fail(&base
->base
)) {
6233 basic_streambuf_char_pubseekpos(basic_ios_char_rdbuf_get(base
),
6234 &seek
, pos
, OPENMODE_out
);
6235 if(seek
.off
==-1 && seek
.pos
==0 && seek
.state
==0)
6236 basic_ios_char_setstate(base
, IOSTATE_failbit
);
6241 /* ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ */
6242 /* ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
6243 DEFINE_THISCALL_WRAPPER(basic_ostream_char_tellp
, 8)
6244 fpos_int
* __thiscall
basic_ostream_char_tellp(basic_ostream_char
*this, fpos_int
*ret
)
6246 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6248 TRACE("(%p)\n", this);
6250 if(!ios_base_fail(&base
->base
)) {
6251 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
6252 ret
, 0, SEEKDIR_cur
, OPENMODE_out
);
6261 /* ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@PBDH@Z */
6262 /* ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEBD_J@Z */
6263 #if STREAMSIZE_BITS == 64
6264 DEFINE_THISCALL_WRAPPER(basic_ostream_char_write
, 16)
6266 DEFINE_THISCALL_WRAPPER(basic_ostream_char_write
, 12)
6268 basic_ostream_char
* __thiscall
basic_ostream_char_write(basic_ostream_char
*this, const char *str
, streamsize count
)
6270 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6272 TRACE("(%p %s %s)\n", this, debugstr_a(str
), wine_dbgstr_longlong(count
));
6274 if(!basic_ostream_char_sentry_create(this)
6275 || basic_streambuf_char_sputn(base
->strbuf
, str
, count
)!=count
) {
6276 basic_ostream_char_sentry_destroy(this);
6277 basic_ios_char_setstate(base
, IOSTATE_badbit
);
6281 basic_ostream_char_sentry_destroy(this);
6285 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@F@Z */
6286 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@F@Z */
6287 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_short
, 8)
6288 basic_ostream_char
* __thiscall
basic_ostream_char_print_short(basic_ostream_char
*this, short val
)
6290 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6291 int state
= IOSTATE_goodbit
;
6293 TRACE("(%p %d)\n", this, val
);
6295 if(basic_ostream_char_sentry_create(this)) {
6296 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6297 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6298 ostreambuf_iterator_char dest
;
6300 memset(&dest
, 0, sizeof(dest
));
6301 dest
.strbuf
= strbuf
;
6302 num_put_char_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
),
6303 (ios_base_flags_get(&base
->base
) & FMTFLAG_basefield
& (FMTFLAG_oct
| FMTFLAG_hex
))
6304 ? (LONG
)((unsigned short)val
) : (LONG
)val
);
6306 basic_ostream_char_sentry_destroy(this);
6308 basic_ios_char_setstate(base
, state
);
6312 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@G@Z */
6313 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@G@Z */
6314 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ushort
, 8)
6315 basic_ostream_char
* __thiscall
basic_ostream_char_print_ushort(basic_ostream_char
*this, unsigned short val
)
6317 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6318 int state
= IOSTATE_goodbit
;
6320 TRACE("(%p %u)\n", this, val
);
6322 if(basic_ostream_char_sentry_create(this)) {
6323 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6324 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6325 ostreambuf_iterator_char dest
;
6327 memset(&dest
, 0, sizeof(dest
));
6328 dest
.strbuf
= strbuf
;
6329 num_put_char_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6331 basic_ostream_char_sentry_destroy(this);
6333 basic_ios_char_setstate(base
, state
);
6337 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@H@Z */
6338 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@H@Z */
6339 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@J@Z */
6340 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@J@Z */
6341 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_int
, 8)
6342 basic_ostream_char
* __thiscall
basic_ostream_char_print_int(basic_ostream_char
*this, int val
)
6344 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6345 int state
= IOSTATE_goodbit
;
6347 TRACE("(%p %d)\n", this, val
);
6349 if(basic_ostream_char_sentry_create(this)) {
6350 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6351 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6352 ostreambuf_iterator_char dest
;
6354 memset(&dest
, 0, sizeof(dest
));
6355 dest
.strbuf
= strbuf
;
6356 num_put_char_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6358 basic_ostream_char_sentry_destroy(this);
6360 basic_ios_char_setstate(base
, state
);
6364 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@I@Z */
6365 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@I@Z */
6366 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@K@Z */
6367 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@K@Z */
6368 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_uint
, 8)
6369 basic_ostream_char
* __thiscall
basic_ostream_char_print_uint(basic_ostream_char
*this, unsigned int val
)
6371 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6372 int state
= IOSTATE_goodbit
;
6374 TRACE("(%p %u)\n", this, val
);
6376 if(basic_ostream_char_sentry_create(this)) {
6377 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6378 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6379 ostreambuf_iterator_char dest
;
6381 memset(&dest
, 0, sizeof(dest
));
6382 dest
.strbuf
= strbuf
;
6383 num_put_char_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6385 basic_ostream_char_sentry_destroy(this);
6387 basic_ios_char_setstate(base
, state
);
6391 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@M@Z */
6392 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@M@Z */
6393 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_float
, 8)
6394 basic_ostream_char
* __thiscall
basic_ostream_char_print_float(basic_ostream_char
*this, float val
)
6396 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6397 int state
= IOSTATE_goodbit
;
6399 TRACE("(%p %f)\n", this, val
);
6401 if(basic_ostream_char_sentry_create(this)) {
6402 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6403 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6404 ostreambuf_iterator_char dest
;
6406 memset(&dest
, 0, sizeof(dest
));
6407 dest
.strbuf
= strbuf
;
6408 num_put_char_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6410 basic_ostream_char_sentry_destroy(this);
6412 basic_ios_char_setstate(base
, state
);
6416 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@N@Z */
6417 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@N@Z */
6418 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_double
, 12)
6419 basic_ostream_char
* __thiscall
basic_ostream_char_print_double(basic_ostream_char
*this, double val
)
6421 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6422 int state
= IOSTATE_goodbit
;
6424 TRACE("(%p %lf)\n", this, val
);
6426 if(basic_ostream_char_sentry_create(this)) {
6427 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6428 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6429 ostreambuf_iterator_char dest
;
6431 memset(&dest
, 0, sizeof(dest
));
6432 dest
.strbuf
= strbuf
;
6433 num_put_char_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6435 basic_ostream_char_sentry_destroy(this);
6437 basic_ios_char_setstate(base
, state
);
6441 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@O@Z */
6442 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@O@Z */
6443 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ldouble
, 12)
6444 basic_ostream_char
* __thiscall
basic_ostream_char_print_ldouble(basic_ostream_char
*this, double val
)
6446 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6447 int state
= IOSTATE_goodbit
;
6449 TRACE("(%p %lf)\n", this, val
);
6451 if(basic_ostream_char_sentry_create(this)) {
6452 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6453 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6454 ostreambuf_iterator_char dest
;
6456 memset(&dest
, 0, sizeof(dest
));
6457 dest
.strbuf
= strbuf
;
6458 num_put_char_put_ldouble(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6460 basic_ostream_char_sentry_destroy(this);
6462 basic_ios_char_setstate(base
, state
);
6466 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
6467 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
6468 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_streambuf
, 8)
6469 basic_ostream_char
* __thiscall
basic_ostream_char_print_streambuf(basic_ostream_char
*this, basic_streambuf_char
*val
)
6471 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6472 IOSB_iostate state
= IOSTATE_badbit
;
6475 TRACE("(%p %p)\n", this, val
);
6477 if(basic_ostream_char_sentry_create(this)) {
6478 for(c
= basic_streambuf_char_sgetc(val
); c
!=EOF
;
6479 c
= basic_streambuf_char_snextc(val
)) {
6480 state
= IOSTATE_goodbit
;
6482 if(basic_streambuf_char_sputc(base
->strbuf
, c
) == EOF
) {
6483 state
= IOSTATE_badbit
;
6488 state
= IOSTATE_badbit
;
6490 basic_ostream_char_sentry_destroy(this);
6492 ios_base_width_set(&base
->base
, 0);
6493 basic_ios_char_setstate(base
, state
);
6497 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PBX@Z */
6498 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEBX@Z */
6499 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ptr
, 8)
6500 basic_ostream_char
* __thiscall
basic_ostream_char_print_ptr(basic_ostream_char
*this, const void *val
)
6502 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6503 int state
= IOSTATE_goodbit
;
6505 TRACE("(%p %p)\n", this, val
);
6507 if(basic_ostream_char_sentry_create(this)) {
6508 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6509 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6510 ostreambuf_iterator_char dest
;
6512 memset(&dest
, 0, sizeof(dest
));
6513 dest
.strbuf
= strbuf
;
6514 num_put_char_put_ptr(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6516 basic_ostream_char_sentry_destroy(this);
6518 basic_ios_char_setstate(base
, state
);
6522 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_J@Z */
6523 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_J@Z */
6524 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_int64
, 12)
6525 basic_ostream_char
* __thiscall
basic_ostream_char_print_int64(basic_ostream_char
*this, __int64 val
)
6527 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6528 int state
= IOSTATE_goodbit
;
6530 TRACE("(%p)\n", this);
6532 if(basic_ostream_char_sentry_create(this)) {
6533 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6534 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6535 ostreambuf_iterator_char dest
;
6537 memset(&dest
, 0, sizeof(dest
));
6538 dest
.strbuf
= strbuf
;
6539 num_put_char_put_int64(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6541 basic_ostream_char_sentry_destroy(this);
6543 basic_ios_char_setstate(base
, state
);
6547 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_K@Z */
6548 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_K@Z */
6549 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_uint64
, 12)
6550 basic_ostream_char
* __thiscall
basic_ostream_char_print_uint64(basic_ostream_char
*this, unsigned __int64 val
)
6552 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6553 int state
= IOSTATE_goodbit
;
6555 TRACE("(%p)\n", this);
6557 if(basic_ostream_char_sentry_create(this)) {
6558 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6559 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6560 ostreambuf_iterator_char dest
;
6562 memset(&dest
, 0, sizeof(dest
));
6563 dest
.strbuf
= strbuf
;
6564 num_put_char_put_uint64(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6566 basic_ostream_char_sentry_destroy(this);
6568 basic_ios_char_setstate(base
, state
);
6572 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_N@Z */
6573 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_N@Z */
6574 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_bool
, 8)
6575 basic_ostream_char
* __thiscall
basic_ostream_char_print_bool(basic_ostream_char
*this, MSVCP_bool val
)
6577 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6578 int state
= IOSTATE_goodbit
;
6580 TRACE("(%p %x)\n", this, val
);
6582 if(basic_ostream_char_sentry_create(this)) {
6583 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6584 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6585 ostreambuf_iterator_char dest
;
6587 memset(&dest
, 0, sizeof(dest
));
6588 dest
.strbuf
= strbuf
;
6589 num_put_char_put_bool(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6591 basic_ostream_char_sentry_destroy(this);
6593 basic_ios_char_setstate(base
, state
);
6597 /* ?ends@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
6598 /* ?ends@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
6599 basic_ostream_char
* __cdecl
basic_ostream_char_ends(basic_ostream_char
*ostr
)
6601 TRACE("(%p)\n", ostr
);
6603 basic_ostream_char_put(ostr
, 0);
6607 /* ?endl@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
6608 /* ?endl@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
6609 basic_ostream_char
* __cdecl
basic_ostream_char_endl(basic_ostream_char
*ostr
)
6611 TRACE("(%p)\n", ostr
);
6613 basic_ostream_char_put(ostr
, '\n');
6614 basic_ostream_char_flush(ostr
);
6618 /* ??$?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 */
6619 /* ??$?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 */
6620 basic_ostream_char
* __cdecl
basic_ostream_char_print_bstr(basic_ostream_char
*ostr
, const basic_string_char
*str
)
6622 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6623 IOSB_iostate state
= IOSTATE_goodbit
;
6625 TRACE("(%p %p)\n", ostr
, str
);
6627 if(basic_ostream_char_sentry_create(ostr
)) {
6628 MSVCP_size_t len
= MSVCP_basic_string_char_length(str
);
6629 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
6631 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
6632 for(; pad
!=0; pad
--) {
6633 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6634 state
= IOSTATE_badbit
;
6640 if(state
== IOSTATE_goodbit
) {
6641 if(basic_streambuf_char_sputn(base
->strbuf
, MSVCP_basic_string_char_c_str(str
), len
) != len
)
6642 state
= IOSTATE_badbit
;
6645 if(state
== IOSTATE_goodbit
) {
6646 for(; pad
!=0; pad
--) {
6647 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6648 state
= IOSTATE_badbit
;
6654 base
->base
.wide
= 0;
6656 state
= IOSTATE_badbit
;
6658 basic_ostream_char_sentry_destroy(ostr
);
6660 basic_ios_char_setstate(base
, state
);
6664 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@C@Z */
6665 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@C@Z */
6666 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@D@Z */
6667 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@D@Z */
6668 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@E@Z */
6669 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@E@Z */
6670 basic_ostream_char
* __cdecl
basic_ostream_char_print_ch(basic_ostream_char
*ostr
, char ch
)
6672 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6673 IOSB_iostate state
= IOSTATE_goodbit
;
6675 TRACE("(%p %d)\n", ostr
, ch
);
6677 if(basic_ostream_char_sentry_create(ostr
)) {
6678 streamsize pad
= (base
->base
.wide
>1 ? base
->base
.wide
-1 : 0);
6680 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
6681 for(; pad
!=0; pad
--) {
6682 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6683 state
= IOSTATE_badbit
;
6689 if(state
== IOSTATE_goodbit
) {
6690 if(basic_streambuf_char_sputc(base
->strbuf
, ch
) == EOF
)
6691 state
= IOSTATE_badbit
;
6694 if(state
== IOSTATE_goodbit
) {
6695 for(; pad
!=0; pad
--) {
6696 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6697 state
= IOSTATE_badbit
;
6703 base
->base
.wide
= 0;
6705 state
= IOSTATE_badbit
;
6707 basic_ostream_char_sentry_destroy(ostr
);
6709 basic_ios_char_setstate(base
, state
);
6713 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBC@Z */
6714 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBC@Z */
6715 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBD@Z */
6716 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBD@Z */
6717 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBE@Z */
6718 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBE@Z */
6719 basic_ostream_char
* __cdecl
basic_ostream_char_print_str(basic_ostream_char
*ostr
, const char *str
)
6721 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6722 IOSB_iostate state
= IOSTATE_goodbit
;
6724 TRACE("(%p %s)\n", ostr
, str
);
6726 if(basic_ostream_char_sentry_create(ostr
)) {
6727 MSVCP_size_t len
= strlen(str
);
6728 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
6730 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
6731 for(; pad
!=0; pad
--) {
6732 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6733 state
= IOSTATE_badbit
;
6739 if(state
== IOSTATE_goodbit
) {
6740 if(basic_streambuf_char_sputn(base
->strbuf
, str
, len
) != len
)
6741 state
= IOSTATE_badbit
;
6744 if(state
== IOSTATE_goodbit
) {
6745 for(; pad
!=0; pad
--) {
6746 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6747 state
= IOSTATE_badbit
;
6753 base
->base
.wide
= 0;
6755 state
= IOSTATE_badbit
;
6757 basic_ostream_char_sentry_destroy(ostr
);
6759 basic_ios_char_setstate(base
, state
);
6763 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
6764 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
6765 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func
, 8)
6766 basic_ostream_char
* __thiscall
basic_ostream_char_print_func(basic_ostream_char
*this,
6767 basic_ostream_char
* (__cdecl
*pfunc
)(basic_ostream_char
*))
6769 TRACE("(%p %p)\n", this, pfunc
);
6774 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z */
6775 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z */
6776 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func_basic_ios
, 8)
6777 basic_ostream_char
* __thiscall
basic_ostream_char_print_func_basic_ios(basic_ostream_char
*this,
6778 basic_ios_char
* (__cdecl
*pfunc
)(basic_ios_char
*))
6780 TRACE("(%p %p)\n", this, pfunc
);
6781 pfunc(basic_ostream_char_get_basic_ios(this));
6785 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
6786 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
6787 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func_ios_base
, 8)
6788 basic_ostream_char
* __thiscall
basic_ostream_char_print_func_ios_base(
6789 basic_ostream_char
*this, ios_base
* (__cdecl
*pfunc
)(ios_base
*))
6791 TRACE("(%p %p)\n", this, pfunc
);
6792 pfunc(&basic_ostream_char_get_basic_ios(this)->base
);
6796 /* ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z */
6797 /* ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z */
6798 DEFINE_THISCALL_WRAPPER(basic_ostream_char_swap
, 8)
6799 void __thiscall
basic_ostream_char_swap(basic_ostream_char
*this, basic_ostream_char
*r
)
6801 TRACE("(%p %p)\n", this, r
);
6806 basic_ios_char_swap(basic_ostream_char_get_basic_ios(this),
6807 basic_ostream_char_get_basic_ios(r
));
6810 /* Caution: basic_ostream uses virtual inheritance. */
6811 static inline basic_ios_wchar
* basic_ostream_wchar_get_basic_ios(basic_ostream_wchar
*this)
6813 return (basic_ios_wchar
*)((char*)this+this->vbtable
[1]);
6816 static inline basic_ios_wchar
* basic_ostream_wchar_to_basic_ios(basic_ostream_wchar
*ptr
)
6818 return (basic_ios_wchar
*)((char*)ptr
+basic_ostream_wchar_vbtable
[1]);
6821 static inline basic_ostream_wchar
* basic_ostream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
6823 return (basic_ostream_wchar
*)((char*)ptr
-basic_ostream_wchar_vbtable
[1]);
6826 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
6827 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
6828 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_ctor
, 16)
6829 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_ctor(basic_ostream_wchar
*this,
6830 basic_streambuf_wchar
*strbuf
, MSVCP_bool isstd
, MSVCP_bool virt_init
)
6832 basic_ios_wchar
*base
;
6834 TRACE("(%p %p %d %d)\n", this, strbuf
, isstd
, virt_init
);
6837 this->vbtable
= basic_ostream_wchar_vbtable
;
6838 base
= basic_ostream_wchar_get_basic_ios(this);
6839 basic_ios_wchar_ctor(base
);
6841 base
= basic_ostream_wchar_get_basic_ios(this);
6844 base
->base
.vtable
= &MSVCP_basic_ostream_wchar_vtable
;
6845 basic_ios_wchar_init(base
, strbuf
, isstd
);
6849 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
6850 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
6851 DEFINE_THISCALL_WRAPPER(basic_ostream_short_ctor
, 16)
6852 basic_ostream_wchar
* __thiscall
basic_ostream_short_ctor(basic_ostream_wchar
*this,
6853 basic_streambuf_wchar
*strbuf
, MSVCP_bool isstd
, MSVCP_bool virt_init
)
6855 basic_ostream_wchar_ctor(this, strbuf
, isstd
, virt_init
);
6856 basic_ostream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_ostream_short_vtable
;
6860 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
6861 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
6862 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_ctor_uninitialized
, 16)
6863 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_ctor_uninitialized(basic_ostream_wchar
*this,
6864 int uninitialized
, MSVCP_bool addstd
, MSVCP_bool virt_init
)
6866 basic_ios_wchar
*base
;
6868 TRACE("(%p %d %x)\n", this, uninitialized
, addstd
);
6871 this->vbtable
= basic_ostream_wchar_vbtable
;
6872 base
= basic_ostream_wchar_get_basic_ios(this);
6873 basic_ios_wchar_ctor(base
);
6875 base
= basic_ostream_wchar_get_basic_ios(this);
6878 base
->base
.vtable
= &MSVCP_basic_ostream_wchar_vtable
;
6880 ios_base_Addstd(&base
->base
);
6884 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
6885 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
6886 DEFINE_THISCALL_WRAPPER(basic_ostream_short_ctor_uninitialized
, 16)
6887 basic_ostream_wchar
* __thiscall
basic_ostream_short_ctor_uninitialized(basic_ostream_wchar
*this,
6888 int uninitialized
, MSVCP_bool addstd
, MSVCP_bool virt_init
)
6890 basic_ostream_wchar_ctor_uninitialized(this, uninitialized
, addstd
, virt_init
);
6891 basic_ostream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_ostream_short_vtable
;
6895 /* ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
6896 /* ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
6897 /* ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UAE@XZ */
6898 /* ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
6899 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_dtor
, 4)
6900 void __thiscall
basic_ostream_wchar_dtor(basic_ios_wchar
*base
)
6902 basic_ostream_wchar
*this = basic_ostream_wchar_from_basic_ios(base
);
6904 /* don't destroy virtual base here */
6905 TRACE("(%p)\n", this);
6908 /* ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
6909 /* ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
6910 /* ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
6911 /* ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
6912 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_vbase_dtor
, 4)
6913 void __thiscall
basic_ostream_wchar_vbase_dtor(basic_ostream_wchar
*this)
6915 TRACE("(%p)\n", this);
6916 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(this));
6917 basic_ios_wchar_dtor(basic_ostream_wchar_get_basic_ios(this));
6920 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_vector_dtor
, 8)
6921 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
6923 basic_ostream_wchar
*this = basic_ostream_wchar_from_basic_ios(base
);
6925 TRACE("(%p %x)\n", this, flags
);
6928 /* we have an array, with the number of elements stored before the first object */
6929 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
6931 for(i
=*ptr
-1; i
>=0; i
--)
6932 basic_ostream_wchar_vbase_dtor(this+i
);
6933 MSVCRT_operator_delete(ptr
);
6935 basic_ostream_wchar_vbase_dtor(this);
6937 MSVCRT_operator_delete(this);
6943 /* ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ */
6944 /* ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ */
6945 /* ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ */
6946 /* ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ */
6947 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_flush
, 4)
6948 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_flush(basic_ostream_wchar
*this)
6950 /* this function is not matching C++ specification */
6951 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
6953 TRACE("(%p)\n", this);
6955 if(basic_ios_wchar_rdbuf_get(base
) && ios_base_good(&base
->base
)
6956 && basic_streambuf_wchar_pubsync(basic_ios_wchar_rdbuf_get(base
))==-1)
6957 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
6961 /* ?flush@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
6962 /* ?flush@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
6963 /* ?flush@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
6964 /* ?flush@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
6965 basic_ostream_wchar
* __cdecl
flush_ostream_wchar(basic_ostream_wchar
*ostream
)
6967 return basic_ostream_wchar_flush(ostream
);
6970 /* ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
6971 /* ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
6972 /* ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
6973 /* ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
6974 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar__Osfx
, 4)
6975 void __thiscall
basic_ostream_wchar__Osfx(basic_ostream_wchar
*this)
6977 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
6979 TRACE("(%p)\n", this);
6981 if(base
->base
.fmtfl
& FMTFLAG_unitbuf
)
6982 basic_ostream_wchar_flush(this);
6985 /* ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
6986 /* ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
6987 /* ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
6988 /* ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
6989 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_osfx
, 4)
6990 void __thiscall
basic_ostream_wchar_osfx(basic_ostream_wchar
*this)
6992 TRACE("(%p)\n", this);
6993 basic_ostream_wchar__Osfx(this);
6996 static BOOL
basic_ostream_wchar_sentry_create(basic_ostream_wchar
*ostr
)
6998 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7000 if(basic_ios_wchar_rdbuf_get(base
))
7001 basic_streambuf_wchar__Lock(base
->strbuf
);
7003 if(ios_base_good(&base
->base
) && base
->stream
)
7004 basic_ostream_wchar_flush(base
->stream
);
7006 return ios_base_good(&base
->base
);
7009 static void basic_ostream_wchar_sentry_destroy(basic_ostream_wchar
*ostr
)
7011 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7013 if(ios_base_good(&base
->base
) && !__uncaught_exception())
7014 basic_ostream_wchar_osfx(ostr
);
7016 if(basic_ios_wchar_rdbuf_get(base
))
7017 basic_streambuf_wchar__Unlock(base
->strbuf
);
7020 /* ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE_NXZ */
7021 /* ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA_NXZ */
7022 /* ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE_NXZ */
7023 /* ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA_NXZ */
7024 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_opfx
, 4)
7025 MSVCP_bool __thiscall
basic_ostream_wchar_opfx(basic_ostream_wchar
*this)
7027 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7029 TRACE("(%p)\n", this);
7031 if(ios_base_good(&base
->base
) && base
->stream
)
7032 basic_ostream_wchar_flush(base
->stream
);
7033 return ios_base_good(&base
->base
);
7036 /* ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z */
7037 /* ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z */
7038 /* ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z */
7039 /* ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z */
7040 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_put
, 8)
7041 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_put(basic_ostream_wchar
*this, wchar_t ch
)
7043 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7045 TRACE("(%p %c)\n", this, ch
);
7047 if(!basic_ostream_wchar_sentry_create(this)
7048 || basic_streambuf_wchar_sputc(base
->strbuf
, ch
)==WEOF
) {
7049 basic_ostream_wchar_sentry_destroy(this);
7050 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
7054 basic_ostream_wchar_sentry_destroy(this);
7058 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@JH@Z */
7059 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z */
7060 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@JH@Z */
7061 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z */
7062 #if STREAMOFF_BITS == 64
7063 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp
, 16)
7065 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp
, 12)
7067 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_seekp(basic_ostream_wchar
*this, streamoff off
, int way
)
7069 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7071 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), way
);
7073 if(!ios_base_fail(&base
->base
)) {
7076 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
7077 &seek
, off
, way
, OPENMODE_out
);
7078 if(seek
.off
==-1 && seek
.pos
==0 && seek
.state
==0)
7079 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
7084 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
7085 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
7086 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
7087 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
7088 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp_fpos
, 28)
7089 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_seekp_fpos(basic_ostream_wchar
*this, fpos_int pos
)
7091 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7093 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos
));
7095 if(!ios_base_fail(&base
->base
)) {
7098 basic_streambuf_wchar_pubseekpos(basic_ios_wchar_rdbuf_get(base
),
7099 &seek
, pos
, OPENMODE_out
);
7100 if(seek
.off
==-1 && seek
.pos
==0 && seek
.state
==0)
7101 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
7106 /* ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ */
7107 /* ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
7108 /* ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ */
7109 /* ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
7110 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_tellp
, 8)
7111 fpos_int
* __thiscall
basic_ostream_wchar_tellp(basic_ostream_wchar
*this, fpos_int
*ret
)
7113 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7115 TRACE("(%p)\n", this);
7117 if(!ios_base_fail(&base
->base
)) {
7118 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
7119 ret
, 0, SEEKDIR_cur
, OPENMODE_out
);
7128 /* ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PB_WH@Z */
7129 /* ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEB_W_J@Z */
7130 /* ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@PBGH@Z */
7131 /* ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEBG_J@Z */
7132 #if STREAMSIZE_BITS == 64
7133 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_write
, 16)
7135 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_write
, 12)
7137 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_write(basic_ostream_wchar
*this, const wchar_t *str
, streamsize count
)
7139 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7141 TRACE("(%p %s %s)\n", this, debugstr_w(str
), wine_dbgstr_longlong(count
));
7143 if(!basic_ostream_wchar_sentry_create(this)
7144 || basic_streambuf_wchar_sputn(base
->strbuf
, str
, count
)!=count
) {
7145 basic_ostream_wchar_sentry_destroy(this);
7146 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
7150 basic_ostream_wchar_sentry_destroy(this);
7154 static basic_ostream_wchar
* basic_ostream_print_short(basic_ostream_wchar
*this, short val
, const num_put
*numput
)
7156 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7157 int state
= IOSTATE_goodbit
;
7159 TRACE("(%p %d)\n", this, val
);
7161 if(basic_ostream_wchar_sentry_create(this)) {
7162 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7163 ostreambuf_iterator_wchar dest
;
7165 memset(&dest
, 0, sizeof(dest
));
7166 dest
.strbuf
= strbuf
;
7167 num_put_wchar_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
),
7168 (ios_base_flags_get(&base
->base
) & FMTFLAG_basefield
& (FMTFLAG_oct
| FMTFLAG_hex
))
7169 ? (LONG
)((unsigned short)val
) : (LONG
)val
);
7171 basic_ostream_wchar_sentry_destroy(this);
7173 basic_ios_wchar_setstate(base
, state
);
7177 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@F@Z */
7178 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@F@Z */
7179 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_short
, 8)
7180 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_short(basic_ostream_wchar
*this, short val
)
7182 return basic_ostream_print_short(this, val
, num_put_wchar_use_facet(
7183 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7186 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@F@Z */
7187 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@F@Z */
7188 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_short
, 8)
7189 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_short(basic_ostream_wchar
*this, short val
)
7191 return basic_ostream_print_short(this, val
, num_put_short_use_facet(
7192 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7195 static basic_ostream_wchar
* basic_ostream_print_ushort(basic_ostream_wchar
*this, unsigned short val
, const num_put
*numput
)
7197 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7198 int state
= IOSTATE_goodbit
;
7200 TRACE("(%p %d)\n", this, val
);
7202 if(basic_ostream_wchar_sentry_create(this)) {
7203 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7204 ostreambuf_iterator_wchar dest
;
7206 memset(&dest
, 0, sizeof(dest
));
7207 dest
.strbuf
= strbuf
;
7208 num_put_wchar_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7210 basic_ostream_wchar_sentry_destroy(this);
7212 basic_ios_wchar_setstate(base
, state
);
7216 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@G@Z */
7217 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@G@Z */
7218 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ushort
, 8)
7219 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_ushort(basic_ostream_wchar
*this, unsigned short val
)
7221 return basic_ostream_print_ushort(this, val
, num_put_wchar_use_facet(
7222 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7225 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@G@Z */
7226 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@G@Z */
7227 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ushort
, 8)
7228 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_ushort(basic_ostream_wchar
*this, unsigned short val
)
7230 return basic_ostream_print_ushort(this, val
, num_put_short_use_facet(
7231 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7234 /* ??6std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@G@Z */
7235 /* ??6std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@G@Z */
7236 basic_ostream_wchar
* __cdecl
basic_ostream_short_print_ushort_global(basic_ostream_wchar
*ostr
, unsigned short val
)
7238 return basic_ostream_print_ushort(ostr
, val
, num_put_short_use_facet(
7239 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(ostr
)))));
7242 static basic_ostream_wchar
* basic_ostream_print_int(basic_ostream_wchar
*this, int val
, const num_put
*numput
)
7244 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7245 int state
= IOSTATE_goodbit
;
7247 TRACE("(%p %d)\n", this, val
);
7249 if(basic_ostream_wchar_sentry_create(this)) {
7250 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7251 ostreambuf_iterator_wchar dest
;
7253 memset(&dest
, 0, sizeof(dest
));
7254 dest
.strbuf
= strbuf
;
7255 num_put_wchar_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7257 basic_ostream_wchar_sentry_destroy(this);
7259 basic_ios_wchar_setstate(base
, state
);
7263 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@H@Z */
7264 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@H@Z */
7265 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@J@Z */
7266 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@J@Z */
7267 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_int
, 8)
7268 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_int(basic_ostream_wchar
*this, int val
)
7270 return basic_ostream_print_int(this, val
, num_put_wchar_use_facet(
7271 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7274 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@H@Z */
7275 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@H@Z */
7276 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@J@Z */
7277 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@J@Z */
7278 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_int
, 8)
7279 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_int(basic_ostream_wchar
*this, int val
)
7281 return basic_ostream_print_int(this, val
, num_put_short_use_facet(
7282 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7285 static basic_ostream_wchar
* basic_ostream_print_uint(basic_ostream_wchar
*this, unsigned int val
, const num_put
*numput
)
7287 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7288 int state
= IOSTATE_goodbit
;
7290 TRACE("(%p %u)\n", this, val
);
7292 if(basic_ostream_wchar_sentry_create(this)) {
7293 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7294 ostreambuf_iterator_wchar dest
;
7296 memset(&dest
, 0, sizeof(dest
));
7297 dest
.strbuf
= strbuf
;
7298 num_put_wchar_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7300 basic_ostream_wchar_sentry_destroy(this);
7302 basic_ios_wchar_setstate(base
, state
);
7306 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@I@Z */
7307 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@I@Z */
7308 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@K@Z */
7309 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@K@Z */
7310 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_uint
, 8)
7311 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_uint(basic_ostream_wchar
*this, unsigned int val
)
7313 return basic_ostream_print_uint(this, val
, num_put_wchar_use_facet(
7314 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7317 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@I@Z */
7318 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@I@Z */
7319 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@K@Z */
7320 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@K@Z */
7321 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_uint
, 8)
7322 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_uint(basic_ostream_wchar
*this, unsigned int val
)
7324 return basic_ostream_print_uint(this, val
, num_put_short_use_facet(
7325 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7328 static basic_ostream_wchar
* basic_ostream_print_float(basic_ostream_wchar
*this, float val
, const num_put
*numput
)
7330 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7331 int state
= IOSTATE_goodbit
;
7333 TRACE("(%p %f)\n", this, val
);
7335 if(basic_ostream_wchar_sentry_create(this)) {
7336 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7337 ostreambuf_iterator_wchar dest
;
7339 memset(&dest
, 0, sizeof(dest
));
7340 dest
.strbuf
= strbuf
;
7341 num_put_wchar_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7343 basic_ostream_wchar_sentry_destroy(this);
7345 basic_ios_wchar_setstate(base
, state
);
7349 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@M@Z */
7350 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@M@Z */
7351 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_float
, 8)
7352 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_float(basic_ostream_wchar
*this, float val
)
7354 return basic_ostream_print_float(this, val
, num_put_wchar_use_facet(
7355 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7358 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@M@Z */
7359 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@M@Z */
7360 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_float
, 8)
7361 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_float(basic_ostream_wchar
*this, float val
)
7363 return basic_ostream_print_float(this, val
, num_put_short_use_facet(
7364 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7367 static basic_ostream_wchar
* basic_ostream_print_double(basic_ostream_wchar
*this, double val
, const num_put
*numput
)
7369 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7370 int state
= IOSTATE_goodbit
;
7372 TRACE("(%p %lf)\n", this, val
);
7374 if(basic_ostream_wchar_sentry_create(this)) {
7375 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7376 ostreambuf_iterator_wchar dest
;
7378 memset(&dest
, 0, sizeof(dest
));
7379 dest
.strbuf
= strbuf
;
7380 num_put_wchar_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7382 basic_ostream_wchar_sentry_destroy(this);
7384 basic_ios_wchar_setstate(base
, state
);
7388 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@N@Z */
7389 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@N@Z */
7390 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_double
, 12)
7391 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_double(basic_ostream_wchar
*this, double val
)
7393 return basic_ostream_print_double(this, val
, num_put_wchar_use_facet(
7394 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7397 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@N@Z */
7398 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@N@Z */
7399 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_double
, 12)
7400 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_double(basic_ostream_wchar
*this, double val
)
7402 return basic_ostream_print_double(this, val
, num_put_short_use_facet(
7403 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7406 static basic_ostream_wchar
* basic_ostream_print_ldouble(basic_ostream_wchar
*this, double val
, const num_put
*numput
)
7408 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7409 int state
= IOSTATE_goodbit
;
7411 TRACE("(%p %lf)\n", this, val
);
7413 if(basic_ostream_wchar_sentry_create(this)) {
7414 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7415 ostreambuf_iterator_wchar dest
;
7417 memset(&dest
, 0, sizeof(dest
));
7418 dest
.strbuf
= strbuf
;
7419 num_put_wchar_put_ldouble(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7421 basic_ostream_wchar_sentry_destroy(this);
7423 basic_ios_wchar_setstate(base
, state
);
7427 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@O@Z */
7428 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@O@Z */
7429 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ldouble
, 12)
7430 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_ldouble(basic_ostream_wchar
*this, double val
)
7432 return basic_ostream_print_ldouble(this, val
, num_put_wchar_use_facet(
7433 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7436 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@O@Z */
7437 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@O@Z */
7438 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ldouble
, 12)
7439 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_ldouble(basic_ostream_wchar
*this, double val
)
7441 return basic_ostream_print_ldouble(this, val
, num_put_short_use_facet(
7442 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7445 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
7446 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
7447 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
7448 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
7449 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_streambuf
, 8)
7450 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_streambuf(basic_ostream_wchar
*this, basic_streambuf_wchar
*val
)
7452 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7453 IOSB_iostate state
= IOSTATE_badbit
;
7454 unsigned short c
= '\n';
7456 TRACE("(%p %p)\n", this, val
);
7458 if(basic_ostream_wchar_sentry_create(this)) {
7459 for(c
= basic_streambuf_wchar_sgetc(val
); c
!=WEOF
;
7460 c
= basic_streambuf_wchar_snextc(val
)) {
7461 state
= IOSTATE_goodbit
;
7463 if(basic_streambuf_wchar_sputc(base
->strbuf
, c
) == WEOF
) {
7464 state
= IOSTATE_badbit
;
7469 state
= IOSTATE_badbit
;
7471 basic_ostream_wchar_sentry_destroy(this);
7473 ios_base_width_set(&base
->base
, 0);
7474 basic_ios_wchar_setstate(base
, state
);
7478 static basic_ostream_wchar
* basic_ostream_print_ptr(basic_ostream_wchar
*this, const void *val
, const num_put
*numput
)
7480 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7481 int state
= IOSTATE_goodbit
;
7483 TRACE("(%p %p)\n", this, val
);
7485 if(basic_ostream_wchar_sentry_create(this)) {
7486 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7487 ostreambuf_iterator_wchar dest
;
7489 memset(&dest
, 0, sizeof(dest
));
7490 dest
.strbuf
= strbuf
;
7491 num_put_wchar_put_ptr(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7493 basic_ostream_wchar_sentry_destroy(this);
7495 basic_ios_wchar_setstate(base
, state
);
7499 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PBX@Z */
7500 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEBX@Z */
7501 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ptr
, 8)
7502 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_ptr(basic_ostream_wchar
*this, const void *val
)
7504 return basic_ostream_print_ptr(this, val
, num_put_wchar_use_facet(
7505 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7508 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PBX@Z */
7509 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEBX@Z */
7510 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ptr
, 8)
7511 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_ptr(basic_ostream_wchar
*this, const void *val
)
7513 return basic_ostream_print_ptr(this, val
, num_put_short_use_facet(
7514 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7517 static basic_ostream_wchar
* basic_ostream_print_int64(basic_ostream_wchar
*this, __int64 val
, const num_put
*numput
)
7519 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7520 int state
= IOSTATE_goodbit
;
7522 TRACE("(%p)\n", this);
7524 if(basic_ostream_wchar_sentry_create(this)) {
7525 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7526 ostreambuf_iterator_wchar dest
;
7528 memset(&dest
, 0, sizeof(dest
));
7529 dest
.strbuf
= strbuf
;
7530 num_put_wchar_put_int64(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7532 basic_ostream_wchar_sentry_destroy(this);
7534 basic_ios_wchar_setstate(base
, state
);
7538 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_J@Z */
7539 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_J@Z */
7540 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_int64
, 12)
7541 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_int64(basic_ostream_wchar
*this, __int64 val
)
7543 return basic_ostream_print_int64(this, val
, num_put_wchar_use_facet(
7544 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7547 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_J@Z */
7548 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_J@Z */
7549 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_int64
, 12)
7550 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_int64(basic_ostream_wchar
*this, __int64 val
)
7552 return basic_ostream_print_int64(this, val
, num_put_short_use_facet(
7553 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7556 static basic_ostream_wchar
* basic_ostream_print_uint64(basic_ostream_wchar
*this, unsigned __int64 val
, const num_put
*numput
)
7558 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7559 int state
= IOSTATE_goodbit
;
7561 TRACE("(%p)\n", this);
7563 if(basic_ostream_wchar_sentry_create(this)) {
7564 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7565 ostreambuf_iterator_wchar dest
;
7567 memset(&dest
, 0, sizeof(dest
));
7568 dest
.strbuf
= strbuf
;
7569 num_put_wchar_put_uint64(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7571 basic_ostream_wchar_sentry_destroy(this);
7573 basic_ios_wchar_setstate(base
, state
);
7577 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_K@Z */
7578 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_K@Z */
7579 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_uint64
, 12)
7580 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_uint64(basic_ostream_wchar
*this, unsigned __int64 val
)
7582 return basic_ostream_print_uint64(this, val
, num_put_wchar_use_facet(
7583 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7586 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_K@Z */
7587 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_K@Z */
7588 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_uint64
, 12)
7589 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_uint64(basic_ostream_wchar
*this, unsigned __int64 val
)
7591 return basic_ostream_print_uint64(this, val
, num_put_short_use_facet(
7592 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7595 static basic_ostream_wchar
* basic_ostream_print_bool(basic_ostream_wchar
*this, MSVCP_bool val
, const num_put
*numput
)
7597 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7598 int state
= IOSTATE_goodbit
;
7600 TRACE("(%p %x)\n", this, val
);
7602 if(basic_ostream_wchar_sentry_create(this)) {
7603 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7604 ostreambuf_iterator_wchar dest
;
7606 memset(&dest
, 0, sizeof(dest
));
7607 dest
.strbuf
= strbuf
;
7608 num_put_wchar_put_bool(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7610 basic_ostream_wchar_sentry_destroy(this);
7612 basic_ios_wchar_setstate(base
, state
);
7616 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_N@Z */
7617 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_N@Z */
7618 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_bool
, 8)
7619 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_bool(basic_ostream_wchar
*this, MSVCP_bool val
)
7621 return basic_ostream_print_bool(this, val
, num_put_wchar_use_facet(
7622 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7625 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_N@Z */
7626 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_N@Z */
7627 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_bool
, 8)
7628 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_bool(basic_ostream_wchar
*this, MSVCP_bool val
)
7630 return basic_ostream_print_bool(this, val
, num_put_short_use_facet(
7631 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7634 /* ?ends@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
7635 /* ?ends@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
7636 /* ?ends@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
7637 /* ?ends@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
7638 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_ends(basic_ostream_wchar
*ostr
)
7640 TRACE("(%p)\n", ostr
);
7642 basic_ostream_wchar_put(ostr
, 0);
7646 /* ?endl@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
7647 /* ?endl@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
7648 /* ?endl@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
7649 /* ?endl@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
7650 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_endl(basic_ostream_wchar
*ostr
)
7652 TRACE("(%p)\n", ostr
);
7654 basic_ostream_wchar_put(ostr
, '\n');
7655 basic_ostream_wchar_flush(ostr
);
7659 /* ??$?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 */
7660 /* ??$?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 */
7661 /* ??$?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 */
7662 /* ??$?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 */
7663 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_print_bstr(basic_ostream_wchar
*ostr
, const basic_string_wchar
*str
)
7665 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7666 IOSB_iostate state
= IOSTATE_goodbit
;
7668 TRACE("(%p %p)\n", ostr
, str
);
7670 if(basic_ostream_wchar_sentry_create(ostr
)) {
7671 MSVCP_size_t len
= MSVCP_basic_string_wchar_length(str
);
7672 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
7674 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
7675 for(; pad
!=0; pad
--) {
7676 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7677 state
= IOSTATE_badbit
;
7683 if(state
== IOSTATE_goodbit
) {
7684 if(basic_streambuf_wchar_sputn(base
->strbuf
, MSVCP_basic_string_wchar_c_str(str
), len
) != len
)
7685 state
= IOSTATE_badbit
;
7688 if(state
== IOSTATE_goodbit
) {
7689 for(; pad
!=0; pad
--) {
7690 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7691 state
= IOSTATE_badbit
;
7697 base
->base
.wide
= 0;
7699 state
= IOSTATE_badbit
;
7701 basic_ostream_wchar_sentry_destroy(ostr
);
7703 basic_ios_wchar_setstate(base
, state
);
7707 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@_W@Z */
7708 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@_W@Z */
7709 /* ??$?6GU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@G@Z */
7710 /* ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@G@Z */
7711 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_print_ch(basic_ostream_wchar
*ostr
, wchar_t ch
)
7713 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7714 IOSB_iostate state
= IOSTATE_goodbit
;
7716 TRACE("(%p %d)\n", ostr
, ch
);
7718 if(basic_ostream_wchar_sentry_create(ostr
)) {
7719 streamsize pad
= (base
->base
.wide
>1 ? base
->base
.wide
-1 : 0);
7721 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
7722 for(; pad
!=0; pad
--) {
7723 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7724 state
= IOSTATE_badbit
;
7730 if(state
== IOSTATE_goodbit
) {
7731 if(basic_streambuf_wchar_sputc(base
->strbuf
, ch
) == WEOF
)
7732 state
= IOSTATE_badbit
;
7735 if(state
== IOSTATE_goodbit
) {
7736 for(; pad
!=0; pad
--) {
7737 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7738 state
= IOSTATE_badbit
;
7744 base
->base
.wide
= 0;
7746 state
= IOSTATE_badbit
;
7748 basic_ostream_wchar_sentry_destroy(ostr
);
7750 basic_ios_wchar_setstate(base
, state
);
7754 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@PB_W@Z */
7755 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@PEB_W@Z */
7756 /* ??$?6GU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@PBG@Z */
7757 /* ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@PEBG@Z */
7758 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_print_str(basic_ostream_wchar
*ostr
, const wchar_t *str
)
7760 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7761 IOSB_iostate state
= IOSTATE_goodbit
;
7763 TRACE("(%p %s)\n", ostr
, debugstr_w(str
));
7765 if(basic_ostream_wchar_sentry_create(ostr
)) {
7766 MSVCP_size_t len
= wcslen(str
);
7767 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
7769 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
7770 for(; pad
!=0; pad
--) {
7771 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7772 state
= IOSTATE_badbit
;
7778 if(state
== IOSTATE_goodbit
) {
7779 if(basic_streambuf_wchar_sputn(base
->strbuf
, str
, len
) != len
)
7780 state
= IOSTATE_badbit
;
7783 if(state
== IOSTATE_goodbit
) {
7784 for(; pad
!=0; pad
--) {
7785 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7786 state
= IOSTATE_badbit
;
7792 base
->base
.wide
= 0;
7794 state
= IOSTATE_badbit
;
7796 basic_ostream_wchar_sentry_destroy(ostr
);
7798 basic_ios_wchar_setstate(base
, state
);
7802 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
7803 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
7804 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
7805 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
7806 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func
, 8)
7807 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_func(basic_ostream_wchar
*this,
7808 basic_ostream_wchar
* (__cdecl
*pfunc
)(basic_ostream_wchar
*))
7810 TRACE("(%p %p)\n", this, pfunc
);
7815 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z */
7816 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z */
7817 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z */
7818 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z */
7819 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func_basic_ios
, 8)
7820 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_func_basic_ios(basic_ostream_wchar
*this,
7821 basic_ios_wchar
* (__cdecl
*pfunc
)(basic_ios_wchar
*))
7823 TRACE("(%p %p)\n", this, pfunc
);
7824 pfunc(basic_ostream_wchar_get_basic_ios(this));
7828 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
7829 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
7830 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
7831 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
7832 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func_ios_base
, 8)
7833 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_func_ios_base(
7834 basic_ostream_wchar
*this, ios_base
* (__cdecl
*pfunc
)(ios_base
*))
7836 TRACE("(%p %p)\n", this, pfunc
);
7837 pfunc(&basic_ostream_wchar_get_basic_ios(this)->base
);
7841 /* ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z */
7842 /* ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z */
7843 /* ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z */
7844 /* ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IEAAXAEAV12@@Z */
7845 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_swap
, 8)
7846 void __thiscall
basic_ostream_wchar_swap(basic_ostream_wchar
*this, basic_ostream_wchar
*r
)
7848 TRACE("(%p %p)\n", this, r
);
7853 basic_ios_wchar_swap(basic_ostream_wchar_get_basic_ios(this),
7854 basic_ostream_wchar_get_basic_ios(r
));
7857 /* Caution: basic_istream uses virtual inheritance. */
7858 static inline basic_ios_char
* basic_istream_char_get_basic_ios(basic_istream_char
*this)
7860 return (basic_ios_char
*)((char*)this+this->vbtable
[1]);
7863 static inline basic_ios_char
* basic_istream_char_to_basic_ios(basic_istream_char
*ptr
)
7865 return (basic_ios_char
*)((char*)ptr
+basic_istream_char_vbtable
[1]);
7868 static inline basic_istream_char
* basic_istream_char_from_basic_ios(basic_ios_char
*ptr
)
7870 return (basic_istream_char
*)((char*)ptr
-basic_istream_char_vbtable
[1]);
7873 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z */
7874 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z */
7875 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor_init
, 20)
7876 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
)
7878 basic_ios_char
*base
;
7880 TRACE("(%p %p %d %d %d)\n", this, strbuf
, isstd
, noinit
, virt_init
);
7883 this->vbtable
= basic_istream_char_vbtable
;
7884 base
= basic_istream_char_get_basic_ios(this);
7885 basic_ios_char_ctor(base
);
7887 base
= basic_istream_char_get_basic_ios(this);
7890 base
->base
.vtable
= &MSVCP_basic_istream_char_vtable
;
7893 basic_ios_char_init(base
, strbuf
, isstd
);
7897 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
7898 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
7899 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor
, 16)
7900 basic_istream_char
* __thiscall
basic_istream_char_ctor(basic_istream_char
*this, basic_streambuf_char
*strbuf
, MSVCP_bool isstd
, MSVCP_bool virt_init
)
7902 return basic_istream_char_ctor_init(this, strbuf
, isstd
, FALSE
, virt_init
);
7905 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z */
7906 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
7907 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor_uninitialized
, 12)
7908 basic_istream_char
* __thiscall
basic_istream_char_ctor_uninitialized(basic_istream_char
*this, int uninitialized
, MSVCP_bool virt_init
)
7910 basic_ios_char
*base
;
7912 TRACE("(%p %d %d)\n", this, uninitialized
, virt_init
);
7915 this->vbtable
= basic_istream_char_vbtable
;
7916 base
= basic_istream_char_get_basic_ios(this);
7917 basic_ios_char_ctor(base
);
7919 base
= basic_istream_char_get_basic_ios(this);
7922 base
->base
.vtable
= &MSVCP_basic_istream_char_vtable
;
7923 ios_base_Addstd(&base
->base
);
7927 /* ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UAE@XZ */
7928 /* ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
7929 DEFINE_THISCALL_WRAPPER(basic_istream_char_dtor
, 4)
7930 void __thiscall
basic_istream_char_dtor(basic_ios_char
*base
)
7932 basic_istream_char
*this = basic_istream_char_from_basic_ios(base
);
7934 /* don't destroy virtual base here */
7935 TRACE("(%p)\n", this);
7938 /* ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ */
7939 /* ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
7940 DEFINE_THISCALL_WRAPPER(basic_istream_char_vbase_dtor
, 4)
7941 void __thiscall
basic_istream_char_vbase_dtor(basic_istream_char
*this)
7943 TRACE("(%p)\n", this);
7944 basic_istream_char_dtor(basic_istream_char_to_basic_ios(this));
7945 basic_ios_char_dtor(basic_istream_char_get_basic_ios(this));
7948 DEFINE_THISCALL_WRAPPER(basic_istream_char_vector_dtor
, 8)
7949 basic_istream_char
* __thiscall
basic_istream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
7951 basic_istream_char
*this = basic_istream_char_from_basic_ios(base
);
7953 TRACE("(%p %x)\n", this, flags
);
7956 /* we have an array, with the number of elements stored before the first object */
7957 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
7959 for(i
=*ptr
-1; i
>=0; i
--)
7960 basic_istream_char_vbase_dtor(this+i
);
7961 MSVCRT_operator_delete(ptr
);
7963 basic_istream_char_vbase_dtor(this);
7965 MSVCRT_operator_delete(this);
7971 /* ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z */
7972 /* ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z */
7973 DEFINE_THISCALL_WRAPPER(basic_istream_char__Ipfx
, 8)
7974 MSVCP_bool __thiscall
basic_istream_char__Ipfx(basic_istream_char
*this, MSVCP_bool noskip
)
7976 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
7978 TRACE("(%p %d)\n", this, noskip
);
7980 if(ios_base_good(&base
->base
)) {
7981 if(basic_ios_char_tie_get(base
))
7982 basic_ostream_char_flush(basic_ios_char_tie_get(base
));
7984 if(!noskip
&& (ios_base_flags_get(&base
->base
) & FMTFLAG_skipws
)) {
7985 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
7986 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(base
->strbuf
));
7989 for(ch
= basic_streambuf_char_sgetc(strbuf
); ;
7990 ch
= basic_streambuf_char_snextc(strbuf
)) {
7992 basic_ios_char_setstate(base
, IOSTATE_eofbit
);
7996 if(!ctype_char_is_ch(ctype
, _SPACE
|_BLANK
, ch
))
8002 if(!ios_base_good(&base
->base
)) {
8003 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8010 /* ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z */
8011 /* ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z */
8012 DEFINE_THISCALL_WRAPPER(basic_istream_char_ipfx
, 8)
8013 MSVCP_bool __thiscall
basic_istream_char_ipfx(basic_istream_char
*this, MSVCP_bool noskip
)
8015 return basic_istream_char__Ipfx(this, noskip
);
8018 /* ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ */
8019 /* ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
8020 DEFINE_THISCALL_WRAPPER(basic_istream_char_isfx
, 4)
8021 void __thiscall
basic_istream_char_isfx(basic_istream_char
*this)
8023 TRACE("(%p)\n", this);
8026 static BOOL
basic_istream_char_sentry_create(basic_istream_char
*istr
, MSVCP_bool noskip
)
8028 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istr
);
8030 if(basic_ios_char_rdbuf_get(base
))
8031 call_basic_streambuf_char__Lock(base
->strbuf
);
8033 return basic_istream_char_ipfx(istr
, noskip
);
8036 static void basic_istream_char_sentry_destroy(basic_istream_char
*istr
)
8038 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istr
);
8040 if(basic_ios_char_rdbuf_get(base
))
8041 call_basic_streambuf_char__Unlock(base
->strbuf
);
8044 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBEHXZ */
8045 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QEBA_JXZ */
8046 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBA_JXZ */
8047 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBE_JXZ */
8048 DEFINE_THISCALL_WRAPPER(basic_istream_char_gcount
, 4)
8049 streamsize __thiscall
basic_istream_char_gcount(const basic_istream_char
*this)
8051 TRACE("(%p)\n", this);
8055 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
8056 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
8057 DEFINE_THISCALL_WRAPPER(basic_istream_char_get
, 4)
8058 int __thiscall
basic_istream_char_get(basic_istream_char
*this)
8060 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8063 TRACE("(%p)\n", this);
8067 if(!basic_istream_char_sentry_create(this, TRUE
)) {
8068 basic_istream_char_sentry_destroy(this);
8072 ret
= basic_streambuf_char_sbumpc(basic_ios_char_rdbuf_get(base
));
8073 basic_istream_char_sentry_destroy(this);
8075 basic_ios_char_setstate(base
, IOSTATE_eofbit
|IOSTATE_failbit
);
8082 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAD@Z */
8083 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAD@Z */
8084 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_ch
, 8)
8085 basic_istream_char
* __thiscall
basic_istream_char_get_ch(basic_istream_char
*this, char *ch
)
8089 TRACE("(%p %p)\n", this, ch
);
8091 ret
= basic_istream_char_get(this);
8097 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADHD@Z */
8098 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z */
8099 #if STREAMSIZE_BITS == 64
8100 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str_delim
, 20)
8102 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str_delim
, 16)
8104 basic_istream_char
* __thiscall
basic_istream_char_get_str_delim(basic_istream_char
*this, char *str
, streamsize count
, char delim
)
8106 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8109 TRACE("(%p %p %s %c)\n", this, str
, wine_dbgstr_longlong(count
), delim
);
8113 if(basic_istream_char_sentry_create(this, TRUE
)) {
8114 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8116 for(ch
= basic_streambuf_char_sgetc(strbuf
); count
>1;
8117 ch
= basic_streambuf_char_snextc(strbuf
)) {
8118 if(ch
==EOF
|| ch
==delim
)
8126 basic_istream_char_sentry_destroy(this);
8128 basic_ios_char_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
8129 (ch
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
8135 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
8136 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
8137 #if STREAMSIZE_BITS == 64
8138 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str
, 16)
8140 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str
, 12)
8142 basic_istream_char
* __thiscall
basic_istream_char_get_str(basic_istream_char
*this, char *str
, streamsize count
)
8144 return basic_istream_char_get_str_delim(this, str
, count
, '\n');
8147 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z */
8148 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z */
8149 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_streambuf_delim
, 12)
8150 basic_istream_char
* __thiscall
basic_istream_char_get_streambuf_delim(basic_istream_char
*this, basic_streambuf_char
*strbuf
, char delim
)
8152 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8155 TRACE("(%p %p %c)\n", this, strbuf
, delim
);
8159 if(basic_istream_char_sentry_create(this, TRUE
)) {
8160 basic_streambuf_char
*strbuf_read
= basic_ios_char_rdbuf_get(base
);
8162 for(ch
= basic_streambuf_char_sgetc(strbuf_read
); ;
8163 ch
= basic_streambuf_char_snextc(strbuf_read
)) {
8164 if(ch
==EOF
|| ch
==delim
)
8167 if(basic_streambuf_char_sputc(strbuf
, ch
) == EOF
)
8172 basic_istream_char_sentry_destroy(this);
8174 basic_ios_char_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
8175 (ch
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
8179 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z */
8180 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z */
8181 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_streambuf
, 8)
8182 basic_istream_char
* __thiscall
basic_istream_char_get_streambuf(basic_istream_char
*this, basic_streambuf_char
*strbuf
)
8184 return basic_istream_char_get_streambuf_delim(this, strbuf
, '\n');
8187 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADHD@Z */
8188 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z */
8189 #if STREAMSIZE_BITS == 64
8190 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline_delim
, 20)
8192 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline_delim
, 16)
8194 basic_istream_char
* __thiscall
basic_istream_char_getline_delim(basic_istream_char
*this, char *str
, streamsize count
, char delim
)
8196 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8197 int ch
= (unsigned char)delim
;
8199 TRACE("(%p %p %s %c)\n", this, str
, wine_dbgstr_longlong(count
), delim
);
8203 if(basic_istream_char_sentry_create(this, TRUE
) && count
>0) {
8204 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8207 ch
= basic_streambuf_char_sbumpc(strbuf
);
8209 if(ch
==EOF
|| ch
==(unsigned char)delim
)
8217 if(ch
== (unsigned char)delim
)
8219 else if(ch
!= EOF
) {
8220 ch
= basic_streambuf_char_sgetc(strbuf
);
8222 if(ch
== (unsigned char)delim
) {
8223 basic_streambuf_char__Gninc(strbuf
);
8228 basic_istream_char_sentry_destroy(this);
8230 basic_ios_char_setstate(base
, (ch
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
) |
8231 (!this->count
|| (ch
!=(unsigned char)delim
&& ch
!=EOF
) ? IOSTATE_failbit
: IOSTATE_goodbit
));
8237 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
8238 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
8239 #if STREAMSIZE_BITS == 64
8240 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline
, 16)
8242 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline
, 12)
8244 basic_istream_char
* __thiscall
basic_istream_char_getline(basic_istream_char
*this, char *str
, streamsize count
)
8246 return basic_istream_char_getline_delim(this, str
, count
, '\n');
8249 /* ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@HH@Z */
8250 /* ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
8251 #if STREAMSIZE_BITS == 64
8252 DEFINE_THISCALL_WRAPPER(basic_istream_char_ignore
, 16)
8254 DEFINE_THISCALL_WRAPPER(basic_istream_char_ignore
, 12)
8256 basic_istream_char
* __thiscall
basic_istream_char_ignore(basic_istream_char
*this, streamsize count
, int delim
)
8258 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8259 int ch
= (unsigned char)delim
;
8262 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(count
), delim
);
8266 if(basic_istream_char_sentry_create(this, TRUE
)) {
8267 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8268 state
= IOSTATE_goodbit
;
8271 ch
= basic_streambuf_char_sbumpc(strbuf
);
8274 state
= IOSTATE_eofbit
;
8278 if(ch
==(unsigned char)delim
)
8282 if(count
!= INT_MAX
)
8286 state
= IOSTATE_failbit
;
8287 basic_istream_char_sentry_destroy(this);
8289 basic_ios_char_setstate(base
, state
);
8293 /* ?ws@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@1@AAV21@@Z */
8294 /* ?ws@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
8295 basic_istream_char
* __cdecl
ws_basic_istream_char(basic_istream_char
*istream
)
8297 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
8300 TRACE("(%p)\n", istream
);
8302 if(basic_istream_char_sentry_create(istream
, TRUE
)) {
8303 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8304 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(strbuf
));
8306 for(ch
= basic_streambuf_char_sgetc(strbuf
); ctype_char_is_ch(ctype
, _SPACE
, ch
);
8307 ch
= basic_streambuf_char_snextc(strbuf
)) {
8312 basic_istream_char_sentry_destroy(istream
);
8315 basic_ios_char_setstate(base
, IOSTATE_eofbit
);
8319 /* ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
8320 /* ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
8321 DEFINE_THISCALL_WRAPPER(basic_istream_char_peek
, 4)
8322 int __thiscall
basic_istream_char_peek(basic_istream_char
*this)
8324 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8327 TRACE("(%p)\n", this);
8331 if(basic_istream_char_sentry_create(this, TRUE
))
8332 ret
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
));
8333 basic_istream_char_sentry_destroy(this);
8336 basic_ios_char_setstate(base
, IOSTATE_eofbit
);
8341 /* ?_Read_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADIH@Z */
8342 /* ?_Read_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_K_J@Z */
8343 #if STREAMSIZE_BITS == 64
8344 DEFINE_THISCALL_WRAPPER(basic_istream_char__Read_s
, 20)
8346 DEFINE_THISCALL_WRAPPER(basic_istream_char__Read_s
, 16)
8348 basic_istream_char
* __thiscall
basic_istream_char__Read_s(basic_istream_char
*this, char *str
, MSVCP_size_t size
, streamsize count
)
8350 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8351 IOSB_iostate state
= IOSTATE_goodbit
;
8353 TRACE("(%p %p %lu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
8355 if(basic_istream_char_sentry_create(this, TRUE
)) {
8356 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8358 this->count
= basic_streambuf_char__Sgetn_s(strbuf
, str
, size
, count
);
8359 if(this->count
!= count
)
8360 state
|= IOSTATE_failbit
| IOSTATE_eofbit
;
8364 basic_istream_char_sentry_destroy(this);
8366 basic_ios_char_setstate(base
, state
);
8370 /* ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
8371 /* ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
8372 #if STREAMSIZE_BITS == 64
8373 DEFINE_THISCALL_WRAPPER(basic_istream_char_read
, 16)
8375 DEFINE_THISCALL_WRAPPER(basic_istream_char_read
, 12)
8377 basic_istream_char
* __thiscall
basic_istream_char_read(basic_istream_char
*this, char *str
, streamsize count
)
8379 return basic_istream_char__Read_s(this, str
, -1, count
);
8382 /* ?_Readsome_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHPADIH@Z */
8383 /* ?_Readsome_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_K_J@Z */
8384 #if STREAMSIZE_BITS == 64
8385 DEFINE_THISCALL_WRAPPER(basic_istream_char__Readsome_s
, 20)
8387 DEFINE_THISCALL_WRAPPER(basic_istream_char__Readsome_s
, 16)
8389 streamsize __thiscall
basic_istream_char__Readsome_s(basic_istream_char
*this, char *str
, MSVCP_size_t size
, streamsize count
)
8391 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8392 IOSB_iostate state
= IOSTATE_goodbit
;
8394 TRACE("(%p %p %lu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
8398 if(basic_istream_char_sentry_create(this, TRUE
)) {
8399 streamsize avail
= basic_streambuf_char_in_avail(basic_ios_char_rdbuf_get(base
));
8404 state
|= IOSTATE_eofbit
;
8406 basic_istream_char__Read_s(this, str
, size
, avail
);
8408 state
|= IOSTATE_failbit
;
8410 basic_istream_char_sentry_destroy(this);
8412 basic_ios_char_setstate(base
, state
);
8416 /* ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHPADH@Z */
8417 /* ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z */
8418 #if STREAMSIZE_BITS == 64
8419 DEFINE_THISCALL_WRAPPER(basic_istream_char_readsome
, 16)
8421 DEFINE_THISCALL_WRAPPER(basic_istream_char_readsome
, 12)
8423 streamsize __thiscall
basic_istream_char_readsome(basic_istream_char
*this, char *str
, streamsize count
)
8425 return basic_istream_char__Readsome_s(this, str
, count
, count
);
8428 /* ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z */
8429 /* ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z */
8430 DEFINE_THISCALL_WRAPPER(basic_istream_char_putback
, 8)
8431 basic_istream_char
* __thiscall
basic_istream_char_putback(basic_istream_char
*this, char ch
)
8433 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8434 IOSB_iostate state
= IOSTATE_goodbit
;
8436 TRACE("(%p %c)\n", this, ch
);
8440 if(basic_istream_char_sentry_create(this, TRUE
)) {
8441 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8443 if(!ios_base_good(&base
->base
))
8444 state
|= IOSTATE_failbit
;
8445 else if(!strbuf
|| basic_streambuf_char_sputbackc(strbuf
, ch
)==EOF
)
8446 state
|= IOSTATE_badbit
;
8448 basic_istream_char_sentry_destroy(this);
8450 basic_ios_char_setstate(base
, state
);
8454 /* ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ */
8455 /* ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ */
8456 DEFINE_THISCALL_WRAPPER(basic_istream_char_unget
, 4)
8457 basic_istream_char
* __thiscall
basic_istream_char_unget(basic_istream_char
*this)
8459 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8460 IOSB_iostate state
= IOSTATE_goodbit
;
8462 TRACE("(%p)\n", this);
8466 if(basic_istream_char_sentry_create(this, TRUE
)) {
8467 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8469 if(!ios_base_good(&base
->base
))
8470 state
|= IOSTATE_failbit
;
8471 else if(!strbuf
|| basic_streambuf_char_sungetc(strbuf
)==EOF
)
8472 state
|= IOSTATE_badbit
;
8474 basic_istream_char_sentry_destroy(this);
8476 basic_ios_char_setstate(base
, state
);
8480 /* ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
8481 /* ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
8482 DEFINE_THISCALL_WRAPPER(basic_istream_char_sync
, 4)
8483 int __thiscall
basic_istream_char_sync(basic_istream_char
*this)
8485 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8486 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8488 TRACE("(%p)\n", this);
8493 if(basic_istream_char_sentry_create(this, TRUE
)) {
8494 if(basic_streambuf_char_pubsync(strbuf
) != -1) {
8495 basic_istream_char_sentry_destroy(this);
8499 basic_istream_char_sentry_destroy(this);
8501 basic_ios_char_setstate(base
, IOSTATE_badbit
);
8505 /* ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ */
8506 /* ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
8507 DEFINE_THISCALL_WRAPPER(basic_istream_char_tellg
, 8)
8508 fpos_int
* __thiscall
basic_istream_char_tellg(basic_istream_char
*this, fpos_int
*ret
)
8510 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8512 TRACE("(%p %p)\n", this, ret
);
8514 if(ios_base_fail(&base
->base
)) {
8521 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
8522 ret
, 0, SEEKDIR_cur
, OPENMODE_in
);
8524 if(ret
->off
==-1 && ret
->pos
==0 && ret
->state
==0)
8525 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8530 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@JW4seekdir@ios_base@2@@Z */
8531 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JW4seekdir@ios_base@2@@Z */
8532 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@JH@Z */
8533 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
8534 #if STREAMOFF_BITS == 64
8535 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg
, 16)
8537 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg
, 12)
8539 basic_istream_char
* __thiscall
basic_istream_char_seekg(basic_istream_char
*this, streamoff off
, int dir
)
8541 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8543 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), dir
);
8545 if(!ios_base_fail(&base
->base
)) {
8546 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8549 basic_streambuf_char_pubseekoff(strbuf
, &ret
, off
, dir
, OPENMODE_in
);
8551 if(ret
.off
==-1 && ret
.pos
==0 && ret
.state
==0)
8552 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8554 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8557 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8562 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
8563 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
8564 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg_fpos
, 28)
8565 basic_istream_char
* __thiscall
basic_istream_char_seekg_fpos(basic_istream_char
*this, fpos_int pos
)
8567 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8569 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos
));
8571 if(!ios_base_fail(&base
->base
)) {
8572 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8575 basic_streambuf_char_pubseekpos(strbuf
, &ret
, pos
, OPENMODE_in
);
8577 if(ret
.off
==-1 && ret
.pos
==0 && ret
.state
==0)
8578 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8580 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8583 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8588 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAF@Z */
8589 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAF@Z */
8590 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_short
, 8)
8591 basic_istream_char
* __thiscall
basic_istream_char_read_short(basic_istream_char
*this, short *v
)
8593 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8594 int state
= IOSTATE_goodbit
;
8596 TRACE("(%p %p)\n", this, v
);
8598 if(basic_istream_char_sentry_create(this, FALSE
)) {
8599 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8600 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8601 istreambuf_iterator_char first
={0}, last
={0};
8604 first
.strbuf
= strbuf
;
8605 num_get_char_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, &tmp
);
8607 if(!(state
&IOSTATE_failbit
) && tmp
==(LONG
)((short)tmp
))
8610 state
|= IOSTATE_failbit
;
8612 basic_istream_char_sentry_destroy(this);
8614 basic_ios_char_setstate(base
, state
);
8618 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAG@Z */
8619 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAG@Z */
8620 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ushort
, 8)
8621 basic_istream_char
* __thiscall
basic_istream_char_read_ushort(basic_istream_char
*this, unsigned short *v
)
8623 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8624 int state
= IOSTATE_goodbit
;
8626 TRACE("(%p %p)\n", this, v
);
8628 if(basic_istream_char_sentry_create(this, FALSE
)) {
8629 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8630 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8631 istreambuf_iterator_char first
={0}, last
={0};
8633 first
.strbuf
= strbuf
;
8634 num_get_char_get_ushort(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8636 basic_istream_char_sentry_destroy(this);
8638 basic_ios_char_setstate(base
, state
);
8642 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAH@Z */
8643 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAH@Z */
8644 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_int
, 8)
8645 basic_istream_char
* __thiscall
basic_istream_char_read_int(basic_istream_char
*this, int *v
)
8647 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8648 int state
= IOSTATE_goodbit
;
8650 TRACE("(%p %p)\n", this, v
);
8652 if(basic_istream_char_sentry_create(this, FALSE
)) {
8653 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8654 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8655 istreambuf_iterator_char first
={0}, last
={0};
8657 first
.strbuf
= strbuf
;
8658 num_get_char_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8660 basic_istream_char_sentry_destroy(this);
8662 basic_ios_char_setstate(base
, state
);
8666 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAI@Z */
8667 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAI@Z */
8668 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_uint
, 8)
8669 basic_istream_char
* __thiscall
basic_istream_char_read_uint(basic_istream_char
*this, unsigned int *v
)
8671 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8672 int state
= IOSTATE_goodbit
;
8674 TRACE("(%p %p)\n", this, v
);
8676 if(basic_istream_char_sentry_create(this, FALSE
)) {
8677 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8678 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8679 istreambuf_iterator_char first
={0}, last
={0};
8681 first
.strbuf
= strbuf
;
8682 num_get_char_get_uint(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8684 basic_istream_char_sentry_destroy(this);
8686 basic_ios_char_setstate(base
, state
);
8690 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAJ@Z */
8691 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAJ@Z */
8692 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_long
, 8)
8693 basic_istream_char
* __thiscall
basic_istream_char_read_long(basic_istream_char
*this, LONG
*v
)
8695 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8696 int state
= IOSTATE_goodbit
;
8698 TRACE("(%p %p)\n", this, v
);
8700 if(basic_istream_char_sentry_create(this, FALSE
)) {
8701 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8702 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8703 istreambuf_iterator_char first
={0}, last
={0};
8705 first
.strbuf
= strbuf
;
8706 num_get_char_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8708 basic_istream_char_sentry_destroy(this);
8710 basic_ios_char_setstate(base
, state
);
8714 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAK@Z */
8715 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAK@Z */
8716 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ulong
, 8)
8717 basic_istream_char
* __thiscall
basic_istream_char_read_ulong(basic_istream_char
*this, ULONG
*v
)
8719 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8720 int state
= IOSTATE_goodbit
;
8722 TRACE("(%p %p)\n", this, v
);
8724 if(basic_istream_char_sentry_create(this, FALSE
)) {
8725 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8726 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8727 istreambuf_iterator_char first
={0}, last
={0};
8729 first
.strbuf
= strbuf
;
8730 num_get_char_get_ulong(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8732 basic_istream_char_sentry_destroy(this);
8734 basic_ios_char_setstate(base
, state
);
8738 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAM@Z */
8739 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAM@Z */
8740 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_float
, 8)
8741 basic_istream_char
* __thiscall
basic_istream_char_read_float(basic_istream_char
*this, float *v
)
8743 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8744 int state
= IOSTATE_goodbit
;
8746 TRACE("(%p %p)\n", this, v
);
8748 if(basic_istream_char_sentry_create(this, FALSE
)) {
8749 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8750 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8751 istreambuf_iterator_char first
={0}, last
={0};
8753 first
.strbuf
= strbuf
;
8754 num_get_char_get_float(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8756 basic_istream_char_sentry_destroy(this);
8758 basic_ios_char_setstate(base
, state
);
8762 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAN@Z */
8763 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAN@Z */
8764 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_double
, 8)
8765 basic_istream_char
* __thiscall
basic_istream_char_read_double(basic_istream_char
*this, double *v
)
8767 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8768 int state
= IOSTATE_goodbit
;
8770 TRACE("(%p %p)\n", this, v
);
8772 if(basic_istream_char_sentry_create(this, FALSE
)) {
8773 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8774 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8775 istreambuf_iterator_char first
={0}, last
={0};
8777 first
.strbuf
= strbuf
;
8778 num_get_char_get_double(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8780 basic_istream_char_sentry_destroy(this);
8782 basic_ios_char_setstate(base
, state
);
8786 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAO@Z */
8787 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAO@Z */
8788 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ldouble
, 8)
8789 basic_istream_char
* __thiscall
basic_istream_char_read_ldouble(basic_istream_char
*this, double *v
)
8791 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8792 int state
= IOSTATE_goodbit
;
8794 TRACE("(%p %p)\n", this, v
);
8796 if(basic_istream_char_sentry_create(this, FALSE
)) {
8797 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8798 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8799 istreambuf_iterator_char first
={0}, last
={0};
8801 first
.strbuf
= strbuf
;
8802 num_get_char_get_ldouble(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8804 basic_istream_char_sentry_destroy(this);
8806 basic_ios_char_setstate(base
, state
);
8810 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAPAX@Z */
8811 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
8812 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ptr
, 8)
8813 basic_istream_char
* __thiscall
basic_istream_char_read_ptr(basic_istream_char
*this, void **v
)
8815 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8816 int state
= IOSTATE_goodbit
;
8818 TRACE("(%p %p)\n", this, v
);
8820 if(basic_istream_char_sentry_create(this, FALSE
)) {
8821 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8822 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8823 istreambuf_iterator_char first
={0}, last
={0};
8825 first
.strbuf
= strbuf
;
8826 num_get_char_get_void(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8828 basic_istream_char_sentry_destroy(this);
8830 basic_ios_char_setstate(base
, state
);
8834 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_J@Z */
8835 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_J@Z */
8836 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_int64
, 8)
8837 basic_istream_char
* __thiscall
basic_istream_char_read_int64(basic_istream_char
*this, __int64
*v
)
8839 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8840 int state
= IOSTATE_goodbit
;
8842 TRACE("(%p %p)\n", this, v
);
8844 if(basic_istream_char_sentry_create(this, FALSE
)) {
8845 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8846 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8847 istreambuf_iterator_char first
={0}, last
={0};
8849 first
.strbuf
= strbuf
;
8850 num_get_char_get_int64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8852 basic_istream_char_sentry_destroy(this);
8854 basic_ios_char_setstate(base
, state
);
8858 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_K@Z */
8859 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_K@Z */
8860 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_uint64
, 8)
8861 basic_istream_char
* __thiscall
basic_istream_char_read_uint64(basic_istream_char
*this, unsigned __int64
*v
)
8863 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8864 int state
= IOSTATE_goodbit
;
8866 TRACE("(%p %p)\n", this, v
);
8868 if(basic_istream_char_sentry_create(this, FALSE
)) {
8869 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8870 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8871 istreambuf_iterator_char first
={0}, last
={0};
8873 first
.strbuf
= strbuf
;
8874 num_get_char_get_uint64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8876 basic_istream_char_sentry_destroy(this);
8878 basic_ios_char_setstate(base
, state
);
8882 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_N@Z */
8883 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_N@Z */
8884 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_bool
, 8)
8885 basic_istream_char
* __thiscall
basic_istream_char_read_bool(basic_istream_char
*this, MSVCP_bool
*v
)
8887 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8888 int state
= IOSTATE_goodbit
;
8890 TRACE("(%p %p)\n", this, v
);
8892 if(basic_istream_char_sentry_create(this, FALSE
)) {
8893 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8894 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8895 istreambuf_iterator_char first
={0}, last
={0};
8897 first
.strbuf
= strbuf
;
8898 num_get_char_get_bool(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8900 basic_istream_char_sentry_destroy(this);
8902 basic_ios_char_setstate(base
, state
);
8906 /* ??$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 */
8907 /* ??$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 */
8908 basic_istream_char
* __cdecl
basic_istream_char_getline_bstr_delim(
8909 basic_istream_char
*istream
, basic_string_char
*str
, char delim
)
8911 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
8912 IOSB_iostate state
= IOSTATE_goodbit
;
8913 int c
= (unsigned char)delim
;
8915 TRACE("(%p %p %c)\n", istream
, str
, delim
);
8917 if(basic_istream_char_sentry_create(istream
, TRUE
)) {
8918 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8919 MSVCP_basic_string_char_clear(str
);
8921 c
= basic_streambuf_char_sgetc(strbuf
);
8922 for(; c
!=(unsigned char)delim
&& c
!=EOF
; c
= basic_streambuf_char_snextc(strbuf
))
8923 MSVCP_basic_string_char_append_ch(str
, c
);
8924 if(c
==EOF
) state
|= IOSTATE_eofbit
;
8925 else if(c
==(unsigned char)delim
) basic_streambuf_char_sbumpc(strbuf
);
8927 if(!MSVCP_basic_string_char_length(str
) && c
!=(unsigned char)delim
) state
|= IOSTATE_failbit
;
8929 basic_istream_char_sentry_destroy(istream
);
8931 basic_ios_char_setstate(basic_istream_char_get_basic_ios(istream
), state
);
8935 /* ??$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 */
8936 /* ??$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 */
8937 basic_istream_char
* __cdecl
basic_istream_char_getline_bstr(
8938 basic_istream_char
*istream
, basic_string_char
*str
)
8940 return basic_istream_char_getline_bstr_delim(istream
, str
, '\n');
8943 /* ??$?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 */
8944 /* ??$?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 */
8945 basic_istream_char
* __cdecl
basic_istream_char_read_bstr(
8946 basic_istream_char
*istream
, basic_string_char
*str
)
8948 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
8949 IOSB_iostate state
= IOSTATE_failbit
;
8952 TRACE("(%p %p)\n", istream
, str
);
8954 if(basic_istream_char_sentry_create(istream
, FALSE
)) {
8955 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(base
->strbuf
));
8956 MSVCP_size_t count
= ios_base_width_get(&base
->base
);
8961 MSVCP_basic_string_char_clear(str
);
8963 for(c
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
));
8964 c
!=EOF
&& !ctype_char_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
8965 c
= basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base
)), count
--) {
8966 state
= IOSTATE_goodbit
;
8967 MSVCP_basic_string_char_append_ch(str
, c
);
8970 basic_istream_char_sentry_destroy(istream
);
8972 ios_base_width_set(&base
->base
, 0);
8973 basic_ios_char_setstate(base
, state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
8977 /* ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAD@Z */
8978 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAD@Z */
8979 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAC@Z */
8980 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAC@Z */
8981 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAE@Z */
8982 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAE@Z */
8983 basic_istream_char
* __cdecl
basic_istream_char_read_str(basic_istream_char
*istream
, char *str
)
8985 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
8986 IOSB_iostate state
= IOSTATE_failbit
;
8989 TRACE("(%p %p)\n", istream
, str
);
8991 if(basic_istream_char_sentry_create(istream
, FALSE
)) {
8992 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(base
->strbuf
));
8993 MSVCP_size_t count
= ios_base_width_get(&base
->base
)-1;
8995 for(c
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
));
8996 c
!=EOF
&& !ctype_char_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
8997 c
= basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base
)), count
--) {
8998 state
= IOSTATE_goodbit
;
9002 basic_istream_char_sentry_destroy(istream
);
9005 ios_base_width_set(&base
->base
, 0);
9006 basic_ios_char_setstate(base
, state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9010 /* ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAD@Z */
9011 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAD@Z */
9012 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAC@Z */
9013 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAC@Z */
9014 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAE@Z */
9015 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAE@Z */
9016 basic_istream_char
* __cdecl
basic_istream_char_read_ch(basic_istream_char
*istream
, char *ch
)
9018 IOSB_iostate state
= IOSTATE_failbit
;
9021 TRACE("(%p %p)\n", istream
, ch
);
9023 if(basic_istream_char_sentry_create(istream
, FALSE
)) {
9024 c
= basic_streambuf_char_sbumpc(basic_ios_char_rdbuf_get(
9025 basic_istream_char_get_basic_ios(istream
)));
9027 state
= IOSTATE_goodbit
;
9031 basic_istream_char_sentry_destroy(istream
);
9033 basic_ios_char_setstate(basic_istream_char_get_basic_ios(istream
),
9034 state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9038 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
9039 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
9040 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_streambuf
, 8)
9041 basic_istream_char
* __thiscall
basic_istream_char_read_streambuf(
9042 basic_istream_char
*this, basic_streambuf_char
*streambuf
)
9044 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9045 IOSB_iostate state
= IOSTATE_failbit
;
9048 TRACE("(%p %p)\n", this, streambuf
);
9050 if(basic_istream_char_sentry_create(this, FALSE
)) {
9051 for(c
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
)); c
!=EOF
;
9052 c
= basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base
))) {
9053 state
= IOSTATE_goodbit
;
9054 if(basic_streambuf_char_sputc(streambuf
, c
) == EOF
)
9058 basic_istream_char_sentry_destroy(this);
9060 basic_ios_char_setstate(base
, state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9064 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
9065 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
9066 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func
, 8)
9067 basic_istream_char
* __thiscall
basic_istream_char_read_func(basic_istream_char
*this,
9068 basic_istream_char
* (__cdecl
*pfunc
)(basic_istream_char
*))
9070 TRACE("(%p %p)\n", this, pfunc
);
9075 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z */
9076 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z */
9077 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func_basic_ios
, 8)
9078 basic_istream_char
* __thiscall
basic_istream_char_read_func_basic_ios(basic_istream_char
*this,
9079 basic_ios_char
* (__cdecl
*pfunc
)(basic_ios_char
*))
9081 TRACE("(%p %p)\n", this, pfunc
);
9082 pfunc(basic_istream_char_get_basic_ios(this));
9086 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
9087 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
9088 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func_ios_base
, 8)
9089 basic_istream_char
* __thiscall
basic_istream_char_read_func_ios_base(basic_istream_char
*this,
9090 ios_base
* (__cdecl
*pfunc
)(ios_base
*))
9092 TRACE("(%p %p)\n", this, pfunc
);
9093 pfunc(&basic_istream_char_get_basic_ios(this)->base
);
9097 /* ??$?5MDU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$complex@M@0@@Z */
9098 /* ??$?5MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$complex@M@0@@Z */
9099 basic_istream_char
* __cdecl
basic_istream_char_read_complex_float(basic_istream_char
*this, complex_float
*v
)
9102 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9104 TRACE("(%p %p)\n", this, v
);
9106 ws_basic_istream_char(this);
9107 if(basic_istream_char_peek(this) == '(') {
9109 basic_istream_char_get(this);
9110 basic_istream_char_read_float(this, &r
);
9112 if(ios_base_fail(&base
->base
))
9115 ws_basic_istream_char(this);
9116 c
= basic_istream_char_peek(this);
9119 basic_istream_char_get(this);
9120 basic_istream_char_read_float(this, &i
);
9122 if(ios_base_fail(&base
->base
))
9125 ws_basic_istream_char(this);
9126 c
= basic_istream_char_peek(this);
9127 if(c
== ')') { /* supported format: (real, imag) */
9128 basic_istream_char_get(this);
9132 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9135 }else if(c
== ')') { /* supported format: (real) */
9136 basic_istream_char_get(this);
9140 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9143 }else { /* supported format: real */
9144 basic_istream_char_read_float(this, &r
);
9146 if(ios_base_fail(&base
->base
))
9156 /* ??$?5NDU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$complex@N@0@@Z */
9157 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$complex@N@0@@Z */
9158 basic_istream_char
* __cdecl
basic_istream_char_read_complex_double(basic_istream_char
*this, complex_double
*v
)
9161 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9163 TRACE("(%p %p)\n", this, v
);
9165 ws_basic_istream_char(this);
9166 if(basic_istream_char_peek(this) == '(') {
9168 basic_istream_char_get(this);
9169 basic_istream_char_read_double(this, &r
);
9171 if(ios_base_fail(&base
->base
))
9174 ws_basic_istream_char(this);
9175 c
= basic_istream_char_peek(this);
9178 basic_istream_char_get(this);
9179 basic_istream_char_read_double(this, &i
);
9181 if(ios_base_fail(&base
->base
))
9184 ws_basic_istream_char(this);
9185 c
= basic_istream_char_peek(this);
9186 if(c
== ')') { /* supported format: (real, imag) */
9187 basic_istream_char_get(this);
9191 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9194 }else if(c
== ')') { /* supported format: (real) */
9195 basic_istream_char_get(this);
9199 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9202 }else { /* supported format: real */
9203 basic_istream_char_read_double(this, &r
);
9205 if(ios_base_fail(&base
->base
))
9215 /* ??$?5ODU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$complex@O@0@@Z */
9216 /* ??$?5ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$complex@O@0@@Z */
9217 basic_istream_char
* __cdecl
basic_istream_char_read_complex_ldouble(basic_istream_char
*this, complex_double
*v
)
9220 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9222 TRACE("(%p %p)\n", this, v
);
9224 ws_basic_istream_char(this);
9225 if(basic_istream_char_peek(this) == '(') {
9227 basic_istream_char_get(this);
9228 basic_istream_char_read_ldouble(this, &r
);
9230 if(ios_base_fail(&base
->base
))
9233 ws_basic_istream_char(this);
9234 c
= basic_istream_char_peek(this);
9237 basic_istream_char_get(this);
9238 basic_istream_char_read_ldouble(this, &i
);
9240 if(ios_base_fail(&base
->base
))
9243 ws_basic_istream_char(this);
9244 c
= basic_istream_char_peek(this);
9245 if(c
== ')') { /* supported format: (real, imag) */
9246 basic_istream_char_get(this);
9250 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9253 }else if(c
== ')') { /* supported format: (real) */
9254 basic_istream_char_get(this);
9258 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9261 }else { /* supported format: real */
9262 basic_istream_char_read_ldouble(this, &r
);
9264 if(ios_base_fail(&base
->base
))
9274 /* ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z */
9275 /* ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z */
9276 DEFINE_THISCALL_WRAPPER(basic_istream_char_swap
, 8)
9277 void __thiscall
basic_istream_char_swap(basic_istream_char
*this, basic_istream_char
*r
)
9279 TRACE("(%p %p)\n", this, r
);
9284 basic_ios_char_swap(basic_istream_char_get_basic_ios(this),
9285 basic_istream_char_get_basic_ios(r
));
9286 this->count
^= r
->count
;
9287 r
->count
^= this->count
;
9288 this->count
^= r
->count
;
9291 /* Caution: basic_istream uses virtual inheritance. */
9292 static inline basic_ios_wchar
* basic_istream_wchar_get_basic_ios(basic_istream_wchar
*this)
9294 return (basic_ios_wchar
*)((char*)this+this->vbtable
[1]);
9297 static inline basic_ios_wchar
* basic_istream_wchar_to_basic_ios(basic_istream_wchar
*ptr
)
9299 return (basic_ios_wchar
*)((char*)ptr
+basic_istream_wchar_vbtable
[1]);
9302 static inline basic_istream_wchar
* basic_istream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
9304 return (basic_istream_wchar
*)((char*)ptr
-basic_istream_wchar_vbtable
[1]);
9307 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z */
9308 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z */
9309 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor_init
, 20)
9310 basic_istream_wchar
* __thiscall
basic_istream_wchar_ctor_init(basic_istream_wchar
*this,
9311 basic_streambuf_wchar
*strbuf
, MSVCP_bool isstd
, MSVCP_bool noinit
, MSVCP_bool virt_init
)
9313 basic_ios_wchar
*base
;
9315 TRACE("(%p %p %d %d %d)\n", this, strbuf
, isstd
, noinit
, virt_init
);
9318 this->vbtable
= basic_istream_wchar_vbtable
;
9319 base
= basic_istream_wchar_get_basic_ios(this);
9320 basic_ios_wchar_ctor(base
);
9322 base
= basic_istream_wchar_get_basic_ios(this);
9325 base
->base
.vtable
= &MSVCP_basic_istream_wchar_vtable
;
9328 basic_ios_wchar_init(base
, strbuf
, isstd
);
9332 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z */
9333 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z */
9334 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor_init
, 20)
9335 basic_istream_wchar
* __thiscall
basic_istream_short_ctor_init(basic_istream_wchar
*this,
9336 basic_streambuf_wchar
*strbuf
, MSVCP_bool isstd
, MSVCP_bool noinit
, MSVCP_bool virt_init
)
9338 basic_istream_wchar_ctor_init(this, strbuf
, isstd
, noinit
, virt_init
);
9339 basic_istream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_istream_short_vtable
;
9343 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
9344 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
9345 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor
, 16)
9346 basic_istream_wchar
* __thiscall
basic_istream_wchar_ctor(basic_istream_wchar
*this,
9347 basic_streambuf_wchar
*strbuf
, MSVCP_bool isstd
, MSVCP_bool virt_init
)
9349 return basic_istream_wchar_ctor_init(this, strbuf
, isstd
, FALSE
, virt_init
);
9352 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
9353 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
9354 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor
, 16)
9355 basic_istream_wchar
* __thiscall
basic_istream_short_ctor(basic_istream_wchar
*this,
9356 basic_streambuf_wchar
*strbuf
, MSVCP_bool isstd
, MSVCP_bool virt_init
)
9358 return basic_istream_short_ctor_init(this, strbuf
, isstd
, FALSE
, virt_init
);
9361 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z */
9362 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
9363 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor_uninitialized
, 12)
9364 basic_istream_wchar
* __thiscall
basic_istream_wchar_ctor_uninitialized(
9365 basic_istream_wchar
*this, int uninitialized
, MSVCP_bool virt_init
)
9367 basic_ios_wchar
*base
;
9369 TRACE("(%p %d %d)\n", this, uninitialized
, virt_init
);
9372 this->vbtable
= basic_istream_wchar_vbtable
;
9373 base
= basic_istream_wchar_get_basic_ios(this);
9374 basic_ios_wchar_ctor(base
);
9376 base
= basic_istream_wchar_get_basic_ios(this);
9379 base
->base
.vtable
= &MSVCP_basic_istream_wchar_vtable
;
9380 ios_base_Addstd(&base
->base
);
9384 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z */
9385 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
9386 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor_uninitialized
, 12)
9387 basic_istream_wchar
* __thiscall
basic_istream_short_ctor_uninitialized(
9388 basic_istream_wchar
*this, int uninitialized
, MSVCP_bool virt_init
)
9390 basic_istream_wchar_ctor_uninitialized(this, uninitialized
, virt_init
);
9391 basic_istream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_istream_short_vtable
;
9395 /* ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
9396 /* ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
9397 /* ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UAE@XZ */
9398 /* ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
9399 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_dtor
, 4)
9400 void __thiscall
basic_istream_wchar_dtor(basic_ios_wchar
*base
)
9402 basic_istream_wchar
*this = basic_istream_wchar_from_basic_ios(base
);
9404 /* don't destroy virtual base here */
9405 TRACE("(%p)\n", this);
9408 /* ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
9409 /* ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
9410 /* ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ */
9411 /* ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
9412 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_vbase_dtor
, 4)
9413 void __thiscall
basic_istream_wchar_vbase_dtor(basic_istream_wchar
*this)
9415 TRACE("(%p)\n", this);
9416 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(this));
9417 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(this));
9420 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_vector_dtor
, 8)
9421 basic_istream_wchar
* __thiscall
basic_istream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
9423 basic_istream_wchar
*this = basic_istream_wchar_from_basic_ios(base
);
9425 TRACE("(%p %x)\n", this, flags
);
9428 /* we have an array, with the number of elements stored before the first object */
9429 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
9431 for(i
=*ptr
-1; i
>=0; i
--)
9432 basic_istream_wchar_vbase_dtor(this+i
);
9433 MSVCRT_operator_delete(ptr
);
9435 basic_istream_wchar_vbase_dtor(this);
9437 MSVCRT_operator_delete(this);
9443 /* ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z */
9444 /* ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z */
9445 /* ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z */
9446 /* ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z */
9447 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Ipfx
, 8)
9448 MSVCP_bool __thiscall
basic_istream_wchar__Ipfx(basic_istream_wchar
*this, MSVCP_bool noskip
)
9450 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9452 TRACE("(%p %d)\n", this, noskip
);
9454 if(ios_base_good(&base
->base
)) {
9455 if(basic_ios_wchar_tie_get(base
))
9456 basic_ostream_wchar_flush(basic_ios_wchar_tie_get(base
));
9458 if(!noskip
&& (ios_base_flags_get(&base
->base
) & FMTFLAG_skipws
)) {
9459 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9460 const ctype_wchar
*ctype
= ctype_wchar_use_facet(IOS_LOCALE(base
->strbuf
));
9463 for(ch
= basic_streambuf_wchar_sgetc(strbuf
); ;
9464 ch
= basic_streambuf_wchar_snextc(strbuf
)) {
9466 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
);
9470 if(!ctype_wchar_is_ch(ctype
, _SPACE
|_BLANK
, ch
))
9476 if(!ios_base_good(&base
->base
)) {
9477 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
9483 /* ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z */
9484 /* ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z */
9485 /* ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z */
9486 /* ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z */
9487 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ipfx
, 8)
9488 MSVCP_bool __thiscall
basic_istream_wchar_ipfx(basic_istream_wchar
*this, MSVCP_bool noskip
)
9490 return basic_istream_wchar__Ipfx(this, noskip
);
9493 /* ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
9494 /* ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
9495 /* ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ */
9496 /* ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
9497 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_isfx
, 4)
9498 void __thiscall
basic_istream_wchar_isfx(basic_istream_wchar
*this)
9500 TRACE("(%p)\n", this);
9503 static BOOL
basic_istream_wchar_sentry_create(basic_istream_wchar
*istr
, MSVCP_bool noskip
)
9505 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istr
);
9507 if(basic_ios_wchar_rdbuf_get(base
))
9508 basic_streambuf_wchar__Lock(base
->strbuf
);
9510 return basic_istream_wchar_ipfx(istr
, noskip
);
9513 static void basic_istream_wchar_sentry_destroy(basic_istream_wchar
*istr
)
9515 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istr
);
9517 if(basic_ios_wchar_rdbuf_get(base
))
9518 basic_streambuf_wchar__Unlock(base
->strbuf
);
9521 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBEHXZ */
9522 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEBA_JXZ */
9523 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBEHXZ */
9524 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QEBA_JXZ */
9525 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBA_JXZ */
9526 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBE_JXZ */
9527 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBA_JXZ */
9528 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBE_JXZ */
9529 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_gcount
, 4)
9530 streamsize __thiscall
basic_istream_wchar_gcount(const basic_istream_wchar
*this)
9532 TRACE("(%p)\n", this);
9536 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
9537 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
9538 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ */
9539 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ */
9540 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get
, 4)
9541 unsigned short __thiscall
basic_istream_wchar_get(basic_istream_wchar
*this)
9543 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9546 TRACE("(%p)\n", this);
9550 if(!basic_istream_wchar_sentry_create(this, TRUE
)) {
9551 basic_istream_wchar_sentry_destroy(this);
9555 ret
= basic_streambuf_wchar_sbumpc(basic_ios_wchar_rdbuf_get(base
));
9556 basic_istream_wchar_sentry_destroy(this);
9558 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
|IOSTATE_failbit
);
9565 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AA_W@Z */
9566 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEA_W@Z */
9567 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAG@Z */
9568 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAG@Z */
9569 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_ch
, 8)
9570 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_ch(basic_istream_wchar
*this, wchar_t *ch
)
9574 TRACE("(%p %p)\n", this, ch
);
9576 ret
= basic_istream_wchar_get(this);
9582 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH_W@Z */
9583 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z */
9584 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGHG@Z */
9585 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z */
9586 #if STREAMSIZE_BITS == 64
9587 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str_delim
, 20)
9589 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str_delim
, 16)
9591 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_str_delim(basic_istream_wchar
*this, wchar_t *str
, streamsize count
, wchar_t delim
)
9593 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9594 unsigned short ch
= delim
;
9596 TRACE("(%p %p %s %c)\n", this, str
, wine_dbgstr_longlong(count
), delim
);
9600 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9601 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9603 for(ch
= basic_streambuf_wchar_sgetc(strbuf
); count
>1;
9604 ch
= basic_streambuf_wchar_snextc(strbuf
)) {
9605 if(ch
==WEOF
|| ch
==delim
)
9613 basic_istream_wchar_sentry_destroy(this);
9615 basic_ios_wchar_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
9616 (ch
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9622 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
9623 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
9624 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
9625 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
9626 #if STREAMSIZE_BITS == 64
9627 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str
, 16)
9629 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str
, 12)
9631 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_str(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
9633 return basic_istream_wchar_get_str_delim(this, str
, count
, '\n');
9636 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z */
9637 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z */
9638 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z */
9639 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z */
9640 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_streambuf_delim
, 12)
9641 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_streambuf_delim(basic_istream_wchar
*this, basic_streambuf_wchar
*strbuf
, wchar_t delim
)
9643 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9644 unsigned short ch
= delim
;
9646 TRACE("(%p %p %c)\n", this, strbuf
, delim
);
9650 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9651 basic_streambuf_wchar
*strbuf_read
= basic_ios_wchar_rdbuf_get(base
);
9653 for(ch
= basic_streambuf_wchar_sgetc(strbuf_read
); ;
9654 ch
= basic_streambuf_wchar_snextc(strbuf_read
)) {
9655 if(ch
==WEOF
|| ch
==delim
)
9658 if(basic_streambuf_wchar_sputc(strbuf
, ch
) == WEOF
)
9663 basic_istream_wchar_sentry_destroy(this);
9665 basic_ios_wchar_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
9666 (ch
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9670 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z */
9671 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z */
9672 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z */
9673 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z */
9674 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_streambuf
, 8)
9675 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_streambuf(basic_istream_wchar
*this, basic_streambuf_wchar
*strbuf
)
9677 return basic_istream_wchar_get_streambuf_delim(this, strbuf
, '\n');
9680 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH_W@Z */
9681 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z */
9682 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGHG@Z */
9683 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z */
9684 #if STREAMSIZE_BITS == 64
9685 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline_delim
, 20)
9687 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline_delim
, 16)
9689 basic_istream_wchar
* __thiscall
basic_istream_wchar_getline_delim(basic_istream_wchar
*this, wchar_t *str
, streamsize count
, wchar_t delim
)
9691 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9692 unsigned short ch
= delim
;
9694 TRACE("(%p %p %s %c)\n", this, str
, wine_dbgstr_longlong(count
), delim
);
9698 if(basic_istream_wchar_sentry_create(this, TRUE
) && count
>0) {
9699 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9702 ch
= basic_streambuf_wchar_sbumpc(strbuf
);
9704 if(ch
==WEOF
|| ch
==delim
)
9714 else if(ch
!= WEOF
) {
9715 ch
= basic_streambuf_wchar_sgetc(strbuf
);
9718 basic_streambuf_wchar__Gninc(strbuf
);
9723 basic_istream_wchar_sentry_destroy(this);
9725 basic_ios_wchar_setstate(base
, (ch
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
) |
9726 (!this->count
|| (ch
!=delim
&& ch
!=WEOF
) ? IOSTATE_failbit
: IOSTATE_goodbit
));
9732 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
9733 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
9734 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
9735 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
9736 #if STREAMSIZE_BITS == 64
9737 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline
, 16)
9739 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline
, 12)
9741 basic_istream_wchar
* __thiscall
basic_istream_wchar_getline(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
9743 return basic_istream_wchar_getline_delim(this, str
, count
, '\n');
9746 /* ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@HG@Z */
9747 /* ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JG@Z */
9748 /* ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@HG@Z */
9749 /* ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JG@Z */
9750 #if STREAMSIZE_BITS == 64
9751 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ignore
, 16)
9753 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ignore
, 12)
9755 basic_istream_wchar
* __thiscall
basic_istream_wchar_ignore(basic_istream_wchar
*this, streamsize count
, unsigned short delim
)
9757 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9758 unsigned short ch
= delim
;
9761 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(count
), delim
);
9765 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9766 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9767 state
= IOSTATE_goodbit
;
9770 ch
= basic_streambuf_wchar_sbumpc(strbuf
);
9773 state
= IOSTATE_eofbit
;
9781 if(count
!= INT_MAX
)
9785 state
= IOSTATE_failbit
;
9786 basic_istream_wchar_sentry_destroy(this);
9788 basic_ios_wchar_setstate(base
, state
);
9792 /* ?ws@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
9793 /* ?ws@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
9794 /* ?ws@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@1@AAV21@@Z */
9795 /* ?ws@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
9796 basic_istream_wchar
* __cdecl
ws_basic_istream_wchar(basic_istream_wchar
*istream
)
9798 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
9799 unsigned short ch
= '\n';
9801 TRACE("(%p)\n", istream
);
9803 if(basic_istream_wchar_sentry_create(istream
, TRUE
)) {
9804 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9805 const ctype_wchar
*ctype
= ctype_wchar_use_facet(IOS_LOCALE(strbuf
));
9807 for(ch
= basic_streambuf_wchar_sgetc(strbuf
); ctype_wchar_is_ch(ctype
, _SPACE
, ch
);
9808 ch
= basic_streambuf_wchar_snextc(strbuf
)) {
9813 basic_istream_wchar_sentry_destroy(istream
);
9816 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
);
9820 /* ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
9821 /* ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
9822 /* ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ */
9823 /* ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ */
9824 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_peek
, 4)
9825 unsigned short __thiscall
basic_istream_wchar_peek(basic_istream_wchar
*this)
9827 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9828 unsigned short ret
= WEOF
;
9830 TRACE("(%p)\n", this);
9834 if(basic_istream_wchar_sentry_create(this, TRUE
))
9835 ret
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
));
9836 basic_istream_wchar_sentry_destroy(this);
9839 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
);
9844 /* ?_Read_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WIH@Z */
9845 /* ?_Read_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_K_J@Z */
9846 /* ?_Read_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGIH@Z */
9847 /* ?_Read_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_K_J@Z */
9848 #if STREAMSIZE_BITS == 64
9849 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Read_s
, 20)
9851 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Read_s
, 16)
9853 basic_istream_wchar
* __thiscall
basic_istream_wchar__Read_s(basic_istream_wchar
*this, wchar_t *str
, MSVCP_size_t size
, streamsize count
)
9855 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9856 IOSB_iostate state
= IOSTATE_goodbit
;
9858 TRACE("(%p %p %lu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
9860 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9861 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9863 this->count
= basic_streambuf_wchar__Sgetn_s(strbuf
, str
, size
, count
);
9864 if(this->count
!= count
)
9865 state
|= IOSTATE_failbit
| IOSTATE_eofbit
;
9869 basic_istream_wchar_sentry_destroy(this);
9871 basic_ios_wchar_setstate(base
, state
);
9875 /* ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
9876 /* ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
9877 /* ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
9878 /* ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
9879 #if STREAMSIZE_BITS == 64
9880 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read
, 16)
9882 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read
, 12)
9884 basic_istream_wchar
* __thiscall
basic_istream_wchar_read(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
9886 return basic_istream_wchar__Read_s(this, str
, -1, count
);
9889 /* ?_Readsome_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHPA_WIH@Z */
9890 /* ?_Readsome_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_K_J@Z */
9891 /* ?_Readsome_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHPAGIH@Z */
9892 /* ?_Readsome_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_K_J@Z */
9893 #if STREAMSIZE_BITS == 64
9894 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Readsome_s
, 20)
9896 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Readsome_s
, 16)
9898 streamsize __thiscall
basic_istream_wchar__Readsome_s(basic_istream_wchar
*this, wchar_t *str
, MSVCP_size_t size
, streamsize count
)
9900 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9901 IOSB_iostate state
= IOSTATE_goodbit
;
9903 TRACE("(%p %p %lu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
9907 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9908 streamsize avail
= basic_streambuf_wchar_in_avail(basic_ios_wchar_rdbuf_get(base
));
9913 state
|= IOSTATE_eofbit
;
9915 basic_istream_wchar__Read_s(this, str
, size
, avail
);
9917 state
|= IOSTATE_failbit
;
9919 basic_istream_wchar_sentry_destroy(this);
9921 basic_ios_wchar_setstate(base
, state
);
9925 /* ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHPA_WH@Z */
9926 /* ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z */
9927 /* ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHPAGH@Z */
9928 /* ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z */
9929 #if STREAMSIZE_BITS == 64
9930 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_readsome
, 16)
9932 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_readsome
, 12)
9934 streamsize __thiscall
basic_istream_wchar_readsome(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
9936 return basic_istream_wchar__Readsome_s(this, str
, count
, count
);
9939 /* ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z */
9940 /* ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z */
9941 /* ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z */
9942 /* ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z */
9943 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_putback
, 8)
9944 basic_istream_wchar
* __thiscall
basic_istream_wchar_putback(basic_istream_wchar
*this, wchar_t ch
)
9946 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9947 IOSB_iostate state
= IOSTATE_goodbit
;
9949 TRACE("(%p %c)\n", this, ch
);
9953 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9954 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9956 if(!ios_base_good(&base
->base
))
9957 state
|= IOSTATE_failbit
;
9958 else if(!strbuf
|| basic_streambuf_wchar_sputbackc(strbuf
, ch
)==WEOF
)
9959 state
|= IOSTATE_badbit
;
9961 basic_istream_wchar_sentry_destroy(this);
9963 basic_ios_wchar_setstate(base
, state
);
9967 /* ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ */
9968 /* ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ */
9969 /* ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ */
9970 /* ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ */
9971 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_unget
, 4)
9972 basic_istream_wchar
* __thiscall
basic_istream_wchar_unget(basic_istream_wchar
*this)
9974 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9975 IOSB_iostate state
= IOSTATE_goodbit
;
9977 TRACE("(%p)\n", this);
9981 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9982 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9984 if(!ios_base_good(&base
->base
))
9985 state
|= IOSTATE_failbit
;
9986 else if(!strbuf
|| basic_streambuf_wchar_sungetc(strbuf
)==WEOF
)
9987 state
|= IOSTATE_badbit
;
9989 basic_istream_wchar_sentry_destroy(this);
9991 basic_ios_wchar_setstate(base
, state
);
9995 /* ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
9996 /* ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAHXZ */
9997 /* ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHXZ */
9998 /* ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAHXZ */
9999 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_sync
, 4)
10000 int __thiscall
basic_istream_wchar_sync(basic_istream_wchar
*this)
10002 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10003 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10005 TRACE("(%p)\n", this);
10010 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10011 if(basic_streambuf_wchar_pubsync(strbuf
) != -1) {
10012 basic_istream_wchar_sentry_destroy(this);
10016 basic_istream_wchar_sentry_destroy(this);
10018 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
10022 /* ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ */
10023 /* ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
10024 /* ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ */
10025 /* ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
10026 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_tellg
, 8)
10027 fpos_int
* __thiscall
basic_istream_wchar_tellg(basic_istream_wchar
*this, fpos_int
*ret
)
10029 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10031 TRACE("(%p %p)\n", this, ret
);
10033 if(ios_base_fail(&base
->base
)) {
10040 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
10041 ret
, 0, SEEKDIR_cur
, OPENMODE_in
);
10042 if(ret
->off
==-1 && ret
->pos
==0 && ret
->state
==0)
10043 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10048 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@JW4seekdir@ios_base@2@@Z */
10049 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JW4seekdir@ios_base@2@@Z */
10050 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@JH@Z */
10051 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z */
10052 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@JH@Z */
10053 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z */
10054 #if STREAMOFF_BITS == 64
10055 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg
, 16)
10057 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg
, 12)
10059 basic_istream_wchar
* __thiscall
basic_istream_wchar_seekg(basic_istream_wchar
*this, streamoff off
, int dir
)
10061 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10063 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), dir
);
10065 if(!ios_base_fail(&base
->base
)) {
10066 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10069 basic_streambuf_wchar_pubseekoff(strbuf
, &ret
, off
, dir
, OPENMODE_in
);
10071 if(ret
.off
==-1 && ret
.pos
==0 && ret
.state
==0)
10072 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10074 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10077 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10082 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
10083 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
10084 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
10085 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
10086 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg_fpos
, 28)
10087 basic_istream_wchar
* __thiscall
basic_istream_wchar_seekg_fpos(basic_istream_wchar
*this, fpos_int pos
)
10089 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10091 TRACE("(%p %s)\n", this, debugstr_fpos_int(&pos
));
10093 if(!ios_base_fail(&base
->base
)) {
10094 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10097 basic_streambuf_wchar_pubseekpos(strbuf
, &ret
, pos
, OPENMODE_in
);
10099 if(ret
.off
==-1 && ret
.pos
==0 && ret
.state
==0)
10100 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10102 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10105 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10110 static basic_istream_wchar
* basic_istream_read_short(basic_istream_wchar
*this, short *v
, const num_get
*numget
)
10112 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10113 int state
= IOSTATE_goodbit
;
10115 TRACE("(%p %p)\n", this, v
);
10117 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10118 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10119 istreambuf_iterator_wchar first
={0}, last
={0};
10122 first
.strbuf
= strbuf
;
10123 num_get_wchar_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, &tmp
);
10125 if(!(state
&IOSTATE_failbit
) && tmp
==(LONG
)((short)tmp
))
10128 state
|= IOSTATE_failbit
;
10130 basic_istream_wchar_sentry_destroy(this);
10132 basic_ios_wchar_setstate(base
, state
);
10136 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAF@Z */
10137 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAF@Z */
10138 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_short
, 8)
10139 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_short(basic_istream_wchar
*this, short *v
)
10141 return basic_istream_read_short(this, v
, num_get_wchar_use_facet(
10142 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10145 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAF@Z */
10146 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAF@Z */
10147 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_short
, 8)
10148 basic_istream_wchar
* __thiscall
basic_istream_short_read_short(basic_istream_wchar
*this, short *v
)
10150 return basic_istream_read_short(this, v
, num_get_short_use_facet(
10151 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10154 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAG@Z */
10155 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAG@Z */
10156 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ushort
, 8)
10157 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ushort(basic_istream_wchar
*this, unsigned short *v
)
10159 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10160 int state
= IOSTATE_goodbit
;
10162 TRACE("(%p %p)\n", this, v
);
10164 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10165 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10166 const num_get
*numget
= num_get_wchar_use_facet(IOS_LOCALE(strbuf
));
10167 istreambuf_iterator_wchar first
={0}, last
={0};
10169 first
.strbuf
= strbuf
;
10170 num_get_wchar_get_ushort(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10172 basic_istream_wchar_sentry_destroy(this);
10174 basic_ios_wchar_setstate(base
, state
);
10178 static basic_istream_wchar
* basic_istream_read_int(basic_istream_wchar
*this, int *v
, const num_get
*numget
)
10180 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10181 int state
= IOSTATE_goodbit
;
10183 TRACE("(%p %p)\n", this, v
);
10185 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10186 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10187 istreambuf_iterator_wchar first
={0}, last
={0};
10189 first
.strbuf
= strbuf
;
10190 num_get_wchar_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10192 basic_istream_wchar_sentry_destroy(this);
10194 basic_ios_wchar_setstate(base
, state
);
10198 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAH@Z */
10199 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAH@Z */
10200 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_int
, 8)
10201 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_int(basic_istream_wchar
*this, int *v
)
10203 return basic_istream_read_int(this, v
, num_get_wchar_use_facet(
10204 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10207 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAH@Z */
10208 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAH@Z */
10209 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_int
, 8)
10210 basic_istream_wchar
* __thiscall
basic_istream_short_read_int(basic_istream_wchar
*this, int *v
)
10212 return basic_istream_read_int(this, v
, num_get_short_use_facet(
10213 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10216 static basic_istream_wchar
* basic_istream_read_uint(basic_istream_wchar
*this, unsigned int *v
, const num_get
*numget
)
10218 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10219 int state
= IOSTATE_goodbit
;
10221 TRACE("(%p %p)\n", this, v
);
10223 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10224 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10225 istreambuf_iterator_wchar first
={0}, last
={0};
10227 first
.strbuf
= strbuf
;
10228 num_get_wchar_get_uint(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10230 basic_istream_wchar_sentry_destroy(this);
10232 basic_ios_wchar_setstate(base
, state
);
10236 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAI@Z */
10237 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAI@Z */
10238 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_uint
, 8)
10239 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_uint(basic_istream_wchar
*this, unsigned int *v
)
10241 return basic_istream_read_uint(this, v
, num_get_wchar_use_facet(
10242 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10245 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAI@Z */
10246 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAI@Z */
10247 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_uint
, 8)
10248 basic_istream_wchar
* __thiscall
basic_istream_short_read_uint(basic_istream_wchar
*this, unsigned int *v
)
10250 return basic_istream_read_uint(this, v
, num_get_short_use_facet(
10251 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10254 static basic_istream_wchar
* basic_istream_read_long(basic_istream_wchar
*this, LONG
*v
, const num_get
*numget
)
10256 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10257 int state
= IOSTATE_goodbit
;
10259 TRACE("(%p %p)\n", this, v
);
10261 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10262 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10263 istreambuf_iterator_wchar first
={0}, last
={0};
10265 first
.strbuf
= strbuf
;
10266 num_get_wchar_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10268 basic_istream_wchar_sentry_destroy(this);
10270 basic_ios_wchar_setstate(base
, state
);
10274 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z */
10275 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z */
10276 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_long
, 8)
10277 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_long(basic_istream_wchar
*this, LONG
*v
)
10279 return basic_istream_read_long(this, v
, num_get_wchar_use_facet(
10280 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10283 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z */
10284 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z */
10285 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_long
, 8)
10286 basic_istream_wchar
* __thiscall
basic_istream_short_read_long(basic_istream_wchar
*this, LONG
*v
)
10288 return basic_istream_read_long(this, v
, num_get_short_use_facet(
10289 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10292 static basic_istream_wchar
* basic_istream_read_ulong(basic_istream_wchar
*this, ULONG
*v
, const num_get
*numget
)
10294 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10295 int state
= IOSTATE_goodbit
;
10297 TRACE("(%p %p)\n", this, v
);
10299 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10300 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10301 istreambuf_iterator_wchar first
={0}, last
={0};
10303 first
.strbuf
= strbuf
;
10304 num_get_wchar_get_ulong(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10306 basic_istream_wchar_sentry_destroy(this);
10308 basic_ios_wchar_setstate(base
, state
);
10312 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAK@Z */
10313 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAK@Z */
10314 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ulong
, 8)
10315 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ulong(basic_istream_wchar
*this, ULONG
*v
)
10317 return basic_istream_read_ulong(this, v
, num_get_wchar_use_facet(
10318 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10321 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAK@Z */
10322 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAK@Z */
10323 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ulong
, 8)
10324 basic_istream_wchar
* __thiscall
basic_istream_short_read_ulong(basic_istream_wchar
*this, ULONG
*v
)
10326 return basic_istream_read_ulong(this, v
, num_get_short_use_facet(
10327 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10330 static basic_istream_wchar
* basic_istream_read_float(basic_istream_wchar
*this, float *v
, const num_get
*numget
)
10332 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10333 int state
= IOSTATE_goodbit
;
10335 TRACE("(%p %p)\n", this, v
);
10337 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10338 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10339 istreambuf_iterator_wchar first
={0}, last
={0};
10341 first
.strbuf
= strbuf
;
10342 num_get_wchar_get_float(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10344 basic_istream_wchar_sentry_destroy(this);
10346 basic_ios_wchar_setstate(base
, state
);
10350 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAM@Z */
10351 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAM@Z */
10352 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_float
, 8)
10353 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_float(basic_istream_wchar
*this, float *v
)
10355 return basic_istream_read_float(this, v
, num_get_wchar_use_facet(
10356 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10359 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAM@Z */
10360 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAM@Z */
10361 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_float
, 8)
10362 basic_istream_wchar
* __thiscall
basic_istream_short_read_float(basic_istream_wchar
*this, float *v
)
10364 return basic_istream_read_float(this, v
, num_get_short_use_facet(
10365 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10368 static basic_istream_wchar
* basic_istream_read_double(basic_istream_wchar
*this, double *v
, const num_get
*numget
)
10370 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10371 int state
= IOSTATE_goodbit
;
10373 TRACE("(%p %p)\n", this, v
);
10375 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10376 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10377 istreambuf_iterator_wchar first
={0}, last
={0};
10379 first
.strbuf
= strbuf
;
10380 num_get_wchar_get_double(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10382 basic_istream_wchar_sentry_destroy(this);
10384 basic_ios_wchar_setstate(base
, state
);
10388 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAN@Z */
10389 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAN@Z */
10390 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_double
, 8)
10391 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_double(basic_istream_wchar
*this, double *v
)
10393 return basic_istream_read_double(this, v
, num_get_wchar_use_facet(
10394 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10397 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAN@Z */
10398 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAN@Z */
10399 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_double
, 8)
10400 basic_istream_wchar
* __thiscall
basic_istream_short_read_double(basic_istream_wchar
*this, double *v
)
10402 return basic_istream_read_double(this, v
, num_get_short_use_facet(
10403 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10406 static basic_istream_wchar
* basic_istream_read_ldouble(basic_istream_wchar
*this, double *v
, const num_get
*numget
)
10408 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10409 int state
= IOSTATE_goodbit
;
10411 TRACE("(%p %p)\n", this, v
);
10413 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10414 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10415 istreambuf_iterator_wchar first
={0}, last
={0};
10417 first
.strbuf
= strbuf
;
10418 num_get_wchar_get_ldouble(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10420 basic_istream_wchar_sentry_destroy(this);
10422 basic_ios_wchar_setstate(base
, state
);
10426 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAO@Z */
10427 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAO@Z */
10428 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ldouble
, 8)
10429 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ldouble(basic_istream_wchar
*this, double *v
)
10431 return basic_istream_read_ldouble(this, v
, num_get_wchar_use_facet(
10432 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10435 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAO@Z */
10436 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAO@Z */
10437 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ldouble
, 8)
10438 basic_istream_wchar
* __thiscall
basic_istream_short_read_ldouble(basic_istream_wchar
*this, double *v
)
10440 return basic_istream_read_ldouble(this, v
, num_get_short_use_facet(
10441 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10444 static basic_istream_wchar
* basic_istream_read_ptr(basic_istream_wchar
*this, void **v
, const num_get
*numget
)
10446 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10447 int state
= IOSTATE_goodbit
;
10449 TRACE("(%p %p)\n", this, v
);
10451 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10452 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10453 istreambuf_iterator_wchar first
={0}, last
={0};
10455 first
.strbuf
= strbuf
;
10456 num_get_wchar_get_void(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10458 basic_istream_wchar_sentry_destroy(this);
10460 basic_ios_wchar_setstate(base
, state
);
10464 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAPAX@Z */
10465 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
10466 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ptr
, 8)
10467 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ptr(basic_istream_wchar
*this, void **v
)
10469 return basic_istream_read_ptr(this, v
, num_get_wchar_use_facet(
10470 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10473 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAPAX@Z */
10474 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
10475 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ptr
, 8)
10476 basic_istream_wchar
* __thiscall
basic_istream_short_read_ptr(basic_istream_wchar
*this, void **v
)
10478 return basic_istream_read_ptr(this, v
, num_get_short_use_facet(
10479 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10482 static basic_istream_wchar
* basic_istream_read_int64(basic_istream_wchar
*this, __int64
*v
, const num_get
*numget
)
10484 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10485 int state
= IOSTATE_goodbit
;
10487 TRACE("(%p %p)\n", this, v
);
10489 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10490 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10491 istreambuf_iterator_wchar first
={0}, last
={0};
10493 first
.strbuf
= strbuf
;
10494 num_get_wchar_get_int64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10496 basic_istream_wchar_sentry_destroy(this);
10498 basic_ios_wchar_setstate(base
, state
);
10502 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_J@Z */
10503 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_J@Z */
10504 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_int64
, 8)
10505 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_int64(basic_istream_wchar
*this, __int64
*v
)
10507 return basic_istream_read_int64(this, v
, num_get_wchar_use_facet(
10508 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10511 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_J@Z */
10512 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_J@Z */
10513 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_int64
, 8)
10514 basic_istream_wchar
* __thiscall
basic_istream_short_read_int64(basic_istream_wchar
*this, __int64
*v
)
10516 return basic_istream_read_int64(this, v
, num_get_short_use_facet(
10517 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10520 static basic_istream_wchar
* basic_istream_read_uint64(basic_istream_wchar
*this, unsigned __int64
*v
, const num_get
*numget
)
10522 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10523 int state
= IOSTATE_goodbit
;
10525 TRACE("(%p %p)\n", this, v
);
10527 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10528 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10529 istreambuf_iterator_wchar first
={0}, last
={0};
10531 first
.strbuf
= strbuf
;
10532 num_get_wchar_get_uint64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10534 basic_istream_wchar_sentry_destroy(this);
10536 basic_ios_wchar_setstate(base
, state
);
10540 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_K@Z */
10541 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_K@Z */
10542 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_uint64
, 8)
10543 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_uint64(basic_istream_wchar
*this, unsigned __int64
*v
)
10545 return basic_istream_read_uint64(this, v
, num_get_wchar_use_facet(
10546 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10549 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_K@Z */
10550 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_K@Z */
10551 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_uint64
, 8)
10552 basic_istream_wchar
* __thiscall
basic_istream_short_read_uint64(basic_istream_wchar
*this, unsigned __int64
*v
)
10554 return basic_istream_read_uint64(this, v
, num_get_short_use_facet(
10555 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10558 static basic_istream_wchar
* basic_istream_read_bool(basic_istream_wchar
*this, MSVCP_bool
*v
, const num_get
*numget
)
10560 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10561 int state
= IOSTATE_goodbit
;
10563 TRACE("(%p %p)\n", this, v
);
10565 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10566 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10567 istreambuf_iterator_wchar first
={0}, last
={0};
10569 first
.strbuf
= strbuf
;
10570 num_get_wchar_get_bool(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10572 basic_istream_wchar_sentry_destroy(this);
10574 basic_ios_wchar_setstate(base
, state
);
10578 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_N@Z */
10579 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_N@Z */
10580 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_bool
, 8)
10581 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_bool(basic_istream_wchar
*this, MSVCP_bool
*v
)
10583 return basic_istream_read_bool(this, v
, num_get_wchar_use_facet(
10584 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10587 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_N@Z */
10588 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_N@Z */
10589 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_bool
, 8)
10590 basic_istream_wchar
* __thiscall
basic_istream_short_read_bool(basic_istream_wchar
*this, MSVCP_bool
*v
)
10592 return basic_istream_read_bool(this, v
, num_get_short_use_facet(
10593 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10596 /* ??$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 */
10597 /* ??$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 */
10598 /* ??$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 */
10599 /* ??$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 */
10600 basic_istream_wchar
* __cdecl
basic_istream_wchar_getline_bstr_delim(
10601 basic_istream_wchar
*istream
, basic_string_wchar
*str
, wchar_t delim
)
10603 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
10604 IOSB_iostate state
= IOSTATE_goodbit
;
10607 TRACE("(%p %p %c)\n", istream
, str
, delim
);
10609 if(basic_istream_wchar_sentry_create(istream
, TRUE
)) {
10610 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10611 MSVCP_basic_string_wchar_clear(str
);
10613 c
= basic_streambuf_wchar_sgetc(strbuf
);
10614 for(; c
!=delim
&& c
!=WEOF
; c
= basic_streambuf_wchar_snextc(strbuf
))
10615 MSVCP_basic_string_wchar_append_ch(str
, c
);
10616 if(c
==delim
) basic_streambuf_wchar_sbumpc(strbuf
);
10617 else if(c
==WEOF
) state
|= IOSTATE_eofbit
;
10619 if(!MSVCP_basic_string_wchar_length(str
) && c
!=delim
) state
|= IOSTATE_failbit
;
10621 basic_istream_wchar_sentry_destroy(istream
);
10623 basic_ios_wchar_setstate(basic_istream_wchar_get_basic_ios(istream
), state
);
10627 /* ??$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 */
10628 /* ??$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 */
10629 /* ??$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 */
10630 /* ??$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 */
10631 basic_istream_wchar
* __cdecl
basic_istream_wchar_getline_bstr(
10632 basic_istream_wchar
*istream
, basic_string_wchar
*str
)
10634 return basic_istream_wchar_getline_bstr_delim(istream
, str
, '\n');
10637 static basic_istream_wchar
* basic_istream_read_bstr(basic_istream_wchar
*istream
,
10638 basic_string_wchar
*str
, const ctype_wchar
*ctype
)
10640 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
10641 IOSB_iostate state
= IOSTATE_failbit
;
10644 TRACE("(%p %p)\n", istream
, str
);
10646 if(basic_istream_wchar_sentry_create(istream
, FALSE
)) {
10647 MSVCP_size_t count
= ios_base_width_get(&base
->base
);
10652 MSVCP_basic_string_wchar_clear(str
);
10654 for(c
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
));
10655 c
!=WEOF
&& !ctype_wchar_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
10656 c
= basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base
)), count
--) {
10657 state
= IOSTATE_goodbit
;
10658 MSVCP_basic_string_wchar_append_ch(str
, c
);
10661 basic_istream_wchar_sentry_destroy(istream
);
10663 ios_base_width_set(&base
->base
, 0);
10664 basic_ios_wchar_setstate(base
, state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
10668 /* ??$?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 */
10669 /* ??$?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 */
10670 basic_istream_wchar
* __cdecl
basic_istream_wchar_read_bstr(
10671 basic_istream_wchar
*istream
, basic_string_wchar
*str
)
10673 return basic_istream_read_bstr(istream
, str
, ctype_wchar_use_facet(
10674 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
10677 /* ??$?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 */
10678 /* ??$?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 */
10679 basic_istream_wchar
* __cdecl
basic_istream_short_read_bstr(
10680 basic_istream_wchar
*istream
, basic_string_wchar
*str
)
10682 return basic_istream_read_bstr(istream
, str
, ctype_short_use_facet(
10683 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
10686 static basic_istream_wchar
* basic_istream_read_str(basic_istream_wchar
*istream
, wchar_t *str
, const ctype_wchar
*ctype
)
10688 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
10689 IOSB_iostate state
= IOSTATE_failbit
;
10690 unsigned short c
= '\n';
10692 TRACE("(%p %p)\n", istream
, str
);
10694 if(basic_istream_wchar_sentry_create(istream
, FALSE
)) {
10695 MSVCP_size_t count
= ios_base_width_get(&base
->base
)-1;
10697 for(c
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
));
10698 c
!=WEOF
&& !ctype_wchar_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
10699 c
= basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base
)), count
--) {
10700 state
= IOSTATE_goodbit
;
10704 basic_istream_wchar_sentry_destroy(istream
);
10707 ios_base_width_set(&base
->base
, 0);
10708 basic_ios_wchar_setstate(base
, state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
10712 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@PA_W@Z */
10713 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@PEA_W@Z */
10714 basic_istream_wchar
* __cdecl
basic_istream_wchar_read_str(basic_istream_wchar
*istream
, wchar_t *str
)
10716 return basic_istream_read_str(istream
, str
, ctype_wchar_use_facet(
10717 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
10720 /* ??$?5GU?$char_traits@G@std@@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@PAG@Z */
10721 /* ??$?5GU?$char_traits@G@std@@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@PEAG@Z */
10722 basic_istream_wchar
* __cdecl
basic_istream_short_read_str(basic_istream_wchar
*istream
, wchar_t *str
)
10724 return basic_istream_read_str(istream
, str
, ctype_short_use_facet(
10725 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
10728 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AA_W@Z */
10729 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEA_W@Z */
10730 /* ??$?5GU?$char_traits@G@std@@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@AAG@Z */
10731 /* ??$?5GU?$char_traits@G@std@@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@AEAG@Z */
10732 basic_istream_wchar
* __cdecl
basic_istream_wchar_read_ch(basic_istream_wchar
*istream
, wchar_t *ch
)
10734 IOSB_iostate state
= IOSTATE_failbit
;
10735 unsigned short c
= 0;
10737 TRACE("(%p %p)\n", istream
, ch
);
10739 if(basic_istream_wchar_sentry_create(istream
, FALSE
)) {
10740 c
= basic_streambuf_wchar_sbumpc(basic_ios_wchar_rdbuf_get(
10741 basic_istream_wchar_get_basic_ios(istream
)));
10743 state
= IOSTATE_goodbit
;
10747 basic_istream_wchar_sentry_destroy(istream
);
10749 basic_ios_wchar_setstate(basic_istream_wchar_get_basic_ios(istream
),
10750 state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
10754 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
10755 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
10756 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
10757 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
10758 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_streambuf
, 8)
10759 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_streambuf(
10760 basic_istream_wchar
*this, basic_streambuf_wchar
*streambuf
)
10762 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10763 IOSB_iostate state
= IOSTATE_failbit
;
10764 unsigned short c
= '\n';
10766 TRACE("(%p %p)\n", this, streambuf
);
10768 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10769 for(c
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
)); c
!=WEOF
;
10770 c
= basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base
))) {
10771 state
= IOSTATE_goodbit
;
10772 if(basic_streambuf_wchar_sputc(streambuf
, c
) == WEOF
)
10776 basic_istream_wchar_sentry_destroy(this);
10778 basic_ios_wchar_setstate(base
, state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
10782 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
10783 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
10784 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
10785 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
10786 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func
, 8)
10787 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_func(basic_istream_wchar
*this,
10788 basic_istream_wchar
* (__cdecl
*pfunc
)(basic_istream_wchar
*))
10790 TRACE("(%p %p)\n", this, pfunc
);
10795 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z */
10796 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z */
10797 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z */
10798 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z */
10799 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func_basic_ios
, 8)
10800 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_func_basic_ios(basic_istream_wchar
*this,
10801 basic_ios_wchar
* (__cdecl
*pfunc
)(basic_ios_wchar
*))
10803 TRACE("(%p %p)\n", this, pfunc
);
10804 pfunc(basic_istream_wchar_get_basic_ios(this));
10808 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
10809 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
10810 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
10811 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
10812 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func_ios_base
, 8)
10813 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_func_ios_base(
10814 basic_istream_wchar
*this, ios_base
* (__cdecl
*pfunc
)(ios_base
*))
10816 TRACE("(%p %p)\n", this, pfunc
);
10817 pfunc(&basic_istream_wchar_get_basic_ios(this)->base
);
10821 /* ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z */
10822 /* ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z */
10823 /* ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z */
10824 /* ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z */
10825 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_swap
, 8)
10826 void __thiscall
basic_istream_wchar_swap(basic_istream_wchar
*this, basic_istream_wchar
*r
)
10828 TRACE("(%p %p)\n", this, r
);
10833 basic_ios_wchar_swap(basic_istream_wchar_get_basic_ios(this),
10834 basic_istream_wchar_get_basic_ios(r
));
10835 this->count
^= r
->count
;
10836 r
->count
^= this->count
;
10837 this->count
^= r
->count
;
10840 static inline basic_ios_char
* basic_iostream_char_to_basic_ios(basic_iostream_char
*ptr
)
10842 return (basic_ios_char
*)((char*)ptr
+basic_iostream_char_vbtable1
[1]);
10845 static inline basic_iostream_char
* basic_iostream_char_from_basic_ios(basic_ios_char
*ptr
)
10847 return (basic_iostream_char
*)((char*)ptr
-basic_iostream_char_vbtable1
[1]);
10850 /* ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
10851 /* ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
10852 DEFINE_THISCALL_WRAPPER(basic_iostream_char_ctor
, 12)
10853 basic_iostream_char
* __thiscall
basic_iostream_char_ctor(basic_iostream_char
*this, basic_streambuf_char
*strbuf
, MSVCP_bool virt_init
)
10855 basic_ios_char
*basic_ios
;
10857 TRACE("(%p %p %d)\n", this, strbuf
, virt_init
);
10860 this->base1
.vbtable
= basic_iostream_char_vbtable1
;
10861 this->base2
.vbtable
= basic_iostream_char_vbtable2
;
10862 basic_ios
= basic_istream_char_get_basic_ios(&this->base1
);
10863 basic_ios_char_ctor(basic_ios
);
10865 basic_ios
= basic_istream_char_get_basic_ios(&this->base1
);
10868 basic_ios
->base
.vtable
= &MSVCP_basic_iostream_char_vtable
;
10870 basic_istream_char_ctor(&this->base1
, strbuf
, FALSE
, FALSE
);
10871 basic_ostream_char_ctor_uninitialized(&this->base2
, 0, FALSE
, FALSE
);
10875 /* ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UAE@XZ */
10876 /* ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
10877 DEFINE_THISCALL_WRAPPER(basic_iostream_char_dtor
, 4)
10878 void __thiscall
basic_iostream_char_dtor(basic_ios_char
*base
)
10880 basic_iostream_char
*this = basic_iostream_char_from_basic_ios(base
);
10882 TRACE("(%p)\n", this);
10883 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base2
));
10884 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base1
));
10887 /* ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
10888 /* ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
10889 DEFINE_THISCALL_WRAPPER(basic_iostream_char_vbase_dtor
, 4)
10890 void __thiscall
basic_iostream_char_vbase_dtor(basic_iostream_char
*this)
10892 TRACE("(%p)\n", this);
10893 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(this));
10894 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base1
));
10897 DEFINE_THISCALL_WRAPPER(basic_iostream_char_vector_dtor
, 8)
10898 basic_iostream_char
* __thiscall
basic_iostream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
10900 basic_iostream_char
*this = basic_iostream_char_from_basic_ios(base
);
10902 TRACE("(%p %x)\n", this, flags
);
10905 /* we have an array, with the number of elements stored before the first object */
10906 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
10908 for(i
=*ptr
-1; i
>=0; i
--)
10909 basic_iostream_char_vbase_dtor(this+i
);
10910 MSVCRT_operator_delete(ptr
);
10912 basic_iostream_char_vbase_dtor(this);
10914 MSVCRT_operator_delete(this);
10920 /* ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z */
10921 /* ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z */
10922 DEFINE_THISCALL_WRAPPER(basic_iostream_char_swap
, 8)
10923 void __thiscall
basic_iostream_char_swap(basic_iostream_char
*this, basic_iostream_char
*r
)
10925 TRACE("(%p %p)\n", this, r
);
10930 basic_ios_char_swap(basic_istream_char_get_basic_ios(&this->base1
),
10931 basic_istream_char_get_basic_ios(&r
->base1
));
10934 static inline basic_ios_wchar
* basic_iostream_wchar_to_basic_ios(basic_iostream_wchar
*ptr
)
10936 return (basic_ios_wchar
*)((char*)ptr
+basic_iostream_wchar_vbtable1
[1]);
10939 static inline basic_iostream_wchar
* basic_iostream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
10941 return (basic_iostream_wchar
*)((char*)ptr
-basic_iostream_wchar_vbtable1
[1]);
10944 /* ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
10945 /* ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
10946 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_ctor
, 12)
10947 basic_iostream_wchar
* __thiscall
basic_iostream_wchar_ctor(basic_iostream_wchar
*this,
10948 basic_streambuf_wchar
*strbuf
, MSVCP_bool virt_init
)
10950 basic_ios_wchar
*basic_ios
;
10952 TRACE("(%p %p %d)\n", this, strbuf
, virt_init
);
10955 this->base1
.vbtable
= basic_iostream_wchar_vbtable1
;
10956 this->base2
.vbtable
= basic_iostream_wchar_vbtable2
;
10957 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base1
);
10958 basic_ios_wchar_ctor(basic_ios
);
10960 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base1
);
10963 basic_istream_wchar_ctor(&this->base1
, strbuf
, FALSE
, FALSE
);
10964 basic_ostream_wchar_ctor_uninitialized(&this->base2
, 0, FALSE
, FALSE
);
10966 basic_ios
->base
.vtable
= &MSVCP_basic_iostream_wchar_vtable
;
10970 /* ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
10971 /* ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
10972 DEFINE_THISCALL_WRAPPER(basic_iostream_short_ctor
, 12)
10973 basic_iostream_wchar
* __thiscall
basic_iostream_short_ctor(basic_iostream_wchar
*this,
10974 basic_streambuf_wchar
*strbuf
, MSVCP_bool virt_init
)
10976 basic_iostream_wchar_ctor(this, strbuf
, virt_init
);
10977 basic_istream_wchar_get_basic_ios(&this->base1
)->base
.vtable
= &MSVCP_basic_iostream_short_vtable
;
10981 /* ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
10982 /* ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
10983 /* ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UAE@XZ */
10984 /* ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
10985 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_dtor
, 4)
10986 void __thiscall
basic_iostream_wchar_dtor(basic_ios_wchar
*base
)
10988 basic_iostream_wchar
*this = basic_iostream_wchar_from_basic_ios(base
);
10990 TRACE("(%p)\n", this);
10991 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base2
));
10992 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base1
));
10995 /* ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
10996 /* ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
10997 /* ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
10998 /* ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
10999 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_vbase_dtor
, 4)
11000 void __thiscall
basic_iostream_wchar_vbase_dtor(basic_iostream_wchar
*this)
11002 TRACE("(%p)\n", this);
11003 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(this));
11004 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base1
));
11007 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_vector_dtor
, 8)
11008 basic_iostream_wchar
* __thiscall
basic_iostream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
11010 basic_iostream_wchar
*this = basic_iostream_wchar_from_basic_ios(base
);
11012 TRACE("(%p %x)\n", this, flags
);
11015 /* we have an array, with the number of elements stored before the first object */
11016 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11018 for(i
=*ptr
-1; i
>=0; i
--)
11019 basic_iostream_wchar_vbase_dtor(this+i
);
11020 MSVCRT_operator_delete(ptr
);
11022 basic_iostream_wchar_vbase_dtor(this);
11024 MSVCRT_operator_delete(this);
11030 /* ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z */
11031 /* ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z */
11032 /* ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z */
11033 /* ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z */
11034 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_swap
, 8)
11035 void __thiscall
basic_iostream_wchar_swap(basic_iostream_wchar
*this, basic_iostream_wchar
*r
)
11037 TRACE("(%p %p)\n", this, r
);
11042 basic_ios_wchar_swap(basic_istream_wchar_get_basic_ios(&this->base1
),
11043 basic_istream_wchar_get_basic_ios(&r
->base1
));
11046 static inline basic_ios_char
* basic_ofstream_char_to_basic_ios(basic_ofstream_char
*ptr
)
11048 return (basic_ios_char
*)((char*)ptr
+basic_ofstream_char_vbtable
[1]);
11051 static inline basic_ofstream_char
* basic_ofstream_char_from_basic_ios(basic_ios_char
*ptr
)
11053 return (basic_ofstream_char
*)((char*)ptr
-basic_ofstream_char_vbtable
[1]);
11056 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
11057 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
11058 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor
, 8)
11059 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor(basic_ofstream_char
*this, MSVCP_bool virt_init
)
11061 basic_ios_char
*basic_ios
;
11063 TRACE("(%p %d)\n", this, virt_init
);
11066 this->base
.vbtable
= basic_ofstream_char_vbtable
;
11067 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11068 basic_ios_char_ctor(basic_ios
);
11070 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11073 basic_filebuf_char_ctor(&this->filebuf
);
11074 basic_ostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11075 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_char_vtable
;
11079 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
11080 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11081 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_file
, 12)
11082 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor_file(
11083 basic_ofstream_char
*this, FILE *file
, MSVCP_bool virt_init
)
11085 basic_ios_char
*basic_ios
;
11087 TRACE("(%p %p %d)\n", this, file
, virt_init
);
11090 this->base
.vbtable
= basic_ofstream_char_vbtable
;
11091 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11092 basic_ios_char_ctor(basic_ios
);
11094 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11097 basic_filebuf_char_ctor_file(&this->filebuf
, file
);
11098 basic_ostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11099 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_char_vtable
;
11103 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
11104 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
11105 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_name
, 20)
11106 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor_name(basic_ofstream_char
*this,
11107 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11109 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
11111 basic_ofstream_char_ctor(this, virt_init
);
11113 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11114 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11115 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11120 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
11121 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
11122 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
11123 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
11124 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_name_wchar
, 20)
11125 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor_name_wchar(basic_ofstream_char
*this,
11126 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11128 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
11130 basic_ofstream_char_ctor(this, virt_init
);
11132 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11133 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11134 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11139 /* ??1?$basic_ofstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
11140 /* ??1?$basic_ofstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
11141 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_dtor
, 4)
11142 void __thiscall
basic_ofstream_char_dtor(basic_ios_char
*base
)
11144 basic_ofstream_char
*this = basic_ofstream_char_from_basic_ios(base
);
11146 TRACE("(%p)\n", this);
11148 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base
));
11149 basic_filebuf_char_dtor(&this->filebuf
);
11152 /* ??_D?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11153 /* ??_D?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11154 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_vbase_dtor
, 4)
11155 void __thiscall
basic_ofstream_char_vbase_dtor(basic_ofstream_char
*this)
11157 TRACE("(%p)\n", this);
11159 basic_ofstream_char_dtor(basic_ofstream_char_to_basic_ios(this));
11160 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(&this->base
));
11163 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_vector_dtor
, 8)
11164 basic_ofstream_char
* __thiscall
basic_ofstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
11166 basic_ofstream_char
*this = basic_ofstream_char_from_basic_ios(base
);
11168 TRACE("(%p %x)\n", this, flags
);
11171 /* we have an array, with the number of elements stored before the first object */
11172 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11174 for(i
=*ptr
-1; i
>=0; i
--)
11175 basic_ofstream_char_vbase_dtor(this+i
);
11176 MSVCRT_operator_delete(ptr
);
11178 basic_ofstream_char_vbase_dtor(this);
11180 MSVCRT_operator_delete(this);
11186 /* ?close@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11187 /* ?close@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11188 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_close
, 4)
11189 void __thiscall
basic_ofstream_char_close(basic_ofstream_char
*this)
11191 TRACE("(%p)\n", this);
11193 if(!basic_filebuf_char_close(&this->filebuf
)) {
11194 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11195 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11199 /* ?is_open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
11200 /* ?is_open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
11201 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_is_open
, 4)
11202 MSVCP_bool __thiscall
basic_ofstream_char_is_open(const basic_ofstream_char
*this)
11204 TRACE("(%p)\n", this);
11205 return basic_filebuf_char_is_open(&this->filebuf
);
11208 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
11209 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
11210 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open
, 16)
11211 void __thiscall
basic_ofstream_char_open(basic_ofstream_char
*this,
11212 const char *name
, int mode
, int prot
)
11214 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
11216 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11217 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11218 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11222 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
11223 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
11224 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_old
, 12)
11225 void __thiscall
basic_ofstream_char_open_old(basic_ofstream_char
*this,
11226 const char *name
, unsigned int mode
)
11228 basic_ofstream_char_open(this, name
, mode
, _SH_DENYNO
);
11231 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
11232 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
11233 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
11234 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
11235 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_wchar
, 16)
11236 void __thiscall
basic_ofstream_char_open_wchar(basic_ofstream_char
*this,
11237 const wchar_t *name
, int mode
, int prot
)
11239 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
11241 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11242 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11243 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11247 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
11248 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
11249 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
11250 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
11251 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_wchar_old
, 12)
11252 void __thiscall
basic_ofstream_char_open_wchar_old(basic_ofstream_char
*this,
11253 const wchar_t *name
, unsigned int mode
)
11255 basic_ofstream_char_open_wchar(this, name
, mode
, _SH_DENYNO
);
11258 /* ?rdbuf@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11259 /* ?rdbuf@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11260 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_rdbuf
, 4)
11261 basic_filebuf_char
* __thiscall
basic_ofstream_char_rdbuf(const basic_ofstream_char
*this)
11263 TRACE("(%p)\n", this);
11264 return (basic_filebuf_char
*)&this->filebuf
;
11267 static inline basic_ios_wchar
* basic_ofstream_wchar_to_basic_ios(basic_ofstream_wchar
*ptr
)
11269 return (basic_ios_wchar
*)((char*)ptr
+basic_ofstream_wchar_vbtable
[1]);
11272 static inline basic_ofstream_wchar
* basic_ofstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
11274 return (basic_ofstream_wchar
*)((char*)ptr
-basic_ofstream_wchar_vbtable
[1]);
11277 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
11278 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
11279 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor
, 8)
11280 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor(basic_ofstream_wchar
*this, MSVCP_bool virt_init
)
11282 basic_ios_wchar
*basic_ios
;
11284 TRACE("(%p %d)\n", this, virt_init
);
11287 this->base
.vbtable
= basic_ofstream_wchar_vbtable
;
11288 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11289 basic_ios_wchar_ctor(basic_ios
);
11291 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11294 basic_filebuf_wchar_ctor(&this->filebuf
);
11295 basic_ostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11296 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_wchar_vtable
;
11300 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
11301 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
11302 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor
, 8)
11303 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor(basic_ofstream_wchar
*this, MSVCP_bool virt_init
)
11305 basic_ofstream_wchar_ctor(this, virt_init
);
11306 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11310 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
11311 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11312 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_file
, 12)
11313 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor_file(
11314 basic_ofstream_wchar
*this, FILE *file
, MSVCP_bool virt_init
)
11316 basic_ios_wchar
*basic_ios
;
11318 TRACE("(%p %p %d)\n", this, file
, virt_init
);
11321 this->base
.vbtable
= basic_ofstream_wchar_vbtable
;
11322 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11323 basic_ios_wchar_ctor(basic_ios
);
11325 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11328 basic_filebuf_wchar_ctor_file(&this->filebuf
, file
);
11329 basic_ostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11330 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_wchar_vtable
;
11334 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
11335 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11336 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_file
, 12)
11337 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor_file(
11338 basic_ofstream_wchar
*this, FILE *file
, MSVCP_bool virt_init
)
11340 basic_ofstream_wchar_ctor_file(this, file
, virt_init
);
11341 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11345 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDHH@Z */
11346 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDHH@Z */
11347 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_name
, 20)
11348 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor_name(basic_ofstream_wchar
*this,
11349 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11351 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
11353 basic_ofstream_wchar_ctor(this, virt_init
);
11355 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11356 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11357 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11362 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PBDHH@Z */
11363 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDHH@Z */
11364 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_name
, 20)
11365 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor_name(basic_ofstream_wchar
*this,
11366 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11368 basic_ofstream_wchar_ctor_name(this, name
, mode
, prot
, virt_init
);
11369 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11373 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
11374 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
11375 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
11376 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
11377 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_name_wchar
, 20)
11378 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor_name_wchar(basic_ofstream_wchar
*this,
11379 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11381 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
11383 basic_ofstream_wchar_ctor(this, virt_init
);
11385 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11386 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11387 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11392 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
11393 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
11394 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
11395 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
11396 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_name_wchar
, 20)
11397 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor_name_wchar(basic_ofstream_wchar
*this,
11398 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11400 basic_ofstream_wchar_ctor_name_wchar(this, name
, mode
, prot
, virt_init
);
11401 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11405 /* ??1?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
11406 /* ??1?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
11407 /* ??1?$basic_ofstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
11408 /* ??1?$basic_ofstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
11409 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_dtor
, 4)
11410 void __thiscall
basic_ofstream_wchar_dtor(basic_ios_wchar
*base
)
11412 basic_ofstream_wchar
*this = basic_ofstream_wchar_from_basic_ios(base
);
11414 TRACE("(%p)\n", this);
11416 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base
));
11417 basic_filebuf_wchar_dtor(&this->filebuf
);
11420 /* ??_D?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11421 /* ??_D?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11422 /* ??_D?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11423 /* ??_D?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11424 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_vbase_dtor
, 4)
11425 void __thiscall
basic_ofstream_wchar_vbase_dtor(basic_ofstream_wchar
*this)
11427 TRACE("(%p)\n", this);
11429 basic_ofstream_wchar_dtor(basic_ofstream_wchar_to_basic_ios(this));
11430 basic_ios_wchar_dtor(basic_ostream_wchar_get_basic_ios(&this->base
));
11433 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_vector_dtor
, 8)
11434 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
11436 basic_ofstream_wchar
*this = basic_ofstream_wchar_from_basic_ios(base
);
11438 TRACE("(%p %x)\n", this, flags
);
11441 /* we have an array, with the number of elements stored before the first object */
11442 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11444 for(i
=*ptr
-1; i
>=0; i
--)
11445 basic_ofstream_wchar_vbase_dtor(this+i
);
11446 MSVCRT_operator_delete(ptr
);
11448 basic_ofstream_wchar_vbase_dtor(this);
11450 MSVCRT_operator_delete(this);
11456 /* ?close@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11457 /* ?close@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11458 /* ?close@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11459 /* ?close@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11460 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_close
, 4)
11461 void __thiscall
basic_ofstream_wchar_close(basic_ofstream_wchar
*this)
11463 TRACE("(%p)\n", this);
11465 if(!basic_filebuf_wchar_close(&this->filebuf
)) {
11466 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11467 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11471 /* ?is_open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
11472 /* ?is_open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
11473 /* ?is_open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
11474 /* ?is_open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
11475 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_is_open
, 4)
11476 MSVCP_bool __thiscall
basic_ofstream_wchar_is_open(const basic_ofstream_wchar
*this)
11478 TRACE("(%p)\n", this);
11479 return basic_filebuf_wchar_is_open(&this->filebuf
);
11482 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
11483 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
11484 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
11485 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
11486 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open
, 16)
11487 void __thiscall
basic_ofstream_wchar_open(basic_ofstream_wchar
*this,
11488 const char *name
, int mode
, int prot
)
11490 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
11492 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11493 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11494 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11498 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
11499 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
11500 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
11501 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
11502 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_old
, 12)
11503 void __thiscall
basic_ofstream_wchar_open_old(basic_ofstream_wchar
*this,
11504 const char *name
, unsigned int mode
)
11506 basic_ofstream_wchar_open(this, name
, mode
, _SH_DENYNO
);
11509 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
11510 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
11511 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
11512 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
11513 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
11514 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
11515 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
11516 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
11517 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_wchar
, 16)
11518 void __thiscall
basic_ofstream_wchar_open_wchar(basic_ofstream_wchar
*this,
11519 const wchar_t *name
, int mode
, int prot
)
11521 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
11523 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11524 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11525 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11529 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
11530 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
11531 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
11532 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
11533 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
11534 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
11535 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
11536 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
11537 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_wchar_old
, 12)
11538 void __thiscall
basic_ofstream_wchar_open_wchar_old(basic_ofstream_wchar
*this,
11539 const wchar_t *name
, unsigned int mode
)
11541 basic_ofstream_wchar_open_wchar(this, name
, mode
, _SH_DENYNO
);
11544 /* ?rdbuf@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
11545 /* ?rdbuf@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
11546 /* ?rdbuf@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
11547 /* ?rdbuf@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
11548 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_rdbuf
, 4)
11549 basic_filebuf_wchar
* __thiscall
basic_ofstream_wchar_rdbuf(const basic_ofstream_wchar
*this)
11551 TRACE("(%p)\n", this);
11552 return (basic_filebuf_wchar
*)&this->filebuf
;
11555 static inline basic_ios_char
* basic_ifstream_char_to_basic_ios(basic_ifstream_char
*ptr
)
11557 return (basic_ios_char
*)((char*)ptr
+basic_ifstream_char_vbtable
[1]);
11560 static inline basic_ifstream_char
* basic_ifstream_char_from_basic_ios(basic_ios_char
*ptr
)
11562 return (basic_ifstream_char
*)((char*)ptr
-basic_ifstream_char_vbtable
[1]);
11565 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
11566 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
11567 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor
, 8)
11568 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor(basic_ifstream_char
*this, MSVCP_bool virt_init
)
11570 basic_ios_char
*basic_ios
;
11572 TRACE("(%p %d)\n", this, virt_init
);
11575 this->base
.vbtable
= basic_ifstream_char_vbtable
;
11576 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11577 basic_ios_char_ctor(basic_ios
);
11579 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11582 basic_filebuf_char_ctor(&this->filebuf
);
11583 basic_istream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11584 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_char_vtable
;
11588 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
11589 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11590 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_file
, 12)
11591 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_file(
11592 basic_ifstream_char
*this, FILE *file
, MSVCP_bool virt_init
)
11594 basic_ios_char
*basic_ios
;
11596 TRACE("(%p %p %d)\n", this, file
, virt_init
);
11599 this->base
.vbtable
= basic_ifstream_char_vbtable
;
11600 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11601 basic_ios_char_ctor(basic_ios
);
11603 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11606 basic_filebuf_char_ctor_file(&this->filebuf
, file
);
11607 basic_istream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11608 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_char_vtable
;
11612 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
11613 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
11614 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name
, 20)
11615 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_name(basic_ifstream_char
*this,
11616 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11618 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
11620 basic_ifstream_char_ctor(this, virt_init
);
11622 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
11623 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11624 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11629 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBDH@Z */
11630 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDH@Z */
11631 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name_old
, 16)
11632 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_name_old(basic_ifstream_char
*this,
11633 const char *name
, int mode
, MSVCP_bool virt_init
)
11635 return basic_ifstream_char_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
11638 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
11639 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
11640 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
11641 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
11642 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name_wchar
, 20)
11643 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_name_wchar(basic_ifstream_char
*this,
11644 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11646 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
11648 basic_ifstream_char_ctor(this, virt_init
);
11650 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
11651 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11652 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11657 /* ??1?$basic_ifstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
11658 /* ??1?$basic_ifstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
11659 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_dtor
, 4)
11660 void __thiscall
basic_ifstream_char_dtor(basic_ios_char
*base
)
11662 basic_ifstream_char
*this = basic_ifstream_char_from_basic_ios(base
);
11664 TRACE("(%p)\n", this);
11666 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base
));
11667 basic_filebuf_char_dtor(&this->filebuf
);
11670 /* ??_D?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11671 /* ??_D?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11672 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_vbase_dtor
, 4)
11673 void __thiscall
basic_ifstream_char_vbase_dtor(basic_ifstream_char
*this)
11675 TRACE("(%p)\n", this);
11677 basic_ifstream_char_dtor(basic_ifstream_char_to_basic_ios(this));
11678 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base
));
11681 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_vector_dtor
, 8)
11682 basic_ifstream_char
* __thiscall
basic_ifstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
11684 basic_ifstream_char
*this = basic_ifstream_char_from_basic_ios(base
);
11686 TRACE("(%p %x)\n", this, flags
);
11689 /* we have an array, with the number of elements stored before the first object */
11690 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11692 for(i
=*ptr
-1; i
>=0; i
--)
11693 basic_ifstream_char_vbase_dtor(this+i
);
11694 MSVCRT_operator_delete(ptr
);
11696 basic_ifstream_char_vbase_dtor(this);
11698 MSVCRT_operator_delete(this);
11704 /* ?close@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11705 /* ?close@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11706 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_close
, 4)
11707 void __thiscall
basic_ifstream_char_close(basic_ifstream_char
*this)
11709 TRACE("(%p)\n", this);
11711 if(!basic_filebuf_char_close(&this->filebuf
)) {
11712 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11713 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11717 /* ?is_open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
11718 /* ?is_open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
11719 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_is_open
, 4)
11720 MSVCP_bool __thiscall
basic_ifstream_char_is_open(const basic_ifstream_char
*this)
11722 TRACE("(%p)\n", this);
11723 return basic_filebuf_char_is_open(&this->filebuf
);
11726 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
11727 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
11728 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open
, 16)
11729 void __thiscall
basic_ifstream_char_open(basic_ifstream_char
*this,
11730 const char *name
, int mode
, int prot
)
11732 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
11734 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
11735 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11736 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11740 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
11741 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
11742 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_old
, 12)
11743 void __thiscall
basic_ifstream_char_open_old(basic_ifstream_char
*this,
11744 const char *name
, unsigned int mode
)
11746 basic_ifstream_char_open(this, name
, mode
, _SH_DENYNO
);
11749 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
11750 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
11751 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
11752 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
11753 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_wchar
, 16)
11754 void __thiscall
basic_ifstream_char_open_wchar(basic_ifstream_char
*this,
11755 const wchar_t *name
, int mode
, int prot
)
11757 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
11759 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
11760 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11761 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11765 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
11766 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
11767 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
11768 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
11769 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_wchar_old
, 12)
11770 void __thiscall
basic_ifstream_char_open_wchar_old(basic_ifstream_char
*this,
11771 const wchar_t *name
, unsigned int mode
)
11773 basic_ifstream_char_open_wchar(this, name
, mode
, _SH_DENYNO
);
11776 /* ?rdbuf@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11777 /* ?rdbuf@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11778 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_rdbuf
, 4)
11779 basic_filebuf_char
* __thiscall
basic_ifstream_char_rdbuf(const basic_ifstream_char
*this)
11781 TRACE("(%p)\n", this);
11782 return (basic_filebuf_char
*)&this->filebuf
;
11785 static inline basic_ios_wchar
* basic_ifstream_wchar_to_basic_ios(basic_ifstream_wchar
*ptr
)
11787 return (basic_ios_wchar
*)((char*)ptr
+basic_ifstream_wchar_vbtable
[1]);
11790 static inline basic_ifstream_wchar
* basic_ifstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
11792 return (basic_ifstream_wchar
*)((char*)ptr
-basic_ifstream_wchar_vbtable
[1]);
11795 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
11796 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
11797 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor
, 8)
11798 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor(basic_ifstream_wchar
*this, MSVCP_bool virt_init
)
11800 basic_ios_wchar
*basic_ios
;
11802 TRACE("(%p %d)\n", this, virt_init
);
11805 this->base
.vbtable
= basic_ifstream_wchar_vbtable
;
11806 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
11807 basic_ios_wchar_ctor(basic_ios
);
11809 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
11812 basic_filebuf_wchar_ctor(&this->filebuf
);
11813 basic_istream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11814 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_wchar_vtable
;
11818 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
11819 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
11820 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor
, 8)
11821 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor(basic_ifstream_wchar
*this, MSVCP_bool virt_init
)
11823 basic_ifstream_wchar_ctor(this, virt_init
);
11824 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
11828 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
11829 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11830 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_file
, 12)
11831 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_file(
11832 basic_ifstream_wchar
*this, FILE *file
, MSVCP_bool virt_init
)
11834 basic_ios_wchar
*basic_ios
;
11836 TRACE("(%p %p %d)\n", this, file
, virt_init
);
11839 this->base
.vbtable
= basic_ifstream_wchar_vbtable
;
11840 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
11841 basic_ios_wchar_ctor(basic_ios
);
11843 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
11846 basic_filebuf_wchar_ctor_file(&this->filebuf
, file
);
11847 basic_istream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11848 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_wchar_vtable
;
11852 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
11853 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11854 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_file
, 12)
11855 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_file(
11856 basic_ifstream_wchar
*this, FILE *file
, MSVCP_bool virt_init
)
11858 basic_ifstream_wchar_ctor_file(this, file
, virt_init
);
11859 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
11863 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDHH@Z */
11864 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDHH@Z */
11865 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name
, 20)
11866 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_name(basic_ifstream_wchar
*this,
11867 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11869 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
11871 basic_ifstream_wchar_ctor(this, virt_init
);
11873 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
11874 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
11875 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11880 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBDHH@Z */
11881 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDHH@Z */
11882 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name
, 20)
11883 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_name(basic_ifstream_wchar
*this,
11884 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11886 basic_ifstream_wchar_ctor_name(this, name
, mode
, prot
, virt_init
);
11887 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
11891 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDH@Z */
11892 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDH@Z */
11893 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name_old
, 16)
11894 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_name_old(basic_ifstream_wchar
*this,
11895 const char *name
, int mode
, MSVCP_bool virt_init
)
11897 return basic_ifstream_wchar_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
11900 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBDH@Z */
11901 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDH@Z */
11902 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name_old
, 16)
11903 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_name_old(basic_ifstream_wchar
*this,
11904 const char *name
, int mode
, MSVCP_bool virt_init
)
11906 return basic_ifstream_short_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
11909 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
11910 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
11911 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
11912 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
11913 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name_wchar
, 20)
11914 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_name_wchar(basic_ifstream_wchar
*this,
11915 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11917 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
11919 basic_ifstream_wchar_ctor(this, virt_init
);
11921 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
11922 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
11923 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11928 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
11929 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
11930 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
11931 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
11932 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name_wchar
, 20)
11933 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_name_wchar(basic_ifstream_wchar
*this,
11934 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
11936 basic_ifstream_wchar_ctor_name_wchar(this, name
, mode
, prot
, virt_init
);
11937 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
11941 /* ??1?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
11942 /* ??1?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
11943 /* ??1?$basic_ifstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
11944 /* ??1?$basic_ifstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
11945 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_dtor
, 4)
11946 void __thiscall
basic_ifstream_wchar_dtor(basic_ios_wchar
*base
)
11948 basic_ifstream_wchar
*this = basic_ifstream_wchar_from_basic_ios(base
);
11950 TRACE("(%p)\n", this);
11952 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base
));
11953 basic_filebuf_wchar_dtor(&this->filebuf
);
11956 /* ??_D?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11957 /* ??_D?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11958 /* ??_D?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11959 /* ??_D?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11960 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_vbase_dtor
, 4)
11961 void __thiscall
basic_ifstream_wchar_vbase_dtor(basic_ifstream_wchar
*this)
11963 TRACE("(%p)\n", this);
11965 basic_ifstream_wchar_dtor(basic_ifstream_wchar_to_basic_ios(this));
11966 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base
));
11969 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_vector_dtor
, 8)
11970 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
11972 basic_ifstream_wchar
*this = basic_ifstream_wchar_from_basic_ios(base
);
11974 TRACE("(%p %x)\n", this, flags
);
11977 /* we have an array, with the number of elements stored before the first object */
11978 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11980 for(i
=*ptr
-1; i
>=0; i
--)
11981 basic_ifstream_wchar_vbase_dtor(this+i
);
11982 MSVCRT_operator_delete(ptr
);
11984 basic_ifstream_wchar_vbase_dtor(this);
11986 MSVCRT_operator_delete(this);
11992 /* ?close@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11993 /* ?close@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11994 /* ?close@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11995 /* ?close@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11996 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_close
, 4)
11997 void __thiscall
basic_ifstream_wchar_close(basic_ifstream_wchar
*this)
11999 TRACE("(%p)\n", this);
12001 if(!basic_filebuf_wchar_close(&this->filebuf
)) {
12002 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12003 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12007 /* ?is_open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
12008 /* ?is_open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
12009 /* ?is_open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
12010 /* ?is_open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
12011 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_is_open
, 4)
12012 MSVCP_bool __thiscall
basic_ifstream_wchar_is_open(const basic_ifstream_wchar
*this)
12014 TRACE("(%p)\n", this);
12015 return basic_filebuf_wchar_is_open(&this->filebuf
);
12018 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
12019 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
12020 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
12021 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
12022 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open
, 16)
12023 void __thiscall
basic_ifstream_wchar_open(basic_ifstream_wchar
*this,
12024 const char *name
, int mode
, int prot
)
12026 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12028 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12029 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12030 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12034 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
12035 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
12036 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
12037 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
12038 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_old
, 12)
12039 void __thiscall
basic_ifstream_wchar_open_old(basic_ifstream_wchar
*this,
12040 const char *name
, unsigned int mode
)
12042 basic_ifstream_wchar_open(this, name
, mode
, _SH_DENYNO
);
12045 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
12046 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
12047 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
12048 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
12049 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
12050 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
12051 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
12052 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
12053 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_wchar
, 16)
12054 void __thiscall
basic_ifstream_wchar_open_wchar(basic_ifstream_wchar
*this,
12055 const wchar_t *name
, int mode
, int prot
)
12057 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
12059 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12060 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12061 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12065 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
12066 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
12067 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
12068 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
12069 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
12070 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
12071 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
12072 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
12073 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_wchar_old
, 12)
12074 void __thiscall
basic_ifstream_wchar_open_wchar_old(basic_ifstream_wchar
*this,
12075 const wchar_t *name
, unsigned int mode
)
12077 basic_ifstream_wchar_open_wchar(this, name
, mode
, _SH_DENYNO
);
12080 /* ?rdbuf@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
12081 /* ?rdbuf@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
12082 /* ?rdbuf@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
12083 /* ?rdbuf@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
12084 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_rdbuf
, 4)
12085 basic_filebuf_wchar
* __thiscall
basic_ifstream_wchar_rdbuf(const basic_ifstream_wchar
*this)
12087 TRACE("(%p)\n", this);
12088 return (basic_filebuf_wchar
*)&this->filebuf
;
12091 static inline basic_ios_char
* basic_fstream_char_to_basic_ios(basic_fstream_char
*ptr
)
12093 return (basic_ios_char
*)((char*)ptr
+basic_fstream_char_vbtable1
[1]);
12096 static inline basic_fstream_char
* basic_fstream_char_from_basic_ios(basic_ios_char
*ptr
)
12098 return (basic_fstream_char
*)((char*)ptr
-basic_fstream_char_vbtable1
[1]);
12101 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
12102 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
12103 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor
, 8)
12104 basic_fstream_char
* __thiscall
basic_fstream_char_ctor(basic_fstream_char
*this, MSVCP_bool virt_init
)
12106 basic_ios_char
*basic_ios
;
12108 TRACE("(%p %d)\n", this, virt_init
);
12111 this->base
.base1
.vbtable
= basic_fstream_char_vbtable1
;
12112 this->base
.base2
.vbtable
= basic_fstream_char_vbtable2
;
12113 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12114 basic_ios_char_ctor(basic_ios
);
12116 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12119 basic_filebuf_char_ctor(&this->filebuf
);
12120 basic_iostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12121 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_char_vtable
;
12125 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
12126 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12127 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_file
, 12)
12128 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_file(basic_fstream_char
*this,
12129 FILE *file
, MSVCP_bool virt_init
)
12131 basic_ios_char
*basic_ios
;
12133 TRACE("(%p %p %d)\n", this, file
, virt_init
);
12136 this->base
.base1
.vbtable
= basic_fstream_char_vbtable1
;
12137 this->base
.base2
.vbtable
= basic_fstream_char_vbtable2
;
12138 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12139 basic_ios_char_ctor(basic_ios
);
12141 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12144 basic_filebuf_char_ctor_file(&this->filebuf
, file
);
12145 basic_iostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12146 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_char_vtable
;
12150 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
12151 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
12152 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name
, 20)
12153 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_name(basic_fstream_char
*this,
12154 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
12156 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
12158 basic_fstream_char_ctor(this, virt_init
);
12160 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
, prot
)) {
12161 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12162 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12167 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBDH@Z */
12168 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDH@Z */
12169 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name_noprot
, 16)
12170 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_name_noprot(basic_fstream_char
*this,
12171 const char *name
, int mode
, MSVCP_bool virt_init
)
12173 return basic_fstream_char_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12176 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
12177 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
12178 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
12179 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
12180 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name_wchar
, 20)
12181 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_name_wchar(basic_fstream_char
*this,
12182 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
12184 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
12186 basic_fstream_char_ctor(this, virt_init
);
12188 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12189 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12190 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12195 /* ??1?$basic_fstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
12196 /* ??1?$basic_fstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
12197 DEFINE_THISCALL_WRAPPER(basic_fstream_char_dtor
, 4)
12198 void __thiscall
basic_fstream_char_dtor(basic_ios_char
*base
)
12200 basic_fstream_char
*this = basic_fstream_char_from_basic_ios(base
);
12202 TRACE("(%p)\n", this);
12204 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base
));
12205 basic_filebuf_char_dtor(&this->filebuf
);
12208 /* ??_D?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
12209 /* ??_D?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
12210 DEFINE_THISCALL_WRAPPER(basic_fstream_char_vbase_dtor
, 4)
12211 void __thiscall
basic_fstream_char_vbase_dtor(basic_fstream_char
*this)
12213 TRACE("(%p)\n", this);
12215 basic_fstream_char_dtor(basic_fstream_char_to_basic_ios(this));
12216 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base
.base1
));
12219 DEFINE_THISCALL_WRAPPER(basic_fstream_char_vector_dtor
, 8)
12220 basic_fstream_char
* __thiscall
basic_fstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
12222 basic_fstream_char
*this = basic_fstream_char_from_basic_ios(base
);
12224 TRACE("(%p %x)\n", this, flags
);
12227 /* we have an array, with the number of elements stored before the first object */
12228 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12230 for(i
=*ptr
-1; i
>=0; i
--)
12231 basic_fstream_char_vbase_dtor(this+i
);
12232 MSVCRT_operator_delete(ptr
);
12234 basic_fstream_char_vbase_dtor(this);
12236 MSVCRT_operator_delete(this);
12242 /* ?close@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
12243 /* ?close@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
12244 DEFINE_THISCALL_WRAPPER(basic_fstream_char_close
, 4)
12245 void __thiscall
basic_fstream_char_close(basic_fstream_char
*this)
12247 TRACE("(%p)\n", this);
12249 if(!basic_filebuf_char_close(&this->filebuf
)) {
12250 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12251 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12255 /* ?is_open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
12256 /* ?is_open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
12257 DEFINE_THISCALL_WRAPPER(basic_fstream_char_is_open
, 4)
12258 MSVCP_bool __thiscall
basic_fstream_char_is_open(const basic_fstream_char
*this)
12260 TRACE("(%p)\n", this);
12261 return basic_filebuf_char_is_open(&this->filebuf
);
12264 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
12265 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
12266 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open
, 16)
12267 void __thiscall
basic_fstream_char_open(basic_fstream_char
*this,
12268 const char *name
, int mode
, int prot
)
12270 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12272 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
, prot
)) {
12273 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12274 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12278 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
12279 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
12280 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_old
, 12)
12281 void __thiscall
basic_fstream_char_open_old(basic_fstream_char
*this,
12282 const char *name
, unsigned int mode
)
12284 basic_fstream_char_open(this, name
, mode
, _SH_DENYNO
);
12287 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
12288 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
12289 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
12290 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
12291 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_wchar
, 16)
12292 void __thiscall
basic_fstream_char_open_wchar(basic_fstream_char
*this,
12293 const wchar_t *name
, int mode
, int prot
)
12295 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
12297 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12298 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12299 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12303 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
12304 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
12305 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
12306 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
12307 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_wchar_old
, 12)
12308 void __thiscall
basic_fstream_char_open_wchar_old(basic_fstream_char
*this,
12309 const wchar_t *name
, unsigned int mode
)
12311 basic_fstream_char_open_wchar(this, name
, mode
, _SH_DENYNO
);
12314 /* ?rdbuf@?$basic_fstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
12315 /* ?rdbuf@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
12316 DEFINE_THISCALL_WRAPPER(basic_fstream_char_rdbuf
, 4)
12317 basic_filebuf_char
* __thiscall
basic_fstream_char_rdbuf(const basic_fstream_char
*this)
12319 TRACE("(%p)\n", this);
12320 return (basic_filebuf_char
*)&this->filebuf
;
12323 static inline basic_ios_wchar
* basic_fstream_wchar_to_basic_ios(basic_fstream_wchar
*ptr
)
12325 return (basic_ios_wchar
*)((char*)ptr
+basic_fstream_wchar_vbtable1
[1]);
12328 static inline basic_fstream_wchar
* basic_fstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
12330 return (basic_fstream_wchar
*)((char*)ptr
-basic_fstream_wchar_vbtable1
[1]);
12333 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
12334 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
12335 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor
, 8)
12336 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor(basic_fstream_wchar
*this, MSVCP_bool virt_init
)
12338 basic_ios_wchar
*basic_ios
;
12340 TRACE("(%p %d)\n", this, virt_init
);
12343 this->base
.base1
.vbtable
= basic_fstream_wchar_vbtable1
;
12344 this->base
.base2
.vbtable
= basic_fstream_wchar_vbtable2
;
12345 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12346 basic_ios_wchar_ctor(basic_ios
);
12348 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12351 basic_filebuf_wchar_ctor(&this->filebuf
);
12352 basic_iostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12353 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_wchar_vtable
;
12357 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
12358 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
12359 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor
, 8)
12360 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor(basic_fstream_wchar
*this, MSVCP_bool virt_init
)
12362 basic_fstream_wchar_ctor(this, virt_init
);
12363 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12367 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
12368 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12369 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_file
, 12)
12370 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_file(basic_fstream_wchar
*this,
12371 FILE *file
, MSVCP_bool virt_init
)
12373 basic_ios_wchar
*basic_ios
;
12375 TRACE("(%p %p %d)\n", this, file
, virt_init
);
12378 this->base
.base1
.vbtable
= basic_fstream_wchar_vbtable1
;
12379 this->base
.base2
.vbtable
= basic_fstream_wchar_vbtable2
;
12380 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12381 basic_ios_wchar_ctor(basic_ios
);
12383 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12386 basic_filebuf_wchar_ctor_file(&this->filebuf
, file
);
12387 basic_iostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12388 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_wchar_vtable
;
12392 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
12393 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12394 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_file
, 12)
12395 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_file(basic_fstream_wchar
*this,
12396 FILE *file
, MSVCP_bool virt_init
)
12398 basic_fstream_wchar_ctor_file(this, file
, virt_init
);
12399 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12403 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
12404 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
12405 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name
, 20)
12406 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_name(basic_fstream_wchar
*this,
12407 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
12409 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
12411 basic_fstream_wchar_ctor(this, virt_init
);
12413 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
, prot
)) {
12414 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12415 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12420 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
12421 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
12422 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name
, 20)
12423 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_name(basic_fstream_wchar
*this,
12424 const char *name
, int mode
, int prot
, MSVCP_bool virt_init
)
12426 basic_fstream_wchar_ctor_name(this, name
, mode
, prot
, virt_init
);
12427 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12431 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDH@Z */
12432 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name_noprot
, 16)
12433 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_name_noprot(basic_fstream_wchar
*this,
12434 const char *name
, int mode
, MSVCP_bool virt_init
)
12436 return basic_fstream_wchar_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12439 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBDH@Z */
12440 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDH@Z */
12441 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name_noprot
, 16)
12442 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_name_noprot(basic_fstream_wchar
*this,
12443 const char *name
, int mode
, MSVCP_bool virt_init
)
12445 return basic_fstream_short_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12448 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
12449 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
12450 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
12451 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
12452 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name_wchar
, 20)
12453 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_name_wchar(basic_fstream_wchar
*this,
12454 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
12456 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
12458 basic_fstream_wchar_ctor(this, virt_init
);
12460 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12461 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12462 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12467 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
12468 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
12469 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
12470 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
12471 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name_wchar
, 20)
12472 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_name_wchar(basic_fstream_wchar
*this,
12473 const wchar_t *name
, int mode
, int prot
, MSVCP_bool virt_init
)
12475 basic_fstream_wchar_ctor_name_wchar(this, name
, mode
, prot
, virt_init
);
12476 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12480 /* ??1?$basic_fstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
12481 /* ??1?$basic_fstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
12482 /* ??1?$basic_fstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
12483 /* ??1?$basic_fstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
12484 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_dtor
, 4)
12485 void __thiscall
basic_fstream_wchar_dtor(basic_ios_wchar
*base
)
12487 basic_fstream_wchar
*this = basic_fstream_wchar_from_basic_ios(base
);
12489 TRACE("(%p)\n", this);
12491 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(&this->base
));
12492 basic_filebuf_wchar_dtor(&this->filebuf
);
12495 /* ??_D?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
12496 /* ??_D?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
12497 /* ??_D?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
12498 /* ??_D?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
12499 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_vbase_dtor
, 4)
12500 void __thiscall
basic_fstream_wchar_vbase_dtor(basic_fstream_wchar
*this)
12502 TRACE("(%p)\n", this);
12504 basic_fstream_wchar_dtor(basic_fstream_wchar_to_basic_ios(this));
12505 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base
.base1
));
12508 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_vector_dtor
, 8)
12509 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
12511 basic_fstream_wchar
*this = basic_fstream_wchar_from_basic_ios(base
);
12513 TRACE("(%p %x)\n", this, flags
);
12516 /* we have an array, with the number of elements stored before the first object */
12517 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12519 for(i
=*ptr
-1; i
>=0; i
--)
12520 basic_fstream_wchar_vbase_dtor(this+i
);
12521 MSVCRT_operator_delete(ptr
);
12523 basic_fstream_wchar_vbase_dtor(this);
12525 MSVCRT_operator_delete(this);
12531 /* ?close@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
12532 /* ?close@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
12533 /* ?close@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
12534 /* ?close@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
12535 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_close
, 4)
12536 void __thiscall
basic_fstream_wchar_close(basic_fstream_wchar
*this)
12538 TRACE("(%p)\n", this);
12540 if(!basic_filebuf_wchar_close(&this->filebuf
)) {
12541 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12542 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12546 /* ?is_open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
12547 /* ?is_open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
12548 /* ?is_open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
12549 /* ?is_open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
12550 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_is_open
, 4)
12551 MSVCP_bool __thiscall
basic_fstream_wchar_is_open(const basic_fstream_wchar
*this)
12553 TRACE("(%p)\n", this);
12554 return basic_filebuf_wchar_is_open(&this->filebuf
);
12557 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
12558 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
12559 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
12560 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
12561 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open
, 16)
12562 void __thiscall
basic_fstream_wchar_open(basic_fstream_wchar
*this,
12563 const char *name
, int mode
, int prot
)
12565 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12567 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
, prot
)) {
12568 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12569 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12573 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
12574 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
12575 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
12576 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
12577 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_old
, 12)
12578 void __thiscall
basic_fstream_wchar_open_old(basic_fstream_wchar
*this,
12579 const char *name
, unsigned int mode
)
12581 basic_fstream_wchar_open(this, name
, mode
, _SH_DENYNO
);
12584 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
12585 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
12586 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
12587 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
12588 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
12589 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
12590 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
12591 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
12592 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_wchar
, 16)
12593 void __thiscall
basic_fstream_wchar_open_wchar(basic_fstream_wchar
*this,
12594 const wchar_t *name
, int mode
, int prot
)
12596 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
12598 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12599 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12600 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12604 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
12605 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
12606 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
12607 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
12608 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
12609 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
12610 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
12611 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
12612 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_wchar_old
, 12)
12613 void __thiscall
basic_fstream_wchar_open_wchar_old(basic_fstream_wchar
*this,
12614 const wchar_t *name
, unsigned int mode
)
12616 basic_fstream_wchar_open_wchar(this, name
, mode
, _SH_DENYNO
);
12619 /* ?rdbuf@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
12620 /* ?rdbuf@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
12621 /* ?rdbuf@?$basic_fstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
12622 /* ?rdbuf@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
12623 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_rdbuf
, 4)
12624 basic_filebuf_wchar
* __thiscall
basic_fstream_wchar_rdbuf(const basic_fstream_wchar
*this)
12626 TRACE("(%p)\n", this);
12627 return (basic_filebuf_wchar
*)&this->filebuf
;
12630 static inline basic_ios_char
* basic_ostringstream_char_to_basic_ios(basic_ostringstream_char
*ptr
)
12632 return (basic_ios_char
*)((char*)ptr
+basic_ostringstream_char_vbtable
[1]);
12635 static inline basic_ostringstream_char
* basic_ostringstream_char_from_basic_ios(basic_ios_char
*ptr
)
12637 return (basic_ostringstream_char
*)((char*)ptr
-basic_ostringstream_char_vbtable
[1]);
12640 /* ??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 */
12641 /* ??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 */
12642 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor_str
, 16)
12643 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_ctor_str(basic_ostringstream_char
*this,
12644 const basic_string_char
*str
, int mode
, MSVCP_bool virt_init
)
12646 basic_ios_char
*basic_ios
;
12648 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
12651 this->base
.vbtable
= basic_ostringstream_char_vbtable
;
12652 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
12653 basic_ios_char_ctor(basic_ios
);
12655 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
12658 basic_stringbuf_char_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_out
);
12659 basic_ostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
12660 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_char_vtable
;
12664 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
12665 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
12666 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor_mode
, 12)
12667 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_ctor_mode(
12668 basic_ostringstream_char
*this, int mode
, MSVCP_bool virt_init
)
12670 basic_ios_char
*basic_ios
;
12672 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
12675 this->base
.vbtable
= basic_ostringstream_char_vbtable
;
12676 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
12677 basic_ios_char_ctor(basic_ios
);
12679 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
12682 basic_stringbuf_char_ctor_mode(&this->strbuf
, mode
|OPENMODE_out
);
12683 basic_ostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
12684 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_char_vtable
;
12688 /* ??_F?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
12689 /* ??_F?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
12690 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor
, 4)
12691 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_ctor(
12692 basic_ostringstream_char
*this)
12694 return basic_ostringstream_char_ctor_mode(this, 0, TRUE
);
12697 /* ??1?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
12698 /* ??1?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
12699 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_dtor
, 4)
12700 void __thiscall
basic_ostringstream_char_dtor(basic_ios_char
*base
)
12702 basic_ostringstream_char
*this = basic_ostringstream_char_from_basic_ios(base
);
12704 TRACE("(%p)\n", this);
12706 basic_stringbuf_char_dtor(&this->strbuf
);
12707 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base
));
12710 /* ??_D?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
12711 /* ??_D?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
12712 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_vbase_dtor
, 4)
12713 void __thiscall
basic_ostringstream_char_vbase_dtor(basic_ostringstream_char
*this)
12715 TRACE("(%p)\n", this);
12717 basic_ostringstream_char_dtor(basic_ostringstream_char_to_basic_ios(this));
12718 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(&this->base
));
12721 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_vector_dtor
, 8)
12722 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
12724 basic_ostringstream_char
*this = basic_ostringstream_char_from_basic_ios(base
);
12726 TRACE("(%p %x)\n", this, flags
);
12729 /* we have an array, with the number of elements stored before the first object */
12730 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12732 for(i
=*ptr
-1; i
>=0; i
--)
12733 basic_ostringstream_char_vbase_dtor(this+i
);
12734 MSVCRT_operator_delete(ptr
);
12736 basic_ostringstream_char_vbase_dtor(this);
12738 MSVCRT_operator_delete(this);
12744 /* ?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 */
12745 /* ?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 */
12746 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_rdbuf
, 4)
12747 basic_stringbuf_char
* __thiscall
basic_ostringstream_char_rdbuf(const basic_ostringstream_char
*this)
12749 TRACE("(%p)\n", this);
12750 return (basic_stringbuf_char
*)&this->strbuf
;
12753 /* ?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 */
12754 /* ?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 */
12755 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_str_set
, 8)
12756 void __thiscall
basic_ostringstream_char_str_set(basic_ostringstream_char
*this, const basic_string_char
*str
)
12758 TRACE("(%p %p)\n", this, str
);
12759 basic_stringbuf_char_str_set(&this->strbuf
, str
);
12762 /* ?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 */
12763 /* ?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 */
12764 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_str_get
, 8)
12765 basic_string_char
* __thiscall
basic_ostringstream_char_str_get(const basic_ostringstream_char
*this, basic_string_char
*ret
)
12767 TRACE("(%p %p)\n", this, ret
);
12768 return basic_stringbuf_char_str_get(&this->strbuf
, ret
);
12771 static inline basic_ios_wchar
* basic_ostringstream_wchar_to_basic_ios(basic_ostringstream_wchar
*ptr
)
12773 return (basic_ios_wchar
*)((char*)ptr
+basic_ostringstream_wchar_vbtable
[1]);
12776 static inline basic_ostringstream_wchar
* basic_ostringstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
12778 return (basic_ostringstream_wchar
*)((char*)ptr
-basic_ostringstream_wchar_vbtable
[1]);
12781 /* ??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 */
12782 /* ??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 */
12783 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor_str
, 16)
12784 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_ctor_str(basic_ostringstream_wchar
*this,
12785 const basic_string_wchar
*str
, int mode
, MSVCP_bool virt_init
)
12787 basic_ios_wchar
*basic_ios
;
12789 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
12792 this->base
.vbtable
= basic_ostringstream_wchar_vbtable
;
12793 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
12794 basic_ios_wchar_ctor(basic_ios
);
12796 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
12799 basic_stringbuf_wchar_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_out
);
12800 basic_ostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
12801 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_wchar_vtable
;
12805 /* ??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 */
12806 /* ??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 */
12807 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor_str
, 16)
12808 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_short_ctor_str(basic_ostringstream_wchar
*this,
12809 const basic_string_wchar
*str
, int mode
, MSVCP_bool virt_init
)
12811 basic_ostringstream_wchar_ctor_str(this, str
, mode
, virt_init
);
12812 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ostringstream_short_vtable
;
12816 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
12817 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
12818 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor_mode
, 12)
12819 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_ctor_mode(
12820 basic_ostringstream_wchar
*this, int mode
, MSVCP_bool virt_init
)
12822 basic_ios_wchar
*basic_ios
;
12824 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
12827 this->base
.vbtable
= basic_ostringstream_wchar_vbtable
;
12828 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
12829 basic_ios_wchar_ctor(basic_ios
);
12831 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
12834 basic_stringbuf_wchar_ctor_mode(&this->strbuf
, mode
|OPENMODE_out
);
12835 basic_ostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
12836 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_wchar_vtable
;
12840 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
12841 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
12842 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor_mode
, 12)
12843 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_short_ctor_mode(
12844 basic_ostringstream_wchar
*this, int mode
, MSVCP_bool virt_init
)
12846 basic_ostringstream_wchar_ctor_mode(this, mode
, virt_init
);
12847 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ostringstream_short_vtable
;
12851 /* ??_F?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
12852 /* ??_F?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
12853 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor
, 4)
12854 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_ctor(
12855 basic_ostringstream_wchar
*this)
12857 return basic_ostringstream_wchar_ctor_mode(this, 0, TRUE
);
12860 /* ??_F?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
12861 /* ??_F?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
12862 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor
, 4)
12863 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_short_ctor(
12864 basic_ostringstream_wchar
*this)
12866 return basic_ostringstream_short_ctor_mode(this, 0, TRUE
);
12869 /* ??1?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
12870 /* ??1?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
12871 /* ??1?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
12872 /* ??1?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
12873 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_dtor
, 4)
12874 void __thiscall
basic_ostringstream_wchar_dtor(basic_ios_wchar
*base
)
12876 basic_ostringstream_wchar
*this = basic_ostringstream_wchar_from_basic_ios(base
);
12878 TRACE("(%p)\n", this);
12880 basic_stringbuf_wchar_dtor(&this->strbuf
);
12881 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base
));
12884 /* ??_D?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
12885 /* ??_D?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
12886 /* ??_D?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
12887 /* ??_D?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
12888 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_vbase_dtor
, 4)
12889 void __thiscall
basic_ostringstream_wchar_vbase_dtor(basic_ostringstream_wchar
*this)
12891 TRACE("(%p)\n", this);
12893 basic_ostringstream_wchar_dtor(basic_ostringstream_wchar_to_basic_ios(this));
12894 basic_ios_wchar_dtor(basic_ostream_wchar_get_basic_ios(&this->base
));
12897 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_vector_dtor
, 8)
12898 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
12900 basic_ostringstream_wchar
*this = basic_ostringstream_wchar_from_basic_ios(base
);
12902 TRACE("(%p %x)\n", this, flags
);
12905 /* we have an array, with the number of elements stored before the first object */
12906 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12908 for(i
=*ptr
-1; i
>=0; i
--)
12909 basic_ostringstream_wchar_vbase_dtor(this+i
);
12910 MSVCRT_operator_delete(ptr
);
12912 basic_ostringstream_wchar_vbase_dtor(this);
12914 MSVCRT_operator_delete(this);
12920 /* ?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 */
12921 /* ?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 */
12922 /* ?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 */
12923 /* ?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 */
12924 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_rdbuf
, 4)
12925 basic_stringbuf_wchar
* __thiscall
basic_ostringstream_wchar_rdbuf(const basic_ostringstream_wchar
*this)
12927 TRACE("(%p)\n", this);
12928 return (basic_stringbuf_wchar
*)&this->strbuf
;
12931 /* ?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 */
12932 /* ?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 */
12933 /* ?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 */
12934 /* ?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 */
12935 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_str_set
, 8)
12936 void __thiscall
basic_ostringstream_wchar_str_set(basic_ostringstream_wchar
*this, const basic_string_wchar
*str
)
12938 TRACE("(%p %p)\n", this, str
);
12939 basic_stringbuf_wchar_str_set(&this->strbuf
, str
);
12942 /* ?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 */
12943 /* ?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 */
12944 /* ?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 */
12945 /* ?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 */
12946 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_str_get
, 8)
12947 basic_string_wchar
* __thiscall
basic_ostringstream_wchar_str_get(const basic_ostringstream_wchar
*this, basic_string_wchar
*ret
)
12949 TRACE("(%p %p)\n", this, ret
);
12950 return basic_stringbuf_wchar_str_get(&this->strbuf
, ret
);
12953 static inline basic_ios_char
* basic_istringstream_char_to_basic_ios(basic_istringstream_char
*ptr
)
12955 return (basic_ios_char
*)((char*)ptr
+basic_istringstream_char_vbtable
[1]);
12958 static inline basic_istringstream_char
* basic_istringstream_char_from_basic_ios(basic_ios_char
*ptr
)
12960 return (basic_istringstream_char
*)((char*)ptr
-basic_istringstream_char_vbtable
[1]);
12963 /* ??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 */
12964 /* ??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 */
12965 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor_str
, 16)
12966 basic_istringstream_char
* __thiscall
basic_istringstream_char_ctor_str(basic_istringstream_char
*this,
12967 const basic_string_char
*str
, int mode
, MSVCP_bool virt_init
)
12969 basic_ios_char
*basic_ios
;
12971 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
12974 this->base
.vbtable
= basic_istringstream_char_vbtable
;
12975 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12976 basic_ios_char_ctor(basic_ios
);
12978 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12981 basic_stringbuf_char_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_in
);
12982 basic_istream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
12983 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_char_vtable
;
12987 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
12988 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
12989 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor_mode
, 12)
12990 basic_istringstream_char
* __thiscall
basic_istringstream_char_ctor_mode(
12991 basic_istringstream_char
*this, int mode
, MSVCP_bool virt_init
)
12993 basic_ios_char
*basic_ios
;
12995 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
12998 this->base
.vbtable
= basic_istringstream_char_vbtable
;
12999 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
13000 basic_ios_char_ctor(basic_ios
);
13002 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
13005 basic_stringbuf_char_ctor_mode(&this->strbuf
, mode
|OPENMODE_in
);
13006 basic_istream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13007 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_char_vtable
;
13011 /* ??_F?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13012 /* ??_F?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13013 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor
, 4)
13014 basic_istringstream_char
* __thiscall
basic_istringstream_char_ctor(
13015 basic_istringstream_char
*this)
13017 return basic_istringstream_char_ctor_mode(this, 0, TRUE
);
13020 /* ??1?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
13021 /* ??1?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
13022 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_dtor
, 4)
13023 void __thiscall
basic_istringstream_char_dtor(basic_ios_char
*base
)
13025 basic_istringstream_char
*this = basic_istringstream_char_from_basic_ios(base
);
13027 TRACE("(%p)\n", this);
13029 basic_stringbuf_char_dtor(&this->strbuf
);
13030 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base
));
13033 /* ??_D?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13034 /* ??_D?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13035 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_vbase_dtor
, 4)
13036 void __thiscall
basic_istringstream_char_vbase_dtor(basic_istringstream_char
*this)
13038 TRACE("(%p)\n", this);
13040 basic_istringstream_char_dtor(basic_istringstream_char_to_basic_ios(this));
13041 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base
));
13044 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_vector_dtor
, 8)
13045 basic_istringstream_char
* __thiscall
basic_istringstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
13047 basic_istringstream_char
*this = basic_istringstream_char_from_basic_ios(base
);
13049 TRACE("(%p %x)\n", this, flags
);
13052 /* we have an array, with the number of elements stored before the first object */
13053 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13055 for(i
=*ptr
-1; i
>=0; i
--)
13056 basic_istringstream_char_vbase_dtor(this+i
);
13057 MSVCRT_operator_delete(ptr
);
13059 basic_istringstream_char_vbase_dtor(this);
13061 MSVCRT_operator_delete(this);
13067 /* ?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 */
13068 /* ?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 */
13069 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_rdbuf
, 4)
13070 basic_stringbuf_char
* __thiscall
basic_istringstream_char_rdbuf(const basic_istringstream_char
*this)
13072 TRACE("(%p)\n", this);
13073 return (basic_stringbuf_char
*)&this->strbuf
;
13076 /* ?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 */
13077 /* ?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 */
13078 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_str_set
, 8)
13079 void __thiscall
basic_istringstream_char_str_set(basic_istringstream_char
*this, const basic_string_char
*str
)
13081 TRACE("(%p %p)\n", this, str
);
13082 basic_stringbuf_char_str_set(&this->strbuf
, str
);
13085 /* ?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 */
13086 /* ?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 */
13087 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_str_get
, 8)
13088 basic_string_char
* __thiscall
basic_istringstream_char_str_get(const basic_istringstream_char
*this, basic_string_char
*ret
)
13090 TRACE("(%p %p)\n", this, ret
);
13091 return basic_stringbuf_char_str_get(&this->strbuf
, ret
);
13094 static inline basic_ios_wchar
* basic_istringstream_wchar_to_basic_ios(basic_istringstream_wchar
*ptr
)
13096 return (basic_ios_wchar
*)((char*)ptr
+basic_istringstream_wchar_vbtable
[1]);
13099 static inline basic_istringstream_wchar
* basic_istringstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
13101 return (basic_istringstream_wchar
*)((char*)ptr
-basic_istringstream_wchar_vbtable
[1]);
13104 /* ??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 */
13105 /* ??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 */
13106 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor_str
, 16)
13107 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_ctor_str(basic_istringstream_wchar
*this,
13108 const basic_string_wchar
*str
, int mode
, MSVCP_bool virt_init
)
13110 basic_ios_wchar
*basic_ios
;
13112 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13115 this->base
.vbtable
= basic_istringstream_wchar_vbtable
;
13116 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13117 basic_ios_wchar_ctor(basic_ios
);
13119 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13122 basic_stringbuf_wchar_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_in
);
13123 basic_istream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13124 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_wchar_vtable
;
13128 /* ??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 */
13129 /* ??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 */
13130 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor_str
, 16)
13131 basic_istringstream_wchar
* __thiscall
basic_istringstream_short_ctor_str(basic_istringstream_wchar
*this,
13132 const basic_string_wchar
*str
, int mode
, MSVCP_bool virt_init
)
13134 basic_istringstream_wchar_ctor_str(this, str
, mode
, virt_init
);
13135 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_istringstream_short_vtable
;
13139 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
13140 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
13141 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor_mode
, 12)
13142 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_ctor_mode(
13143 basic_istringstream_wchar
*this, int mode
, MSVCP_bool virt_init
)
13145 basic_ios_wchar
*basic_ios
;
13147 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13150 this->base
.vbtable
= basic_istringstream_wchar_vbtable
;
13151 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13152 basic_ios_wchar_ctor(basic_ios
);
13154 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13157 basic_stringbuf_wchar_ctor_mode(&this->strbuf
, mode
|OPENMODE_in
);
13158 basic_istream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13159 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_wchar_vtable
;
13163 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
13164 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
13165 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor_mode
, 12)
13166 basic_istringstream_wchar
* __thiscall
basic_istringstream_short_ctor_mode(
13167 basic_istringstream_wchar
*this, int mode
, MSVCP_bool virt_init
)
13169 basic_istringstream_wchar_ctor_mode(this, mode
, virt_init
);
13170 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_istringstream_short_vtable
;
13174 /* ??_F?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13175 /* ??_F?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13176 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor
, 4)
13177 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_ctor(
13178 basic_istringstream_wchar
*this)
13180 return basic_istringstream_wchar_ctor_mode(this, 0, TRUE
);
13183 /* ??_F?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13184 /* ??_F?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13185 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor
, 4)
13186 basic_istringstream_wchar
* __thiscall
basic_istringstream_short_ctor(
13187 basic_istringstream_wchar
*this)
13189 return basic_istringstream_short_ctor_mode(this, 0, TRUE
);
13192 /* ??1?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
13193 /* ??1?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
13194 /* ??1?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
13195 /* ??1?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
13196 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_dtor
, 4)
13197 void __thiscall
basic_istringstream_wchar_dtor(basic_ios_wchar
*base
)
13199 basic_istringstream_wchar
*this = basic_istringstream_wchar_from_basic_ios(base
);
13201 TRACE("(%p)\n", this);
13203 basic_stringbuf_wchar_dtor(&this->strbuf
);
13204 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base
));
13207 /* ??_D?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13208 /* ??_D?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13209 /* ??_D?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13210 /* ??_D?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13211 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_vbase_dtor
, 4)
13212 void __thiscall
basic_istringstream_wchar_vbase_dtor(basic_istringstream_wchar
*this)
13214 TRACE("(%p)\n", this);
13216 basic_istringstream_wchar_dtor(basic_istringstream_wchar_to_basic_ios(this));
13217 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base
));
13220 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_vector_dtor
, 8)
13221 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
13223 basic_istringstream_wchar
*this = basic_istringstream_wchar_from_basic_ios(base
);
13225 TRACE("(%p %x)\n", this, flags
);
13228 /* we have an array, with the number of elements stored before the first object */
13229 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13231 for(i
=*ptr
-1; i
>=0; i
--)
13232 basic_istringstream_wchar_vbase_dtor(this+i
);
13233 MSVCRT_operator_delete(ptr
);
13235 basic_istringstream_wchar_vbase_dtor(this);
13237 MSVCRT_operator_delete(this);
13243 /* ?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 */
13244 /* ?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 */
13245 /* ?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 */
13246 /* ?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 */
13247 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_rdbuf
, 4)
13248 basic_stringbuf_wchar
* __thiscall
basic_istringstream_wchar_rdbuf(const basic_istringstream_wchar
*this)
13250 TRACE("(%p)\n", this);
13251 return (basic_stringbuf_wchar
*)&this->strbuf
;
13254 /* ?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 */
13255 /* ?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 */
13256 /* ?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 */
13257 /* ?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 */
13258 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_str_set
, 8)
13259 void __thiscall
basic_istringstream_wchar_str_set(basic_istringstream_wchar
*this, const basic_string_wchar
*str
)
13261 TRACE("(%p %p)\n", this, str
);
13262 basic_stringbuf_wchar_str_set(&this->strbuf
, str
);
13265 /* ?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 */
13266 /* ?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 */
13267 /* ?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 */
13268 /* ?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 */
13269 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_str_get
, 8)
13270 basic_string_wchar
* __thiscall
basic_istringstream_wchar_str_get(const basic_istringstream_wchar
*this, basic_string_wchar
*ret
)
13272 TRACE("(%p %p)\n", this, ret
);
13273 return basic_stringbuf_wchar_str_get(&this->strbuf
, ret
);
13276 static inline basic_ios_char
* basic_stringstream_char_to_basic_ios(basic_stringstream_char
*ptr
)
13278 return (basic_ios_char
*)((char*)ptr
+basic_stringstream_char_vbtable1
[1]);
13281 static inline basic_stringstream_char
* basic_stringstream_char_from_basic_ios(basic_ios_char
*ptr
)
13283 return (basic_stringstream_char
*)((char*)ptr
-basic_stringstream_char_vbtable1
[1]);
13286 /* ??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 */
13287 /* ??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 */
13288 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor_str
, 16)
13289 basic_stringstream_char
* __thiscall
basic_stringstream_char_ctor_str(basic_stringstream_char
*this,
13290 const basic_string_char
*str
, int mode
, MSVCP_bool virt_init
)
13292 basic_ios_char
*basic_ios
;
13294 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13297 this->base
.base1
.vbtable
= basic_stringstream_char_vbtable1
;
13298 this->base
.base2
.vbtable
= basic_stringstream_char_vbtable2
;
13299 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13300 basic_ios_char_ctor(basic_ios
);
13302 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13305 basic_stringbuf_char_ctor_str(&this->strbuf
, str
, mode
);
13306 basic_iostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13307 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_char_vtable
;
13311 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
13312 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
13313 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor_mode
, 12)
13314 basic_stringstream_char
* __thiscall
basic_stringstream_char_ctor_mode(
13315 basic_stringstream_char
*this, int mode
, MSVCP_bool virt_init
)
13317 basic_ios_char
*basic_ios
;
13319 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13322 this->base
.base1
.vbtable
= basic_stringstream_char_vbtable1
;
13323 this->base
.base2
.vbtable
= basic_stringstream_char_vbtable2
;
13324 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13325 basic_ios_char_ctor(basic_ios
);
13327 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13330 basic_stringbuf_char_ctor_mode(&this->strbuf
, mode
);
13331 basic_iostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13332 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_char_vtable
;
13336 /* ??_F?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13337 /* ??_F?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13338 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor
, 4)
13339 basic_stringstream_char
* __thiscall
basic_stringstream_char_ctor(
13340 basic_stringstream_char
*this)
13342 return basic_stringstream_char_ctor_mode(
13343 this, OPENMODE_out
|OPENMODE_in
, TRUE
);
13346 /* ??1?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
13347 /* ??1?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
13348 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_dtor
, 4)
13349 void __thiscall
basic_stringstream_char_dtor(basic_ios_char
*base
)
13351 basic_stringstream_char
*this = basic_stringstream_char_from_basic_ios(base
);
13353 TRACE("(%p)\n", this);
13355 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base
));
13356 basic_stringbuf_char_dtor(&this->strbuf
);
13359 /* ??_D?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13360 /* ??_D?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13361 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_vbase_dtor
, 4)
13362 void __thiscall
basic_stringstream_char_vbase_dtor(basic_stringstream_char
*this)
13364 TRACE("(%p)\n", this);
13366 basic_stringstream_char_dtor(basic_stringstream_char_to_basic_ios(this));
13367 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base
.base1
));
13370 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_vector_dtor
, 8)
13371 basic_stringstream_char
* __thiscall
basic_stringstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
13373 basic_stringstream_char
*this = basic_stringstream_char_from_basic_ios(base
);
13375 TRACE("(%p %x)\n", this, flags
);
13378 /* we have an array, with the number of elements stored before the first object */
13379 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13381 for(i
=*ptr
-1; i
>=0; i
--)
13382 basic_stringstream_char_vbase_dtor(this+i
);
13383 MSVCRT_operator_delete(ptr
);
13385 basic_stringstream_char_vbase_dtor(this);
13387 MSVCRT_operator_delete(this);
13393 /* ?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 */
13394 /* ?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 */
13395 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_rdbuf
, 4)
13396 basic_stringbuf_char
* __thiscall
basic_stringstream_char_rdbuf(const basic_stringstream_char
*this)
13398 TRACE("(%p)\n", this);
13399 return (basic_stringbuf_char
*)&this->strbuf
;
13402 /* ?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 */
13403 /* ?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 */
13404 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_str_set
, 8)
13405 void __thiscall
basic_stringstream_char_str_set(basic_stringstream_char
*this, const basic_string_char
*str
)
13407 TRACE("(%p %p)\n", this, str
);
13408 basic_stringbuf_char_str_set(&this->strbuf
, str
);
13411 /* ?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 */
13412 /* ?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 */
13413 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_str_get
, 8)
13414 basic_string_char
* __thiscall
basic_stringstream_char_str_get(const basic_stringstream_char
*this, basic_string_char
*ret
)
13416 TRACE("(%p %p)\n", this, ret
);
13417 return basic_stringbuf_char_str_get(&this->strbuf
, ret
);
13420 static inline basic_ios_wchar
* basic_stringstream_wchar_to_basic_ios(basic_stringstream_wchar
*ptr
)
13422 return (basic_ios_wchar
*)((char*)ptr
+basic_stringstream_wchar_vbtable1
[1]);
13425 static inline basic_stringstream_wchar
* basic_stringstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
13427 return (basic_stringstream_wchar
*)((char*)ptr
-basic_stringstream_wchar_vbtable1
[1]);
13430 /* ??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 */
13431 /* ??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 */
13432 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor_str
, 16)
13433 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_ctor_str(basic_stringstream_wchar
*this,
13434 const basic_string_wchar
*str
, int mode
, MSVCP_bool virt_init
)
13436 basic_ios_wchar
*basic_ios
;
13438 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13441 this->base
.base1
.vbtable
= basic_stringstream_wchar_vbtable1
;
13442 this->base
.base2
.vbtable
= basic_stringstream_wchar_vbtable2
;
13443 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13444 basic_ios_wchar_ctor(basic_ios
);
13446 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13449 basic_stringbuf_wchar_ctor_str(&this->strbuf
, str
, mode
);
13450 basic_iostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13451 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_wchar_vtable
;
13455 /* ??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 */
13456 /* ??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 */
13457 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor_str
, 16)
13458 basic_stringstream_wchar
* __thiscall
basic_stringstream_short_ctor_str(basic_stringstream_wchar
*this,
13459 const basic_string_wchar
*str
, int mode
, MSVCP_bool virt_init
)
13461 basic_stringstream_wchar_ctor_str(this, str
, mode
, virt_init
);
13462 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_stringstream_short_vtable
;
13466 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
13467 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
13468 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor_mode
, 12)
13469 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_ctor_mode(
13470 basic_stringstream_wchar
*this, int mode
, MSVCP_bool virt_init
)
13472 basic_ios_wchar
*basic_ios
;
13474 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13477 this->base
.base1
.vbtable
= basic_stringstream_wchar_vbtable1
;
13478 this->base
.base2
.vbtable
= basic_stringstream_wchar_vbtable2
;
13479 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13480 basic_ios_wchar_ctor(basic_ios
);
13482 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13485 basic_stringbuf_wchar_ctor_mode(&this->strbuf
, mode
);
13486 basic_iostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13487 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_wchar_vtable
;
13491 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
13492 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
13493 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor_mode
, 12)
13494 basic_stringstream_wchar
* __thiscall
basic_stringstream_short_ctor_mode(
13495 basic_stringstream_wchar
*this, int mode
, MSVCP_bool virt_init
)
13497 basic_stringstream_wchar_ctor_mode(this, mode
, virt_init
);
13498 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_stringstream_short_vtable
;
13502 /* ??_F?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13503 /* ??_F?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13504 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor
, 4)
13505 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_ctor(
13506 basic_stringstream_wchar
*this)
13508 return basic_stringstream_wchar_ctor_mode(
13509 this, OPENMODE_out
|OPENMODE_in
, TRUE
);
13512 /* ??_F?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13513 /* ??_F?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13514 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor
, 4)
13515 basic_stringstream_wchar
* __thiscall
basic_stringstream_short_ctor(
13516 basic_stringstream_wchar
*this)
13518 return basic_stringstream_short_ctor_mode(
13519 this, OPENMODE_out
|OPENMODE_in
, TRUE
);
13522 /* ??1?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
13523 /* ??1?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
13524 /* ??1?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
13525 /* ??1?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
13526 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_dtor
, 4)
13527 void __thiscall
basic_stringstream_wchar_dtor(basic_ios_wchar
*base
)
13529 basic_stringstream_wchar
*this = basic_stringstream_wchar_from_basic_ios(base
);
13531 TRACE("(%p)\n", this);
13533 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(&this->base
));
13534 basic_stringbuf_wchar_dtor(&this->strbuf
);
13537 /* ??_D?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13538 /* ??_D?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13539 /* ??_D?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13540 /* ??_D?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13541 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_vbase_dtor
, 4)
13542 void __thiscall
basic_stringstream_wchar_vbase_dtor(basic_stringstream_wchar
*this)
13544 TRACE("(%p)\n", this);
13546 basic_stringstream_wchar_dtor(basic_stringstream_wchar_to_basic_ios(this));
13547 basic_ios_wchar_dtor(basic_istream_wchar_get_basic_ios(&this->base
.base1
));
13550 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_vector_dtor
, 8)
13551 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
13553 basic_stringstream_wchar
*this = basic_stringstream_wchar_from_basic_ios(base
);
13555 TRACE("(%p %x)\n", this, flags
);
13558 /* we have an array, with the number of elements stored before the first object */
13559 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13561 for(i
=*ptr
-1; i
>=0; i
--)
13562 basic_stringstream_wchar_vbase_dtor(this+i
);
13563 MSVCRT_operator_delete(ptr
);
13565 basic_stringstream_wchar_vbase_dtor(this);
13567 MSVCRT_operator_delete(this);
13573 /* ?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 */
13574 /* ?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 */
13575 /* ?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 */
13576 /* ?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 */
13577 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_rdbuf
, 4)
13578 basic_stringbuf_wchar
* __thiscall
basic_stringstream_wchar_rdbuf(const basic_stringstream_wchar
*this)
13580 TRACE("(%p)\n", this);
13581 return (basic_stringbuf_wchar
*)&this->strbuf
;
13584 /* ?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 */
13585 /* ?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 */
13586 /* ?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 */
13587 /* ?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 */
13588 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_str_set
, 8)
13589 void __thiscall
basic_stringstream_wchar_str_set(basic_stringstream_wchar
*this, const basic_string_wchar
*str
)
13591 TRACE("(%p %p)\n", this, str
);
13592 basic_stringbuf_wchar_str_set(&this->strbuf
, str
);
13595 /* ?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 */
13596 /* ?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 */
13597 /* ?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 */
13598 /* ?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 */
13599 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_str_get
, 8)
13600 basic_string_wchar
* __thiscall
basic_stringstream_wchar_str_get(const basic_stringstream_wchar
*this, basic_string_wchar
*ret
)
13602 TRACE("(%p %p)\n", this, ret
);
13603 return basic_stringbuf_wchar_str_get(&this->strbuf
, ret
);
13606 /* ?_Init@strstreambuf@std@@IAEXHPAD0H@Z */
13607 /* ?_Init@strstreambuf@std@@IEAAX_JPEAD1H@Z */
13608 #if STREAMSIZE_BITS == 64
13609 DEFINE_THISCALL_WRAPPER(strstreambuf__Init
, 24)
13611 DEFINE_THISCALL_WRAPPER(strstreambuf__Init
, 20)
13613 void __thiscall
strstreambuf__Init(strstreambuf
*this, streamsize len
, char *g
, char *p
, int mode
)
13615 TRACE("(%p %s %p %p %d)\n", this, wine_dbgstr_longlong(len
), g
, p
, mode
);
13617 this->minsize
= 32;
13618 this->endsave
= NULL
;
13619 this->strmode
= mode
;
13620 this->palloc
= NULL
;
13621 this->pfree
= NULL
;
13624 this->strmode
|= STRSTATE_Dynamic
;
13625 if(len
> this->minsize
)
13626 this->minsize
= len
;
13627 this->seekhigh
= NULL
;
13636 this->seekhigh
= g
+len
;
13637 basic_streambuf_char_setg(&this->base
, g
, g
, p
? p
: this->seekhigh
);
13639 basic_streambuf_char_setp(&this->base
, p
, this->seekhigh
);
13642 /* ??0strstreambuf@std@@QAE@PACH0@Z */
13643 /* ??0strstreambuf@std@@QEAA@PEAC_J0@Z */
13644 /* ??0strstreambuf@std@@QAE@PADH0@Z */
13645 /* ??0strstreambuf@std@@QEAA@PEAD_J0@Z */
13646 /* ??0strstreambuf@std@@QAE@PAEH0@Z */
13647 /* ??0strstreambuf@std@@QEAA@PEAE_J0@Z */
13648 #if STREAMSIZE_BITS == 64
13649 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get_put
, 20)
13651 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get_put
, 16)
13653 strstreambuf
* __thiscall
strstreambuf_ctor_get_put(strstreambuf
*this, char *g
, streamsize len
, char *p
)
13655 TRACE("(%p %p %s %p)\n", this, g
, wine_dbgstr_longlong(len
), p
);
13657 basic_streambuf_char_ctor(&this->base
);
13658 this->base
.vtable
= &MSVCP_strstreambuf_vtable
;
13660 strstreambuf__Init(this, len
, g
, p
, 0);
13664 /* ??0strstreambuf@std@@QAE@H@Z */
13665 /* ??0strstreambuf@std@@QEAA@_J@Z */
13666 #if STREAMSIZE_BITS == 64
13667 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_len
, 12)
13669 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_len
, 8)
13671 strstreambuf
* __thiscall
strstreambuf_ctor_len(strstreambuf
*this, streamsize len
)
13673 return strstreambuf_ctor_get_put(this, NULL
, len
, NULL
);
13676 /* ??0strstreambuf@std@@QAE@P6APAXI@ZP6AXPAX@Z@Z */
13677 /* ??0strstreambuf@std@@QEAA@P6APEAX_K@ZP6AXPEAX@Z@Z */
13678 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_alloc
, 12)
13679 strstreambuf
* __thiscall
strstreambuf_ctor_alloc(strstreambuf
*this, void* (__cdecl
*palloc
)(MSVCP_size_t
), void (__cdecl
*pfree
)(void*))
13681 TRACE("(%p %p %p)\n", this, palloc
, pfree
);
13683 strstreambuf_ctor_get_put(this, NULL
, 0, NULL
);
13684 this->palloc
= palloc
;
13685 this->pfree
= pfree
;
13689 /* ??0strstreambuf@std@@QAE@PBCH@Z */
13690 /* ??0strstreambuf@std@@QEAA@PEBC_J@Z */
13691 /* ??0strstreambuf@std@@QAE@PBDH@Z */
13692 /* ??0strstreambuf@std@@QEAA@PEBD_J@Z */
13693 /* ??0strstreambuf@std@@QAE@PBEH@Z */
13694 /* ??0strstreambuf@std@@QEAA@PEBE_J@Z */
13695 #if STREAMSIZE_BITS == 64
13696 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get
, 16)
13698 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get
, 12)
13700 strstreambuf
* __thiscall
strstreambuf_ctor_get(strstreambuf
*this, const char *g
, streamsize len
)
13702 TRACE("(%p %p %s)\n", this, g
, wine_dbgstr_longlong(len
));
13704 strstreambuf_ctor_get_put(this, (char*)g
, len
, NULL
);
13705 this->strmode
|= STRSTATE_Constant
;
13709 /* ??_Fstrstreambuf@std@@QAEXXZ */
13710 /* ??_Fstrstreambuf@std@@QEAAXXZ */
13711 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor
, 4)
13712 strstreambuf
* __thiscall
strstreambuf_ctor(strstreambuf
*this)
13714 return strstreambuf_ctor_get_put(this, NULL
, 0, NULL
);
13717 /* ?_Tidy@strstreambuf@std@@IAEXXZ */
13718 /* ?_Tidy@strstreambuf@std@@IEAAXXZ */
13719 DEFINE_THISCALL_WRAPPER(strstreambuf__Tidy
, 4)
13720 void __thiscall
strstreambuf__Tidy(strstreambuf
*this)
13722 TRACE("(%p)\n", this);
13724 if((this->strmode
& STRSTATE_Allocated
) && !(this->strmode
& STRSTATE_Frozen
)) {
13726 this->pfree(basic_streambuf_char_eback(&this->base
));
13728 MSVCRT_operator_delete(basic_streambuf_char_eback(&this->base
));
13731 this->endsave
= NULL
;
13732 this->seekhigh
= NULL
;
13733 this->strmode
&= ~(STRSTATE_Allocated
| STRSTATE_Frozen
);
13734 basic_streambuf_char_setg(&this->base
, NULL
, NULL
, NULL
);
13735 basic_streambuf_char_setp(&this->base
, NULL
, NULL
);
13738 /* ??1strstreambuf@std@@UAE@XZ */
13739 /* ??1strstreambuf@std@@UEAA@XZ */
13740 DEFINE_THISCALL_WRAPPER(strstreambuf_dtor
, 4)
13741 void __thiscall
strstreambuf_dtor(strstreambuf
*this)
13743 TRACE("(%p)\n", this);
13745 strstreambuf__Tidy(this);
13746 basic_streambuf_char_dtor(&this->base
);
13749 DEFINE_THISCALL_WRAPPER(strstreambuf_vector_dtor
, 8)
13750 strstreambuf
* __thiscall
strstreambuf_vector_dtor(strstreambuf
*this, unsigned int flags
)
13752 TRACE("(%p %x)\n", this, flags
);
13754 /* we have an array, with the number of elements stored before the first object */
13755 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13757 for(i
=*ptr
-1; i
>=0; i
--)
13758 strstreambuf_dtor(this+i
);
13759 MSVCRT_operator_delete(ptr
);
13761 strstreambuf_dtor(this);
13763 MSVCRT_operator_delete(this);
13769 /* ?freeze@strstreambuf@std@@QAEX_N@Z */
13770 /* ?freeze@strstreambuf@std@@QEAAX_N@Z */
13771 DEFINE_THISCALL_WRAPPER(strstreambuf_freeze
, 8)
13772 void __thiscall
strstreambuf_freeze(strstreambuf
*this, MSVCP_bool freeze
)
13774 TRACE("(%p %d)\n", this, freeze
);
13776 if(!freeze
== !(this->strmode
& STRSTATE_Frozen
))
13780 this->strmode
|= STRSTATE_Frozen
;
13781 this->endsave
= basic_streambuf_char_epptr(&this->base
);
13782 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
),
13783 basic_streambuf_char_pptr(&this->base
), basic_streambuf_char_eback(&this->base
));
13785 this->strmode
&= ~STRSTATE_Frozen
;
13786 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
),
13787 basic_streambuf_char_pptr(&this->base
), this->endsave
);
13791 /* ?str@strstreambuf@std@@QAEPADXZ */
13792 /* ?str@strstreambuf@std@@QEAAPEADXZ */
13793 DEFINE_THISCALL_WRAPPER(strstreambuf_str
, 4)
13794 char* __thiscall
strstreambuf_str(strstreambuf
*this)
13796 TRACE("(%p)\n", this);
13798 strstreambuf_freeze(this, TRUE
);
13799 return basic_streambuf_char_gptr(&this->base
);
13802 /* ?pcount@strstreambuf@std@@QBEHXZ */
13803 /* ?pcount@strstreambuf@std@@QEBA_JXZ */
13804 DEFINE_THISCALL_WRAPPER(strstreambuf_pcount
, 4)
13805 streamsize __thiscall
strstreambuf_pcount(const strstreambuf
*this)
13807 char *ppos
= basic_streambuf_char_pptr(&this->base
);
13809 TRACE("(%p)\n", this);
13811 return ppos
? ppos
-basic_streambuf_char_pbase(&this->base
) : 0;
13814 /* ?overflow@strstreambuf@std@@MAEHH@Z */
13815 /* ?overflow@strstreambuf@std@@MEAAHH@Z */
13816 DEFINE_THISCALL_WRAPPER(strstreambuf_overflow
, 8)
13817 int __thiscall
strstreambuf_overflow(strstreambuf
*this, int c
)
13819 MSVCP_size_t old_size
, size
;
13822 TRACE("(%p %d)\n", this, c
);
13827 if(this->strmode
& STRSTATE_Frozen
)
13830 ptr
= basic_streambuf_char_pptr(&this->base
);
13831 if(ptr
&& ptr
<basic_streambuf_char_epptr(&this->base
))
13832 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = c
);
13834 if(!(this->strmode
& STRSTATE_Dynamic
) || (this->strmode
& STRSTATE_Constant
))
13837 ptr
= basic_streambuf_char_eback(&this->base
);
13838 old_size
= ptr
? basic_streambuf_char_epptr(&this->base
) - ptr
: 0;
13840 size
= old_size
+ old_size
/2;
13841 if(size
< this->minsize
)
13842 size
= this->minsize
;
13845 buf
= this->palloc(size
);
13847 buf
= MSVCRT_operator_new(size
);
13851 memcpy(buf
, ptr
, old_size
);
13852 if(this->strmode
& STRSTATE_Allocated
) {
13856 MSVCRT_operator_delete(ptr
);
13859 this->strmode
|= STRSTATE_Allocated
;
13861 this->seekhigh
= buf
;
13862 basic_streambuf_char_setp(&this->base
, buf
, buf
+size
);
13863 basic_streambuf_char_setg(&this->base
, buf
, buf
, buf
);
13865 this->seekhigh
= this->seekhigh
-ptr
+buf
;
13866 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
)-ptr
+buf
,
13867 basic_streambuf_char_pptr(&this->base
)-ptr
+buf
, buf
+size
);
13868 basic_streambuf_char_setg(&this->base
, buf
, basic_streambuf_char_gptr(&this->base
)-ptr
+buf
,
13869 basic_streambuf_char_pptr(&this->base
));
13872 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = c
);
13875 /* ?pbackfail@strstreambuf@std@@MAEHH@Z */
13876 /* ?pbackfail@strstreambuf@std@@MEAAHH@Z */
13877 DEFINE_THISCALL_WRAPPER(strstreambuf_pbackfail
, 8)
13878 int __thiscall
strstreambuf_pbackfail(strstreambuf
*this, int c
)
13880 char *ptr
= basic_streambuf_char_gptr(&this->base
);
13882 TRACE("(%p %d)\n", this, c
);
13884 if(ptr
<=basic_streambuf_char_eback(&this->base
)
13885 || ((this->strmode
& STRSTATE_Constant
) && c
!=ptr
[-1]))
13888 basic_streambuf_char_gbump(&this->base
, -1);
13891 if(this->strmode
& STRSTATE_Constant
)
13892 return (unsigned char)c
;
13894 return (unsigned char)(ptr
[0] = c
);
13897 /* ?seekoff@strstreambuf@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
13898 /* ?seekoff@strstreambuf@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
13899 /* ?seekoff@strstreambuf@std@@MAE?AV?$fpos@H@2@JHH@Z */
13900 /* ?seekoff@strstreambuf@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
13901 #if STREAMOFF_BITS == 64
13902 DEFINE_THISCALL_WRAPPER(strstreambuf_seekoff
, 24)
13904 DEFINE_THISCALL_WRAPPER(strstreambuf_seekoff
, 20)
13906 fpos_int
* __thiscall
strstreambuf_seekoff(strstreambuf
*this, fpos_int
*ret
, streamoff off
, int way
, int mode
)
13908 char *eback
= basic_streambuf_char_eback(&this->base
);
13909 char *pptr
= basic_streambuf_char_pptr(&this->base
);
13910 char *gptr
= basic_streambuf_char_gptr(&this->base
);
13912 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
13917 if(pptr
> this->seekhigh
)
13918 this->seekhigh
= pptr
;
13920 if((mode
& OPENMODE_in
) && gptr
) {
13921 if(way
==SEEKDIR_cur
&& !(mode
& OPENMODE_out
))
13923 else if(way
== SEEKDIR_end
)
13924 off
+= this->seekhigh
-eback
;
13925 else if(way
!= SEEKDIR_beg
)
13928 if(off
<0 || off
>this->seekhigh
-eback
) {
13931 basic_streambuf_char_gbump(&this->base
, eback
-gptr
+off
);
13932 if((mode
& OPENMODE_out
) && pptr
) {
13933 basic_streambuf_char_setp_next(&this->base
, eback
,
13934 gptr
, basic_streambuf_char_epptr(&this->base
));
13937 }else if((mode
& OPENMODE_out
) && pptr
) {
13938 if(way
== SEEKDIR_cur
)
13940 else if(way
== SEEKDIR_end
)
13941 off
+= this->seekhigh
-eback
;
13942 else if(way
!= SEEKDIR_beg
)
13945 if(off
<0 || off
>this->seekhigh
-eback
)
13948 basic_streambuf_char_pbump(&this->base
, eback
-pptr
+off
);
13957 /* ?seekpos@strstreambuf@std@@MAE?AV?$fpos@H@2@V32@H@Z */
13958 /* ?seekpos@strstreambuf@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
13959 DEFINE_THISCALL_WRAPPER(strstreambuf_seekpos
, 36)
13960 fpos_int
* __thiscall
strstreambuf_seekpos(strstreambuf
*this, fpos_int
*ret
, fpos_int pos
, int mode
)
13962 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_int(&pos
), mode
);
13964 if(pos
.off
==-1 && pos
.pos
==0 && pos
.state
==0) {
13969 return strstreambuf_seekoff(this, ret
, pos
.pos
+pos
.off
, SEEKDIR_beg
, mode
);
13972 /* ?underflow@strstreambuf@std@@MAEHXZ */
13973 /* ?underflow@strstreambuf@std@@MEAAHXZ */
13974 DEFINE_THISCALL_WRAPPER(strstreambuf_underflow
, 4)
13975 int __thiscall
strstreambuf_underflow(strstreambuf
*this)
13977 char *gptr
= basic_streambuf_char_gptr(&this->base
);
13980 TRACE("(%p)\n", this);
13985 if(gptr
< basic_streambuf_char_egptr(&this->base
))
13986 return (unsigned char)(*gptr
);
13988 pptr
= basic_streambuf_char_gptr(&this->base
);
13989 if(pptr
> this->seekhigh
)
13990 this->seekhigh
= pptr
;
13992 if(this->seekhigh
<= gptr
)
13995 basic_streambuf_char_setg(&this->base
, basic_streambuf_char_eback(&this->base
),
13996 gptr
, this->seekhigh
);
13997 return (unsigned char)(*gptr
);
14000 static inline basic_ios_char
* ostrstream_to_basic_ios(ostrstream
*ptr
)
14002 return (basic_ios_char
*)((char*)ptr
+ostrstream_vbtable
[1]);
14005 static inline ostrstream
* ostrstream_from_basic_ios(basic_ios_char
*ptr
)
14007 return (ostrstream
*)((char*)ptr
-ostrstream_vbtable
[1]);
14010 /* ??0ostrstream@std@@QAE@PADHH@Z */
14011 #if STREAMSIZE_BITS == 64
14012 DEFINE_THISCALL_WRAPPER(ostrstream_ctor
, 24)
14014 DEFINE_THISCALL_WRAPPER(ostrstream_ctor
, 20)
14016 ostrstream
* __thiscall
ostrstream_ctor(ostrstream
*this, char *buf
, streamsize size
, int mode
, MSVCP_bool virt_init
)
14018 basic_ios_char
*basic_ios
;
14020 TRACE("(%p %p %s %d %d)\n", this, buf
, wine_dbgstr_longlong(size
), mode
, virt_init
);
14023 this->base
.vbtable
= ostrstream_vbtable
;
14024 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
14025 basic_ios_char_ctor(basic_ios
);
14027 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
14030 strstreambuf_ctor_get_put(&this->buf
, buf
, size
,
14031 buf
&& (mode
& OPENMODE_app
) ? buf
+strlen(buf
) : buf
);
14032 basic_ostream_char_ctor(&this->base
, &this->buf
.base
, FALSE
, FALSE
);
14033 basic_ios
->base
.vtable
= &MSVCP_ostrstream_vtable
;
14037 /* ??1ostrstream@std@@UAE@XZ */
14038 /* ??1ostrstream@std@@UEAA@XZ */
14039 DEFINE_THISCALL_WRAPPER(ostrstream_dtor
, 4)
14040 void __thiscall
ostrstream_dtor(basic_ios_char
*base
)
14042 ostrstream
*this = ostrstream_from_basic_ios(base
);
14044 TRACE("(%p)\n", this);
14046 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base
));
14047 strstreambuf_dtor(&this->buf
);
14050 static void ostrstream_vbase_dtor(ostrstream
*this)
14052 TRACE("(%p)\n", this);
14054 ostrstream_dtor(ostrstream_to_basic_ios(this));
14055 basic_ios_char_dtor(basic_ostream_char_get_basic_ios(&this->base
));
14058 DEFINE_THISCALL_WRAPPER(ostrstream_vector_dtor
, 8)
14059 ostrstream
* __thiscall
ostrstream_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
14061 ostrstream
*this = ostrstream_from_basic_ios(base
);
14063 TRACE("(%p %x)\n", this, flags
);
14066 /* we have an array, with the number of elements stored before the first object */
14067 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
14069 for(i
=*ptr
-1; i
>=0; i
--)
14070 ostrstream_vbase_dtor(this+i
);
14071 MSVCRT_operator_delete(ptr
);
14073 ostrstream_vbase_dtor(this);
14075 MSVCRT_operator_delete(this);
14081 static inline istrstream
* istrstream_from_basic_ios(basic_ios_char
*ptr
)
14083 return (istrstream
*)((char*)ptr
-istrstream_vbtable
[1]);
14086 /* ??1istrstream@std@@UAE@XZ */
14087 /* ??1istrstream@std@@UEAA@XZ */
14088 DEFINE_THISCALL_WRAPPER(istrstream_dtor
, 4)
14089 void __thiscall
istrstream_dtor(basic_ios_char
*base
)
14091 istrstream
*this = istrstream_from_basic_ios(base
);
14093 TRACE("(%p)\n", this);
14095 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base
));
14096 strstreambuf_dtor(&this->buf
);
14099 static inline basic_ios_char
* strstream_to_basic_ios(strstream
*ptr
)
14101 return (basic_ios_char
*)((char*)ptr
+strstream_vbtable1
[1]);
14104 static inline strstream
* strstream_from_basic_ios(basic_ios_char
*ptr
)
14106 return (strstream
*)((char*)ptr
-strstream_vbtable1
[1]);
14109 /* ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z */
14110 /* ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z */
14111 basic_ostream_char
* __cdecl
basic_ostream_char_print_complex_float(basic_ostream_char
*ostr
, const complex_float
*val
)
14114 basic_ostringstream_char obj
;
14115 basic_ios_char vbase
;
14117 ios_base
*ostringstream_ios_base
, *ostream_ios_base
;
14119 basic_string_char str
;
14120 basic_ostringstream_char_ctor(&oss
.obj
);
14121 ostringstream_ios_base
= &oss
.vbase
.base
;
14122 ostream_ios_base
= &basic_ostream_char_get_basic_ios(ostr
)->base
;
14123 TRACE("(%p %p)\n", ostr
, val
);
14125 ios_base_imbue(ostringstream_ios_base
, &loc
, IOS_LOCALE(ostream_ios_base
));
14127 ios_base_precision_set(ostringstream_ios_base
, ios_base_precision_get(ostream_ios_base
));
14128 ios_base_flags_set(ostringstream_ios_base
, ios_base_flags_get(ostream_ios_base
));
14130 basic_ostream_char_print_ch(&oss
.obj
.base
, '(');
14131 basic_ostream_char_print_float(&oss
.obj
.base
, val
->real
);
14132 basic_ostream_char_print_ch(&oss
.obj
.base
, ',');
14133 basic_ostream_char_print_float(&oss
.obj
.base
, val
->imag
);
14134 basic_ostream_char_print_ch(&oss
.obj
.base
, ')');
14136 basic_ostringstream_char_str_get(&oss
.obj
, &str
);
14137 basic_ostringstream_char_dtor(&oss
.vbase
);
14138 basic_ostream_char_print_bstr(ostr
, &str
);
14139 MSVCP_basic_string_char_dtor(&str
);
14143 /* ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z */
14144 /* ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z */
14145 basic_ostream_char
* __cdecl
basic_ostream_char_print_complex_double(basic_ostream_char
*ostr
, const complex_double
*val
)
14148 basic_ostringstream_char obj
;
14149 basic_ios_char vbase
;
14151 ios_base
*ostringstream_ios_base
, *ostream_ios_base
;
14153 basic_string_char str
;
14154 basic_ostringstream_char_ctor(&oss
.obj
);
14155 ostringstream_ios_base
= &oss
.vbase
.base
;
14156 ostream_ios_base
= &basic_ostream_char_get_basic_ios(ostr
)->base
;
14157 TRACE("(%p %p)\n", ostr
, val
);
14159 ios_base_imbue(ostringstream_ios_base
, &loc
, IOS_LOCALE(ostream_ios_base
));
14161 ios_base_precision_set(ostringstream_ios_base
, ios_base_precision_get(ostream_ios_base
));
14162 ios_base_flags_set(ostringstream_ios_base
, ios_base_flags_get(ostream_ios_base
));
14164 basic_ostream_char_print_ch(&oss
.obj
.base
, '(');
14165 basic_ostream_char_print_double(&oss
.obj
.base
, val
->real
);
14166 basic_ostream_char_print_ch(&oss
.obj
.base
, ',');
14167 basic_ostream_char_print_double(&oss
.obj
.base
, val
->imag
);
14168 basic_ostream_char_print_ch(&oss
.obj
.base
, ')');
14170 basic_ostringstream_char_str_get(&oss
.obj
, &str
);
14171 basic_ostringstream_char_dtor(&oss
.vbase
);
14172 basic_ostream_char_print_bstr(ostr
, &str
);
14173 MSVCP_basic_string_char_dtor(&str
);
14177 /* ??$?6odu?$char_traits@d@std@@@std@@yaaav?$basic_ostream@du?$char_traits@d@std@@@0@aav10@abv?$complex@o@0@@Z */
14178 /* ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z */
14179 basic_ostream_char
* __cdecl
basic_ostream_char_print_complex_ldouble(basic_ostream_char
*ostr
, const complex_double
*val
)
14182 basic_ostringstream_char obj
;
14183 basic_ios_char vbase
;
14185 ios_base
*ostringstream_ios_base
, *ostream_ios_base
;
14187 basic_string_char str
;
14188 basic_ostringstream_char_ctor(&oss
.obj
);
14189 ostringstream_ios_base
= &oss
.vbase
.base
;
14190 ostream_ios_base
= &basic_ostream_char_get_basic_ios(ostr
)->base
;
14191 TRACE("(%p %p)\n", ostr
, val
);
14193 ios_base_imbue(ostringstream_ios_base
, &loc
, IOS_LOCALE(ostream_ios_base
));
14195 ios_base_precision_set(ostringstream_ios_base
, ios_base_precision_get(ostream_ios_base
));
14196 ios_base_flags_set(ostringstream_ios_base
, ios_base_flags_get(ostream_ios_base
));
14198 basic_ostream_char_print_ch(&oss
.obj
.base
, '(');
14199 basic_ostream_char_print_ldouble(&oss
.obj
.base
, val
->real
);
14200 basic_ostream_char_print_ch(&oss
.obj
.base
, ',');
14201 basic_ostream_char_print_ldouble(&oss
.obj
.base
, val
->imag
);
14202 basic_ostream_char_print_ch(&oss
.obj
.base
, ')');
14204 basic_ostringstream_char_str_get(&oss
.obj
, &str
);
14205 basic_ostringstream_char_dtor(&oss
.vbase
);
14206 basic_ostream_char_print_bstr(ostr
, &str
);
14207 MSVCP_basic_string_char_dtor(&str
);
14211 /* ?_File_size@sys@tr2@std@@YA_KPBD@Z */
14212 /* ?_File_size@sys@tr2@std@@YA_KPEBD@Z */
14213 ULONGLONG __cdecl
tr2_sys__File_size(char const* path
)
14215 WIN32_FILE_ATTRIBUTE_DATA fad
;
14217 TRACE("(%s)\n", debugstr_a(path
));
14218 if(!GetFileAttributesExA(path
, GetFileExInfoStandard
, &fad
))
14220 if(fad
.dwFileAttributes
& FILE_ATTRIBUTE_DIRECTORY
)
14223 return ((ULONGLONG
)(fad
.nFileSizeHigh
) << 32) + fad
.nFileSizeLow
;
14226 /* ?_Equivalent@sys@tr2@std@@YAHPBD0@Z */
14227 /* ?_Equivalent@sys@tr2@std@@YAHPEBD0@Z */
14228 int __cdecl
tr2_sys__Equivalent(char const* path1
, char const* path2
)
14232 BY_HANDLE_FILE_INFORMATION info1
, info2
;
14233 TRACE("(%s %s)\n", debugstr_a(path1
), debugstr_a(path2
));
14235 h1
= CreateFileA(path1
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14236 NULL
, OPEN_EXISTING
, 0, 0);
14237 h2
= CreateFileA(path2
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14238 NULL
, OPEN_EXISTING
, 0, 0);
14239 if(h1
== INVALID_HANDLE_VALUE
) {
14240 if(h2
== INVALID_HANDLE_VALUE
) {
14246 }else if(h2
== INVALID_HANDLE_VALUE
) {
14251 ret
= GetFileInformationByHandle(h1
, &info1
) && GetFileInformationByHandle(h2
, &info2
);
14256 return (info1
.dwVolumeSerialNumber
== info2
.dwVolumeSerialNumber
14257 && info1
.nFileIndexHigh
== info2
.nFileIndexHigh
14258 && info1
.nFileIndexLow
== info2
.nFileIndexLow
14262 /* ?_Current_get@sys@tr2@std@@YAPADAAY0BAE@D@Z */
14263 /* ?_Current_get@sys@tr2@std@@YAPEADAEAY0BAE@D@Z */
14264 char* __cdecl
tr2_sys__Current_get(char *current_path
)
14266 TRACE("(%s)\n", debugstr_a(current_path
));
14268 if(!GetCurrentDirectoryA(MAX_PATH
, current_path
))
14270 return current_path
;
14273 /* ?_Current_set@sys@tr2@std@@YA_NPBD@Z */
14274 /* ?_Current_set@sys@tr2@std@@YA_NPEBD@Z */
14275 MSVCP_bool __cdecl
tr2_sys__Current_set(char const* path
)
14277 TRACE("(%s)\n", debugstr_a(path
));
14278 return SetCurrentDirectoryA(path
) != 0;
14281 /* ?_Make_dir@sys@tr2@std@@YAHPBD@Z */
14282 /* ?_Make_dir@sys@tr2@std@@YAHPEBD@Z */
14283 int __cdecl
tr2_sys__Make_dir(char const* path
)
14285 TRACE("(%s)\n", debugstr_a(path
));
14287 if(!CreateDirectoryA(path
, NULL
)) {
14288 if(GetLastError() == ERROR_ALREADY_EXISTS
)
14297 /* ?_Remove_dir@sys@tr2@std@@YA_NPBD@Z */
14298 /* ?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z */
14299 MSVCP_bool __cdecl
tr2_sys__Remove_dir(char const* path
)
14301 TRACE("(%s)\n", debugstr_a(path
));
14302 return RemoveDirectoryA(path
) != 0;
14305 /* ?_Copy_file@sys@tr2@std@@YAHPBD0_N@Z */
14306 /* ?_Copy_file@sys@tr2@std@@YAHPEBD0_N@Z */
14307 int __cdecl
tr2_sys__Copy_file(char const* source
, char const* dest
, MSVCP_bool fail_if_exists
)
14309 TRACE("(%s %s %x)\n", debugstr_a(source
), debugstr_a(dest
), fail_if_exists
);
14311 if(CopyFileA(source
, dest
, fail_if_exists
))
14312 return ERROR_SUCCESS
;
14313 return GetLastError();
14316 /* ?_Rename@sys@tr2@std@@YAHPBD0@Z */
14317 /* ?_Rename@sys@tr2@std@@YAHPEBD0@Z */
14318 int __cdecl
tr2_sys__Rename(char const* old_path
, char const* new_path
)
14320 TRACE("(%s %s)\n", debugstr_a(old_path
), debugstr_a(new_path
));
14322 if(!old_path
|| !new_path
)
14323 return ERROR_INVALID_PARAMETER
;
14325 if(MoveFileExA(old_path
, new_path
, MOVEFILE_COPY_ALLOWED
))
14326 return ERROR_SUCCESS
;
14327 return GetLastError();
14330 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PBD@Z */
14331 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PEBD@Z */
14332 struct space_info
* __cdecl
tr2_sys__Statvfs(struct space_info
*ret
, const char* path
)
14334 ULARGE_INTEGER available
, total
, free
;
14336 TRACE("(%s)\n", debugstr_a(path
));
14338 if(!path
|| !GetDiskFreeSpaceExA(path
, &available
, &total
, &free
)) {
14339 ret
->capacity
= ret
->free
= ret
->available
= 0;
14341 ret
->capacity
= total
.QuadPart
;
14342 ret
->free
= free
.QuadPart
;
14343 ret
->available
= available
.QuadPart
;
14348 /* ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PBDAAH@Z */
14349 /* ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PEBDAEAH@Z */
14350 enum file_type __cdecl
tr2_sys__Stat(char const* path
, int* err_code
)
14353 TRACE("(%s %p)\n", debugstr_a(path
), err_code
);
14355 *err_code
= ERROR_INVALID_PARAMETER
;
14356 return status_unknown
;
14359 attr
=GetFileAttributesA(path
);
14360 if(attr
== INVALID_FILE_ATTRIBUTES
) {
14361 enum file_type ret
;
14362 switch(GetLastError()) {
14363 case ERROR_FILE_NOT_FOUND
:
14364 case ERROR_BAD_NETPATH
:
14365 case ERROR_INVALID_NAME
:
14366 case ERROR_BAD_PATHNAME
:
14367 case ERROR_PATH_NOT_FOUND
:
14368 ret
= file_not_found
;
14369 *err_code
= ERROR_SUCCESS
;
14372 ret
= status_unknown
;
14373 *err_code
= GetLastError();
14378 *err_code
= ERROR_SUCCESS
;
14379 return (attr
& FILE_ATTRIBUTE_DIRECTORY
)?directory_file
:regular_file
;
14382 /* ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PBDAAH@Z */
14383 /* ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PEBDAEAH@Z */
14384 enum file_type __cdecl
tr2_sys__Lstat(char const* path
, int* err_code
)
14386 return tr2_sys__Stat(path
, err_code
);
14389 /* ?_Last_write_time@sys@tr2@std@@YA_JPBD@Z */
14390 /* ?_Last_write_time@sys@tr2@std@@YA_JPEBD@Z */
14391 __int64 __cdecl
tr2_sys__Last_write_time(char const* path
)
14396 __int64 last_write_time
;
14397 TRACE("(%s)\n", debugstr_a(path
));
14399 handle
= CreateFileA(path
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14400 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
14401 if(handle
== INVALID_HANDLE_VALUE
)
14404 ret
= GetFileTime(handle
, 0, 0, &lwt
);
14405 CloseHandle(handle
);
14409 last_write_time
= (((__int64
)lwt
.dwHighDateTime
)<< 32) + lwt
.dwLowDateTime
;
14410 last_write_time
-= TICKS_1601_TO_1970
;
14411 last_write_time
/= TICKSPERSEC
;
14412 return last_write_time
;
14415 /* ?_Last_write_time@sys@tr2@std@@YAXPBD_J@Z */
14416 /* ?_Last_write_time@sys@tr2@std@@YAXPEBD_J@Z */
14417 void __cdecl
tr2_sys__Last_write_time_set(char const* path
, __int64 newtime
)
14421 TRACE("(%s)\n", debugstr_a(path
));
14423 handle
= CreateFileA(path
, FILE_WRITE_ATTRIBUTES
,
14424 FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14425 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
14426 if(handle
== INVALID_HANDLE_VALUE
)
14429 /* This is the implementation based on the test of msvcp110.
14430 * According to the test of msvcp120,
14431 * msvcp120's implementation does nothing. Obviously, this is a bug of windows.
14434 newtime
*= TICKSPERSEC
;
14435 newtime
+= TICKS_1601_TO_1970
;
14436 lwt
.dwLowDateTime
= (DWORD
)(newtime
);
14437 lwt
.dwHighDateTime
= (DWORD
)(newtime
>> 32);
14438 SetFileTime(handle
, 0, 0, &lwt
);
14439 CloseHandle(handle
);
14442 /* ?_Open_dir@sys@tr2@std@@YAPAXAAY0BAE@DPBDAAHAAW4file_type@123@@Z */
14443 /* ?_Open_dir@sys@tr2@std@@YAPEAXAEAY0BAE@DPEBDAEAHAEAW4file_type@123@@Z */
14444 void* __cdecl
tr2_sys__Open_dir(char* target
, char const* dest
, int* err_code
, enum file_type
* type
)
14447 WIN32_FIND_DATAA data
;
14448 char temppath
[MAX_PATH
];
14450 TRACE("(%p %s %p %p)\n", target
, debugstr_a(dest
), err_code
, type
);
14451 if(strlen(dest
) > MAX_PATH
- 3) {
14452 *err_code
= ERROR_BAD_PATHNAME
;
14455 strcpy(temppath
, dest
);
14456 strcat(temppath
, "\\*");
14458 handle
= FindFirstFileA(temppath
, &data
);
14459 if(handle
== INVALID_HANDLE_VALUE
) {
14460 *err_code
= GetLastError();
14463 while(!strcmp(data
.cFileName
, ".") || !strcmp(data
.cFileName
, "..")) {
14464 if(!FindNextFileA(handle
, &data
)) {
14465 *err_code
= ERROR_SUCCESS
;
14466 *type
= status_unknown
;
14472 strcpy(target
, data
.cFileName
);
14473 *err_code
= ERROR_SUCCESS
;
14474 if(data
.dwFileAttributes
& FILE_ATTRIBUTE_DIRECTORY
)
14475 *type
= directory_file
;
14477 *type
= regular_file
;
14481 /* ??0strstream@std@@QAE@PADHH@Z */
14482 /* ??0strstream@std@@QEAA@PEAD_JH@Z */
14483 #if STREAMSIZE_BITS == 64
14484 DEFINE_THISCALL_WRAPPER(strstream_ctor
, 24)
14486 DEFINE_THISCALL_WRAPPER(strstream_ctor
, 20)
14488 strstream
* __thiscall
strstream_ctor(strstream
*this, char *buf
, streamsize size
, int mode
, MSVCP_bool virt_init
)
14490 basic_ios_char
*basic_ios
;
14492 TRACE("(%p %p %s %d %d)\n", this, buf
, wine_dbgstr_longlong(size
), mode
, virt_init
);
14495 this->base
.base1
.vbtable
= strstream_vbtable1
;
14496 this->base
.base2
.vbtable
= strstream_vbtable2
;
14497 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
14498 basic_ios_char_ctor(basic_ios
);
14500 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
14503 strstreambuf_ctor_get_put(&this->buf
, buf
, size
,
14504 buf
&& (mode
& OPENMODE_app
) ? buf
+strlen(buf
) : buf
);
14505 basic_iostream_char_ctor(&this->base
, &this->buf
.base
, FALSE
);
14506 basic_ios
->base
.vtable
= &MSVCP_strstream_vtable
;
14510 /* ??1strstream@std@@UAE@XZ */
14511 /* ??1strstream@std@@UEAA@XZ */
14512 DEFINE_THISCALL_WRAPPER(strstream_dtor
, 4)
14513 void __thiscall
strstream_dtor(basic_ios_char
*base
)
14515 strstream
*this = strstream_from_basic_ios(base
);
14517 TRACE("(%p)\n", this);
14519 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base
));
14520 strstreambuf_dtor(&this->buf
);
14523 static void strstream_vbase_dtor(strstream
*this)
14525 TRACE("(%p)\n", this);
14527 strstream_dtor(strstream_to_basic_ios(this));
14528 basic_ios_char_dtor(basic_istream_char_get_basic_ios(&this->base
.base1
));
14531 DEFINE_THISCALL_WRAPPER(strstream_vector_dtor
, 8)
14532 strstream
* __thiscall
strstream_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
14534 strstream
*this = strstream_from_basic_ios(base
);
14536 TRACE("(%p %x)\n", this, flags
);
14539 /* we have an array, with the number of elements stored before the first object */
14540 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
14542 for(i
=*ptr
-1; i
>=0; i
--)
14543 strstream_vbase_dtor(this+i
);
14544 MSVCRT_operator_delete(ptr
);
14546 strstream_vbase_dtor(this);
14548 MSVCRT_operator_delete(this);
14554 static void __cdecl
setprecision_func(ios_base
*base
, streamsize prec
)
14556 ios_base_precision_set(base
, prec
);
14559 /* ?setprecision@std@@YA?AU?$_Smanip@H@1@H@Z */
14560 /* ?setprecision@std@@YA?AU?$_Smanip@_J@1@_J@Z */
14561 manip_streamsize
* __cdecl
setprecision(manip_streamsize
*ret
, streamsize prec
)
14563 TRACE("(%p %s)\n", ret
, wine_dbgstr_longlong(prec
));
14565 ret
->pfunc
= setprecision_func
;
14570 static void __cdecl
setw_func(ios_base
*base
, streamsize width
)
14572 ios_base_width_set(base
, width
);
14575 /* ?setw@std@@YA?AU?$_Smanip@H@1@H@Z */
14576 /* ?setw@std@@YA?AU?$_Smanip@_J@1@_J@Z */
14577 manip_streamsize
* __cdecl
setw(manip_streamsize
*ret
, streamsize width
)
14579 TRACE("(%p %s)\n", ret
, wine_dbgstr_longlong(width
));
14581 ret
->pfunc
= setw_func
;
14586 static void __cdecl
resetioflags_func(ios_base
*base
, int mask
)
14588 ios_base_setf_mask(base
, 0, mask
);
14591 /* ?resetiosflags@std@@YA?AU?$_Smanip@H@1@H@Z */
14592 manip_int
* __cdecl
resetiosflags(manip_int
*ret
, int mask
)
14594 TRACE("(%p %d)\n", ret
, mask
);
14596 ret
->pfunc
= resetioflags_func
;
14601 static void __cdecl
setiosflags_func(ios_base
*base
, int mask
)
14603 ios_base_setf_mask(base
, FMTFLAG_mask
, mask
);
14606 /* ?setiosflags@std@@YA?AU?$_Smanip@H@1@H@Z */
14607 manip_int
* __cdecl
setiosflags(manip_int
*ret
, int mask
)
14609 TRACE("(%p %d)\n", ret
, mask
);
14611 ret
->pfunc
= setiosflags_func
;
14616 static void __cdecl
setbase_func(ios_base
*base
, int set_base
)
14619 set_base
= FMTFLAG_dec
;
14620 else if(set_base
== 8)
14621 set_base
= FMTFLAG_oct
;
14622 else if(set_base
== 16)
14623 set_base
= FMTFLAG_hex
;
14627 ios_base_setf_mask(base
, set_base
, FMTFLAG_basefield
);
14630 /* ?setbase@std@@YA?AU?$_Smanip@H@1@H@Z */
14631 manip_int
* __cdecl
setbase(manip_int
*ret
, int base
)
14633 TRACE("(%p %d)\n", ret
, base
);
14635 ret
->pfunc
= setbase_func
;
14640 static basic_filebuf_char filebuf_char_stdin
;
14641 /* ?cin@std@@3V?$basic_istream@DU?$char_traits@D@std@@@1@A */
14643 basic_istream_char obj
;
14644 basic_ios_char vbase
;
14646 /* ?_Ptr_cin@std@@3PAV?$basic_istream@DU?$char_traits@D@std@@@1@A */
14647 /* ?_Ptr_cin@std@@3PEAV?$basic_istream@DU?$char_traits@D@std@@@1@EA */
14648 basic_istream_char
*_Ptr_cin
= &cin
.obj
;
14650 static basic_filebuf_wchar filebuf_short_stdin
;
14651 /* ?wcin@std@@3V?$basic_istream@GU?$char_traits@G@std@@@1@A */
14653 basic_istream_wchar obj
;
14654 basic_ios_wchar vbase
;
14655 } ucin
= { { 0 } };
14656 /* ?_Ptr_wcin@std@@3PAV?$basic_istream@GU?$char_traits@G@std@@@1@A */
14657 /* ?_Ptr_wcin@std@@3PEAV?$basic_istream@GU?$char_traits@G@std@@@1@EA */
14658 basic_istream_wchar
*_Ptr_ucin
= &ucin
.obj
;
14660 static basic_filebuf_wchar filebuf_wchar_stdin
;
14661 /* ?wcin@std@@3V?$basic_istream@_WU?$char_traits@_W@std@@@1@A */
14663 basic_istream_wchar obj
;
14664 basic_ios_wchar vbase
;
14665 } wcin
= { { 0 } };
14666 /* ?_Ptr_wcin@std@@3PAV?$basic_istream@_WU?$char_traits@_W@std@@@1@A */
14667 /* ?_Ptr_wcin@std@@3PEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@EA */
14668 basic_istream_wchar
*_Ptr_wcin
= &wcin
.obj
;
14670 static basic_filebuf_char filebuf_char_stdout
;
14671 /* ?cout@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
14673 basic_ostream_char obj
;
14674 basic_ios_char vbase
;
14675 } cout
= { { 0 } };
14676 /* ?_Ptr_cout@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
14677 /* ?_Ptr_cout@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
14678 basic_ostream_char
*_Ptr_cout
= &cout
.obj
;
14680 static basic_filebuf_wchar filebuf_short_stdout
;
14681 /* ?wcout@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
14683 basic_ostream_wchar obj
;
14684 basic_ios_wchar vbase
;
14685 } ucout
= { { 0 } };
14686 /* ?_Ptr_wcout@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
14687 /* ?_Ptr_wcout@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
14688 basic_ostream_wchar
*_Ptr_ucout
= &ucout
.obj
;
14690 static basic_filebuf_wchar filebuf_wchar_stdout
;
14691 /* ?wcout@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
14693 basic_ostream_wchar obj
;
14694 basic_ios_wchar vbase
;
14695 } wcout
= { { 0 } };
14696 /* ?_Ptr_wcout@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
14697 /* ?_Ptr_wcout@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
14698 basic_ostream_wchar
*_Ptr_wcout
= &wcout
.obj
;
14700 static basic_filebuf_char filebuf_char_stderr
;
14701 /* ?cerr@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
14703 basic_ostream_char obj
;
14704 basic_ios_char vbase
;
14705 } cerr
= { { 0 } };
14706 /* ?_Ptr_cerr@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
14707 /* ?_Ptr_cerr@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
14708 basic_ostream_char
*_Ptr_cerr
= &cerr
.obj
;
14710 static basic_filebuf_wchar filebuf_short_stderr
;
14711 /* ?wcerr@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
14713 basic_ostream_wchar obj
;
14714 basic_ios_wchar vbase
;
14715 } ucerr
= { { 0 } };
14716 /* ?_Ptr_wcerr@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
14717 /* ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
14718 basic_ostream_wchar
*_Ptr_ucerr
= &ucerr
.obj
;
14720 static basic_filebuf_wchar filebuf_wchar_stderr
;
14721 /* ?wcerr@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
14723 basic_ostream_wchar obj
;
14724 basic_ios_wchar vbase
;
14725 } wcerr
= { { 0 } };
14726 /* ?_Ptr_wcerr@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
14727 /* ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
14728 basic_ostream_wchar
*_Ptr_wcerr
= &wcerr
.obj
;
14730 static basic_filebuf_char filebuf_char_log
;
14731 /* ?clog@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
14733 basic_ostream_char obj
;
14734 basic_ios_char vbase
;
14735 } clog
= { { 0 } };
14736 /* ?_Ptr_clog@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
14737 /* ?_Ptr_clog@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
14738 basic_ostream_char
*_Ptr_clog
= &clog
.obj
;
14740 static basic_filebuf_wchar filebuf_short_log
;
14741 /* ?wclog@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
14743 basic_ostream_wchar obj
;
14744 basic_ios_wchar vbase
;
14745 } uclog
= { { 0 } };
14746 /* ?_Ptr_wclog@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
14747 /* ?_Ptr_wclog@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
14748 basic_ostream_wchar
*_Ptr_uclog
= &uclog
.obj
;
14750 static basic_filebuf_wchar filebuf_wchar_log
;
14751 /* ?wclog@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
14753 basic_ostream_wchar obj
;
14754 basic_ios_wchar vbase
;
14755 } wclog
= { { 0 } };
14756 /* ?_Ptr_wclog@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
14757 /* ?_Ptr_wclog@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
14758 basic_ostream_wchar
*_Ptr_wclog
= &wclog
.obj
;
14760 /* ?_Init_cnt@Init@ios_base@std@@0HA */
14761 int ios_base_Init__Init_cnt
= -1;
14763 /* ?_Init_cnt_func@Init@ios_base@std@@CAAAHXZ */
14764 /* ?_Init_cnt_func@Init@ios_base@std@@CAAEAHXZ */
14765 int* __cdecl
ios_base_Init__Init_cnt_func(void)
14767 return &ios_base_Init__Init_cnt
;
14770 /* ?_Init_ctor@Init@ios_base@std@@CAXPAV123@@Z */
14771 /* ?_Init_ctor@Init@ios_base@std@@CAXPEAV123@@Z */
14772 void __cdecl
ios_base_Init__Init_ctor(void *this)
14774 TRACE("(%p)\n", this);
14776 if(ios_base_Init__Init_cnt
< 0)
14777 ios_base_Init__Init_cnt
= 1;
14779 ios_base_Init__Init_cnt
++;
14782 /* ??0Init@ios_base@std@@QAE@XZ */
14783 /* ??0Init@ios_base@std@@QEAA@XZ */
14784 DEFINE_THISCALL_WRAPPER(ios_base_Init_ctor
, 4)
14785 void* __thiscall
ios_base_Init_ctor(void *this)
14787 ios_base_Init__Init_ctor(this);
14791 /* ?_Init_dtor@Init@ios_base@std@@CAXPAV123@@Z */
14792 /* ?_Init_dtor@Init@ios_base@std@@CAXPEAV123@@Z */
14793 void __cdecl
ios_base_Init__Init_dtor(void *this)
14795 TRACE("(%p)\n", this);
14797 ios_base_Init__Init_cnt
--;
14798 if(!ios_base_Init__Init_cnt
) {
14799 basic_ostream_char_flush(&cout
.obj
);
14800 basic_ostream_char_flush(&cerr
.obj
);
14801 basic_ostream_char_flush(&clog
.obj
);
14805 /* ??1Init@ios_base@std@@QAE@XZ */
14806 /* ??1Init@ios_base@std@@QEAA@XZ */
14807 DEFINE_THISCALL_WRAPPER(ios_base_Init_dtor
, 4)
14808 void __thiscall
ios_base_Init_dtor(void *this)
14810 ios_base_Init__Init_dtor(this);
14813 /* ??4Init@ios_base@std@@QAEAAV012@ABV012@@Z */
14814 /* ??4Init@ios_base@std@@QEAAAEAV012@AEBV012@@Z */
14815 DEFINE_THISCALL_WRAPPER(ios_base_Init_op_assign
, 8)
14816 void* __thiscall
ios_base_Init_op_assign(void *this, void *rhs
)
14818 TRACE("(%p %p)\n", this, rhs
);
14822 /* ?_Init_cnt@_Winit@std@@0HA */
14823 int _Winit__Init_cnt
= -1;
14825 /* ??0_Winit@std@@QAE@XZ */
14826 /* ??0_Winit@std@@QEAA@XZ */
14827 DEFINE_THISCALL_WRAPPER(_Winit_ctor
, 4)
14828 void* __thiscall
_Winit_ctor(void *this)
14830 TRACE("(%p)\n", this);
14832 if(_Winit__Init_cnt
< 0)
14833 _Winit__Init_cnt
= 1;
14835 _Winit__Init_cnt
++;
14840 /* ?_File_size@sys@tr2@std@@YA_KPB_W@Z */
14841 /* ?_File_size@sys@tr2@std@@YA_KPEB_W@Z */
14842 ULONGLONG __cdecl
tr2_sys__File_size_wchar(WCHAR
const* path
)
14844 WIN32_FILE_ATTRIBUTE_DATA fad
;
14846 TRACE("(%s)\n", debugstr_w(path
));
14847 if(!GetFileAttributesExW(path
, GetFileExInfoStandard
, &fad
))
14849 if(fad
.dwFileAttributes
& FILE_ATTRIBUTE_DIRECTORY
)
14852 return ((ULONGLONG
)(fad
.nFileSizeHigh
) << 32) + fad
.nFileSizeLow
;
14855 /* ?_Equivalent@sys@tr2@std@@YAHPB_W0@Z */
14856 /* ?_Equivalent@sys@tr2@std@@YAHPEB_W0@Z */
14857 int __cdecl
tr2_sys__Equivalent_wchar(WCHAR
const* path1
, WCHAR
const* path2
)
14861 BY_HANDLE_FILE_INFORMATION info1
, info2
;
14862 TRACE("(%s %s)\n", debugstr_w(path1
), debugstr_w(path2
));
14864 h1
= CreateFileW(path1
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14865 NULL
, OPEN_EXISTING
, 0, 0);
14866 h2
= CreateFileW(path2
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14867 NULL
, OPEN_EXISTING
, 0, 0);
14868 if(h1
== INVALID_HANDLE_VALUE
) {
14869 if(h2
== INVALID_HANDLE_VALUE
) {
14875 }else if(h2
== INVALID_HANDLE_VALUE
) {
14880 ret
= GetFileInformationByHandle(h1
, &info1
) && GetFileInformationByHandle(h2
, &info2
);
14885 return (info1
.dwVolumeSerialNumber
== info2
.dwVolumeSerialNumber
14886 && info1
.nFileIndexHigh
== info2
.nFileIndexHigh
14887 && info1
.nFileIndexLow
== info2
.nFileIndexLow
14891 /* ?_Current_get@sys@tr2@std@@YAPA_WAAY0BAE@_W@Z */
14892 /* ?_Current_get@sys@tr2@std@@YAPEA_WAEAY0BAE@_W@Z */
14893 WCHAR
* __cdecl
tr2_sys__Current_get_wchar(WCHAR
*current_path
)
14895 TRACE("(%s)\n", debugstr_w(current_path
));
14897 if(!GetCurrentDirectoryW(MAX_PATH
, current_path
))
14899 return current_path
;
14902 /* ?_Current_set@sys@tr2@std@@YA_NPB_W@Z */
14903 /* ?_Current_set@sys@tr2@std@@YA_NPEB_W@Z */
14904 MSVCP_bool __cdecl
tr2_sys__Current_set_wchar(WCHAR
const* path
)
14906 TRACE("(%s)\n", debugstr_w(path
));
14907 return SetCurrentDirectoryW(path
) != 0;
14910 /* ?_Make_dir@sys@tr2@std@@YAHPB_W@Z */
14911 /* ?_Make_dir@sys@tr2@std@@YAHPEB_W@Z */
14912 int __cdecl
tr2_sys__Make_dir_wchar(WCHAR
const* path
)
14914 TRACE("(%s)\n", debugstr_w(path
));
14916 if(!CreateDirectoryW(path
, NULL
)) {
14917 if(GetLastError() == ERROR_ALREADY_EXISTS
)
14926 /* ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z */
14927 /* ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z */
14928 MSVCP_bool __cdecl
tr2_sys__Remove_dir_wchar(WCHAR
const* path
)
14930 TRACE("(%s)\n", debugstr_w(path
));
14931 return RemoveDirectoryW(path
) != 0;
14934 /* ?_Copy_file@sys@tr2@std@@YAHPB_W0_N@Z */
14935 /* ?_Copy_file@sys@tr2@std@@YAHPEB_W0_N@Z */
14936 int __cdecl
tr2_sys__Copy_file_wchar(WCHAR
const* source
, WCHAR
const* dest
, MSVCP_bool fail_if_exists
)
14938 TRACE("(%s %s %x)\n", debugstr_w(source
), debugstr_w(dest
), fail_if_exists
);
14940 if(CopyFileW(source
, dest
, fail_if_exists
))
14941 return ERROR_SUCCESS
;
14942 return GetLastError();
14945 /* ?_Rename@sys@tr2@std@@YAHPB_W0@Z */
14946 /* ?_Rename@sys@tr2@std@@YAHPEB_W0@Z */
14947 int __cdecl
tr2_sys__Rename_wchar(WCHAR
const* old_path
, WCHAR
const* new_path
)
14949 TRACE("(%s %s)\n", debugstr_w(old_path
), debugstr_w(new_path
));
14951 if(!old_path
|| !new_path
)
14952 return ERROR_INVALID_PARAMETER
;
14954 if(MoveFileExW(old_path
, new_path
, MOVEFILE_COPY_ALLOWED
))
14955 return ERROR_SUCCESS
;
14956 return GetLastError();
14959 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PB_W@Z */
14960 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PEB_W@Z */
14961 struct space_info
* __cdecl
tr2_sys__Statvfs_wchar(struct space_info
*ret
, const WCHAR
* path
)
14963 ULARGE_INTEGER available
, total
, free
;
14965 TRACE("(%s)\n", debugstr_w(path
));
14967 if(!path
|| !GetDiskFreeSpaceExW(path
, &available
, &total
, &free
)) {
14968 ret
->capacity
= ret
->free
= ret
->available
= 0;
14970 ret
->capacity
= total
.QuadPart
;
14971 ret
->free
= free
.QuadPart
;
14972 ret
->available
= available
.QuadPart
;
14977 /* ??1_Winit@std@@QAE@XZ */
14978 /* ??1_Winit@std@@QAE@XZ */
14979 DEFINE_THISCALL_WRAPPER(_Winit_dtor
, 4)
14980 void __thiscall
_Winit_dtor(void *this)
14982 TRACE("(%p)\n", this);
14984 _Winit__Init_cnt
--;
14985 if(!_Winit__Init_cnt
) {
14986 basic_ostream_wchar_flush(&wcout
.obj
);
14987 basic_ostream_wchar_flush(&wcerr
.obj
);
14988 basic_ostream_wchar_flush(&wclog
.obj
);
14992 /* ??4_Winit@std@@QAEAAV01@ABV01@@Z */
14993 /* ??4_Winit@std@@QEAAAEAV01@AEBV01@@Z */
14994 DEFINE_THISCALL_WRAPPER(_Winit_op_assign
, 8)
14995 void* __thiscall
_Winit_op_assign(void *this, void *rhs
)
14997 TRACE("(%p %p)\n", this, rhs
);
15001 void init_io(void *base
)
15004 init_iosb_rtti(base
);
15005 init_ios_base_rtti(base
);
15006 init_basic_ios_char_rtti(base
);
15007 init_basic_ios_wchar_rtti(base
);
15008 init_basic_ios_short_rtti(base
);
15009 init_basic_streambuf_char_rtti(base
);
15010 init_basic_streambuf_wchar_rtti(base
);
15011 init_basic_streambuf_short_rtti(base
);
15012 init_basic_filebuf_char_rtti(base
);
15013 init_basic_filebuf_wchar_rtti(base
);
15014 init_basic_filebuf_short_rtti(base
);
15015 init_basic_stringbuf_char_rtti(base
);
15016 init_basic_stringbuf_wchar_rtti(base
);
15017 init_basic_stringbuf_short_rtti(base
);
15018 init_basic_ostream_char_rtti(base
);
15019 init_basic_ostream_wchar_rtti(base
);
15020 init_basic_ostream_short_rtti(base
);
15021 init_basic_istream_char_rtti(base
);
15022 init_basic_istream_wchar_rtti(base
);
15023 init_basic_istream_short_rtti(base
);
15024 init_basic_iostream_char_rtti(base
);
15025 init_basic_iostream_wchar_rtti(base
);
15026 init_basic_iostream_short_rtti(base
);
15027 init_basic_ofstream_char_rtti(base
);
15028 init_basic_ofstream_wchar_rtti(base
);
15029 init_basic_ofstream_short_rtti(base
);
15030 init_basic_ifstream_char_rtti(base
);
15031 init_basic_ifstream_wchar_rtti(base
);
15032 init_basic_ifstream_short_rtti(base
);
15033 init_basic_fstream_char_rtti(base
);
15034 init_basic_fstream_wchar_rtti(base
);
15035 init_basic_fstream_short_rtti(base
);
15036 init_basic_ostringstream_char_rtti(base
);
15037 init_basic_ostringstream_wchar_rtti(base
);
15038 init_basic_ostringstream_short_rtti(base
);
15039 init_basic_istringstream_char_rtti(base
);
15040 init_basic_istringstream_wchar_rtti(base
);
15041 init_basic_istringstream_short_rtti(base
);
15042 init_basic_stringstream_char_rtti(base
);
15043 init_basic_stringstream_wchar_rtti(base
);
15044 init_basic_stringstream_short_rtti(base
);
15045 init_strstreambuf_rtti(base
);
15046 init_strstream_rtti(base
);
15047 init_ostrstream_rtti(base
);
15050 basic_filebuf_char_ctor_file(&filebuf_char_stdin
, stdin
);
15051 basic_istream_char_ctor(&cin
.obj
, &filebuf_char_stdin
.base
, FALSE
/*FIXME*/, TRUE
);
15053 basic_filebuf_short_ctor_file(&filebuf_short_stdin
, stdin
);
15054 basic_istream_short_ctor(&ucin
.obj
, &filebuf_short_stdin
.base
, FALSE
/*FIXME*/, TRUE
);
15056 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stdin
, stdin
);
15057 basic_istream_wchar_ctor(&wcin
.obj
, &filebuf_wchar_stdin
.base
, FALSE
/*FIXME*/, TRUE
);
15059 basic_filebuf_char_ctor_file(&filebuf_char_stdout
, stdout
);
15060 basic_ostream_char_ctor(&cout
.obj
, &filebuf_char_stdout
.base
, FALSE
/*FIXME*/, TRUE
);
15062 basic_filebuf_short_ctor_file(&filebuf_short_stdout
, stdout
);
15063 basic_ostream_short_ctor(&ucout
.obj
, &filebuf_short_stdout
.base
, FALSE
/*FIXME*/, TRUE
);
15065 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stdout
, stdout
);
15066 basic_ostream_wchar_ctor(&wcout
.obj
, &filebuf_wchar_stdout
.base
, FALSE
/*FIXME*/, TRUE
);
15068 basic_filebuf_char_ctor_file(&filebuf_char_stderr
, stderr
);
15069 basic_ostream_char_ctor(&cerr
.obj
, &filebuf_char_stderr
.base
, FALSE
/*FIXME*/, TRUE
);
15071 basic_filebuf_short_ctor_file(&filebuf_short_stderr
, stderr
);
15072 basic_ostream_short_ctor(&ucerr
.obj
, &filebuf_short_stderr
.base
, FALSE
/*FIXME*/, TRUE
);
15074 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stderr
, stderr
);
15075 basic_ostream_wchar_ctor(&wcerr
.obj
, &filebuf_wchar_stderr
.base
, FALSE
/*FIXME*/, TRUE
);
15077 basic_filebuf_char_ctor_file(&filebuf_char_log
, stderr
);
15078 basic_ostream_char_ctor(&clog
.obj
, &filebuf_char_log
.base
, FALSE
/*FIXME*/, TRUE
);
15080 basic_filebuf_short_ctor_file(&filebuf_short_log
, stderr
);
15081 basic_ostream_short_ctor(&uclog
.obj
, &filebuf_short_log
.base
, FALSE
/*FIXME*/, TRUE
);
15083 basic_filebuf_wchar_ctor_file(&filebuf_wchar_log
, stderr
);
15084 basic_ostream_wchar_ctor(&wclog
.obj
, &filebuf_wchar_log
.base
, FALSE
/*FIXME*/, TRUE
);
15089 basic_istream_char_vbase_dtor(&cin
.obj
);
15090 basic_filebuf_char_dtor(&filebuf_char_stdin
);
15092 basic_istream_wchar_vbase_dtor(&ucin
.obj
);
15093 basic_filebuf_wchar_dtor(&filebuf_short_stdin
);
15095 basic_istream_wchar_vbase_dtor(&wcin
.obj
);
15096 basic_filebuf_wchar_dtor(&filebuf_wchar_stdin
);
15098 basic_ostream_char_vbase_dtor(&cout
.obj
);
15099 basic_filebuf_char_dtor(&filebuf_char_stdout
);
15101 basic_ostream_wchar_vbase_dtor(&ucout
.obj
);
15102 basic_filebuf_wchar_dtor(&filebuf_short_stdout
);
15104 basic_ostream_wchar_vbase_dtor(&wcout
.obj
);
15105 basic_filebuf_wchar_dtor(&filebuf_wchar_stdout
);
15107 basic_ostream_char_vbase_dtor(&cerr
.obj
);
15108 basic_filebuf_char_dtor(&filebuf_char_stderr
);
15110 basic_ostream_wchar_vbase_dtor(&ucerr
.obj
);
15111 basic_filebuf_wchar_dtor(&filebuf_short_stderr
);
15113 basic_ostream_wchar_vbase_dtor(&wcerr
.obj
);
15114 basic_filebuf_wchar_dtor(&filebuf_wchar_stderr
);
15116 basic_ostream_char_vbase_dtor(&clog
.obj
);
15117 basic_filebuf_char_dtor(&filebuf_char_log
);
15119 basic_ostream_wchar_vbase_dtor(&uclog
.obj
);
15120 basic_filebuf_wchar_dtor(&filebuf_short_log
);
15122 basic_ostream_wchar_vbase_dtor(&wclog
.obj
);
15123 basic_filebuf_wchar_dtor(&filebuf_wchar_log
);