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
28 #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 bool ios_base_Sync
= FALSE
;
45 __int64
DECLSPEC_ALIGN(8) pos
;
49 static inline const char* debugstr_fpos_mbstatet(fpos_mbstatet
*fpos
)
51 return wine_dbg_sprintf("fpos(%s %s %d)", wine_dbgstr_longlong(fpos
->off
),
52 wine_dbgstr_longlong(fpos
->pos
), MBSTATET_TO_INT(&fpos
->state
));
56 void (__cdecl
*pfunc
)(ios_base
*, streamsize
);
61 void (__cdecl
*pfunc
)(ios_base
*, int);
69 } basic_filebuf__Initfl
;
72 basic_streambuf_char base
;
77 basic_string_char
*conv
;
91 basic_streambuf_wchar base
;
96 basic_string_char
*conv
;
107 } basic_filebuf_wchar
;
110 STRINGBUF_allocated
= 1,
111 STRINGBUF_no_write
= 2,
112 STRINGBUF_no_read
= 4,
113 STRINGBUF_append
= 8,
114 STRINGBUF_at_end
= 16
115 } basic_stringbuf_state
;
118 basic_streambuf_char base
;
121 char allocator
; /* empty struct */
122 } basic_stringbuf_char
;
125 basic_streambuf_wchar base
;
128 char allocator
; /* empty struct */
129 } basic_stringbuf_wchar
;
133 basic_streambuf_char
*strbuf
;
134 struct _basic_ostream_char
*stream
;
140 basic_streambuf_wchar
*strbuf
;
141 struct _basic_ostream_wchar
*stream
;
145 typedef struct _basic_ostream_char
{
147 /* virtual inheritance
148 * basic_ios_char basic_ios;
150 } basic_ostream_char
;
152 typedef struct _basic_ostream_wchar
{
154 /* virtual inheritance
155 * basic_ios_wchar basic_ios;
157 } basic_ostream_wchar
;
162 /* virtual inheritance
163 * basic_ios_char basic_ios;
165 } basic_istream_char
;
170 /* virtual inheritance
171 * basic_ios_wchar basic_ios;
173 } basic_istream_wchar
;
176 basic_istream_char base1
;
177 basic_ostream_char base2
;
178 /* virtual inheritance
179 * basic_ios_char basic_ios;
181 } basic_iostream_char
;
184 basic_istream_wchar base1
;
185 basic_ostream_wchar base2
;
186 /* virtual inheritance
187 * basic_ios_wchar basic_ios;
189 } basic_iostream_wchar
;
192 basic_ostream_char base
;
193 basic_filebuf_char filebuf
;
194 /* virtual inheritance
195 * basic_ios_char basic_ios;
197 } basic_ofstream_char
;
200 basic_ostream_wchar base
;
201 basic_filebuf_wchar filebuf
;
202 /* virtual inheritance
203 * basic_ios_wchar basic_ios;
205 } basic_ofstream_wchar
;
208 basic_istream_char base
;
209 basic_filebuf_char filebuf
;
210 /* virtual inheritance
211 * basic_ios_char basic_ios;
213 } basic_ifstream_char
;
216 basic_istream_wchar base
;
217 basic_filebuf_wchar filebuf
;
218 /* virtual inheritance
219 * basic_ios_wchar basic_ios;
221 } basic_ifstream_wchar
;
224 basic_iostream_char base
;
225 basic_filebuf_char filebuf
;
226 /* virtual inheritance
227 * basic_ios_char basic_ios;
229 } basic_fstream_char
;
232 basic_iostream_wchar base
;
233 basic_filebuf_wchar filebuf
;
234 /* virtual inheritance
235 * basic_ios_char basic_ios;
237 } basic_fstream_wchar
;
240 basic_ostream_char base
;
241 basic_stringbuf_char strbuf
;
242 /* virtual inheritance
243 * basic_ios_char basic_ios;
245 } basic_ostringstream_char
;
248 basic_ostream_wchar base
;
249 basic_stringbuf_wchar strbuf
;
250 /* virtual inheritance
251 * basic_ios_wchar basic_ios;
253 } basic_ostringstream_wchar
;
256 basic_istream_char base
;
257 basic_stringbuf_char strbuf
;
258 /* virtual inheritance
259 * basic_ios_char basic_ios;
261 } basic_istringstream_char
;
264 basic_istream_wchar base
;
265 basic_stringbuf_wchar strbuf
;
266 /* virtual inheritance
267 * basic_ios_wchar basic_ios;
269 } basic_istringstream_wchar
;
272 basic_iostream_char base
;
273 basic_stringbuf_char strbuf
;
274 /* virtual inheritance
275 * basic_ios_char basic_ios;
277 } basic_stringstream_char
;
280 basic_iostream_wchar base
;
281 basic_stringbuf_wchar strbuf
;
282 /* virtual inheritance
283 * basic_ios_wchar basic_ios;
285 } basic_stringstream_wchar
;
288 STRSTATE_Allocated
= 1,
289 STRSTATE_Constant
= 2,
290 STRSTATE_Dynamic
= 4,
292 } strstreambuf__Strstate
;
295 basic_streambuf_char base
;
300 void* (__cdecl
*palloc
)(size_t);
301 void (__cdecl
*pfree
)(void*);
305 basic_ostream_char base
;
307 /* virtual inheritance
308 * basic_ios_char basic_ios;
313 basic_istream_char base
;
315 /* virtual inheritance
316 * basic_ios_char basic_ios;
321 basic_iostream_char base
;
323 /* virtual inheritance
324 * basic_ios_char basic_ios;
356 #if _MSVCP_VER >= 110
357 #define BASIC_IOS_VTORDISP 1
358 #define INIT_BASIC_IOS_VTORDISP(basic_ios) ((int*)basic_ios)[-1] = 0
360 #define BASIC_IOS_VTORDISP 0
361 #define INIT_BASIC_IOS_VTORDISP(basic_ios)
364 #define VBTABLE_ENTRY(class, offset, vbase, vtordisp) ALIGNED_SIZE(sizeof(class)+vtordisp*sizeof(int), TYPE_ALIGNMENT(vbase))-offset
365 #define VBTABLE_BASIC_IOS_ENTRY(class, offset) VBTABLE_ENTRY(class, offset, basic_ios_char, BASIC_IOS_VTORDISP)
367 extern const vtable_ptr MSVCP_iosb_vtable
;
369 /* ??_7ios_base@std@@6B@ */
370 extern const vtable_ptr MSVCP_ios_base_vtable
;
372 /* ??_7?$basic_ios@DU?$char_traits@D@std@@@std@@6B@ */
373 extern const vtable_ptr MSVCP_basic_ios_char_vtable
;
375 /* ??_7?$basic_ios@_WU?$char_traits@_W@std@@@std@@6B@ */
376 extern const vtable_ptr MSVCP_basic_ios_wchar_vtable
;
378 /* ??_7?$basic_ios@GU?$char_traits@G@std@@@std@@6B@ */
379 extern const vtable_ptr MSVCP_basic_ios_short_vtable
;
381 /* ??_7?$basic_streambuf@DU?$char_traits@D@std@@@std@@6B@ */
382 extern const vtable_ptr MSVCP_basic_streambuf_char_vtable
;
384 /* ??_7?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@6B@ */
385 extern const vtable_ptr MSVCP_basic_streambuf_wchar_vtable
;
387 /* ??_7?$basic_streambuf@GU?$char_traits@G@std@@@std@@6B@ */
388 extern const vtable_ptr MSVCP_basic_streambuf_short_vtable
;
390 /* ??_7?$basic_filebuf@DU?$char_traits@D@std@@@std@@6B@ */
391 extern const vtable_ptr MSVCP_basic_filebuf_char_vtable
;
393 /* ??_7?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@6B@ */
394 extern const vtable_ptr MSVCP_basic_filebuf_wchar_vtable
;
396 /* ??_7?$basic_filebuf@GU?$char_traits@G@std@@@std@@6B@ */
397 extern const vtable_ptr MSVCP_basic_filebuf_short_vtable
;
399 /* ??_7?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
400 extern const vtable_ptr MSVCP_basic_stringbuf_char_vtable
;
402 /* ??_7?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
403 extern const vtable_ptr MSVCP_basic_stringbuf_wchar_vtable
;
405 /* ??_7?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
406 extern const vtable_ptr MSVCP_basic_stringbuf_short_vtable
;
408 /* ??_8?$basic_ostream@DU?$char_traits@D@std@@@std@@7B@ */
409 const int basic_ostream_char_vbtable
[] = {0,
410 VBTABLE_BASIC_IOS_ENTRY(basic_ostream_char
, 0)};
411 /* ??_7?$basic_ostream@DU?$char_traits@D@std@@@std@@6B@ */
412 extern const vtable_ptr MSVCP_basic_ostream_char_vtable
;
414 /* ??_8?$basic_ostream@_WU?$char_traits@_W@std@@@std@@7B@ */
415 const int basic_ostream_wchar_vbtable
[] = {0,
416 VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)};
417 /* ??_7?$basic_ostream@_WU?$char_traits@_W@std@@@std@@6B@ */
418 extern const vtable_ptr MSVCP_basic_ostream_wchar_vtable
;
420 /* ??_8?$basic_ostream@GU?$char_traits@G@std@@@std@@7B@ */
421 const int basic_ostream_short_vbtable
[] = {0,
422 VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)};
423 /* ??_7?$basic_ostream@GU?$char_traits@G@std@@@std@@6B@ */
424 extern const vtable_ptr MSVCP_basic_ostream_short_vtable
;
426 /* ??_8?$basic_istream@DU?$char_traits@D@std@@@std@@7B@ */
427 const int basic_istream_char_vbtable
[] = {0,
428 VBTABLE_BASIC_IOS_ENTRY(basic_istream_char
, 0)};
429 /* ??_7?$basic_istream@DU?$char_traits@D@std@@@std@@6B@ */
430 extern const vtable_ptr MSVCP_basic_istream_char_vtable
;
432 /* ??_8?$basic_istream@_WU?$char_traits@_W@std@@@std@@7B@ */
433 const int basic_istream_wchar_vbtable
[] = {0,
434 VBTABLE_BASIC_IOS_ENTRY(basic_istream_wchar
, 0)};
435 /* ??_7?$basic_istream@_WU?$char_traits@_W@std@@@std@@6B@ */
436 extern const vtable_ptr MSVCP_basic_istream_wchar_vtable
;
438 /* ??_8?$basic_istream@GU?$char_traits@G@std@@@std@@7B@ */
439 const int basic_istream_short_vbtable
[] = {0,
440 VBTABLE_BASIC_IOS_ENTRY(basic_istream_wchar
, 0)};
441 /* ??_7?$basic_istream@GU?$char_traits@G@std@@@std@@6B@ */
442 extern const vtable_ptr MSVCP_basic_istream_short_vtable
;
444 /* ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
445 const int basic_iostream_char_vbtable1
[] = {0,
446 VBTABLE_BASIC_IOS_ENTRY(basic_iostream_char
, 0)};
447 /* ??_8?$basic_iostream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
448 const int basic_iostream_char_vbtable2
[] = {0,
449 VBTABLE_BASIC_IOS_ENTRY(basic_iostream_char
, FIELD_OFFSET(basic_iostream_char
, base2
))};
450 /* ??_7?$basic_iostream@DU?$char_traits@D@std@@@std@@6B@ */
451 extern const vtable_ptr MSVCP_basic_iostream_char_vtable
;
453 /* ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
454 /* ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
455 const int basic_iostream_wchar_vbtable1
[] = {0,
456 VBTABLE_BASIC_IOS_ENTRY(basic_iostream_wchar
, 0)};
457 /* ??_8?$basic_iostream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
458 /* ??_8?$basic_iostream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
459 const int basic_iostream_wchar_vbtable2
[] = {0,
460 VBTABLE_BASIC_IOS_ENTRY(basic_iostream_wchar
, FIELD_OFFSET(basic_iostream_wchar
, base2
))};
461 /* ??_7?$basic_iostream@_WU?$char_traits@_W@std@@@std@@6B@ */
462 extern const vtable_ptr MSVCP_basic_iostream_wchar_vtable
;
463 /* ??_7?$basic_iostream@GU?$char_traits@G@std@@@std@@6B@ */
464 extern const vtable_ptr MSVCP_basic_iostream_short_vtable
;
466 /* ??_8?$basic_ofstream@DU?$char_traits@D@std@@@std@@7B@ */
467 const int basic_ofstream_char_vbtable
[] = {0,
468 VBTABLE_BASIC_IOS_ENTRY(basic_ofstream_char
, 0)};
469 /* ??_7?$basic_ofstream@DU?$char_traits@D@std@@@std@@6B@ */
470 extern const vtable_ptr MSVCP_basic_ofstream_char_vtable
;
472 /* ??_8?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@7B@ */
473 const int basic_ofstream_wchar_vbtable
[] = {0,
474 VBTABLE_BASIC_IOS_ENTRY(basic_ofstream_wchar
, 0)};
475 /* ??_7?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@6B@ */
476 extern const vtable_ptr MSVCP_basic_ofstream_wchar_vtable
;
478 /* ??_8?$basic_ofstream@GU?$char_traits@G@std@@@std@@7B@ */
479 const int basic_ofstream_short_vbtable
[] = {0,
480 VBTABLE_BASIC_IOS_ENTRY(basic_ofstream_wchar
, 0)};
481 /* ??_7?$basic_ofstream@GU?$char_traits@G@std@@@std@@6B@ */
482 extern const vtable_ptr MSVCP_basic_ofstream_short_vtable
;
484 /* ??_8?$basic_ifstream@DU?$char_traits@D@std@@@std@@7B@ */
485 const int basic_ifstream_char_vbtable
[] = {0,
486 VBTABLE_BASIC_IOS_ENTRY(basic_ifstream_char
, 0)};
487 /* ??_7?$basic_ifstream@DU?$char_traits@D@std@@@std@@6B@ */
488 extern const vtable_ptr MSVCP_basic_ifstream_char_vtable
;
490 /* ??_8?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@7B@ */
491 const int basic_ifstream_wchar_vbtable
[] = {0,
492 VBTABLE_BASIC_IOS_ENTRY(basic_ifstream_wchar
, 0)};
493 /* ??_7?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@6B@ */
494 extern const vtable_ptr MSVCP_basic_ifstream_wchar_vtable
;
496 /* ??_8?$basic_ifstream@GU?$char_traits@G@std@@@std@@7B@ */
497 const int basic_ifstream_short_vbtable
[] = {0,
498 VBTABLE_BASIC_IOS_ENTRY(basic_ifstream_wchar
, 0)};
499 /* ??_7?$basic_ifstream@GU?$char_traits@G@std@@@std@@6B@ */
500 extern const vtable_ptr MSVCP_basic_ifstream_short_vtable
;
502 /* ??_8?$basic_fstream@DU?$char_traits@D@std@@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
503 const int basic_fstream_char_vbtable1
[] = {0,
504 VBTABLE_BASIC_IOS_ENTRY(basic_fstream_char
, 0)};
505 /* ??_8?$basic_fstream@DU?$char_traits@D@std@@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
506 const int basic_fstream_char_vbtable2
[] = {0,
507 VBTABLE_BASIC_IOS_ENTRY(basic_fstream_char
, FIELD_OFFSET(basic_fstream_char
, base
.base2
))};
508 /* ??_7?$basic_fstream@DU?$char_traits@D@std@@@std@@6B@ */
509 extern const vtable_ptr MSVCP_basic_fstream_char_vtable
;
511 /* ??_8?$basic_fstream@_WU?$char_traits@_W@std@@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
512 /* ??_8?$basic_fstream@GU?$char_traits@G@std@@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
513 const int basic_fstream_wchar_vbtable1
[] = {0,
514 VBTABLE_BASIC_IOS_ENTRY(basic_fstream_wchar
, 0)};
515 /* ??_8?$basic_fstream@_WU?$char_traits@_W@std@@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
516 /* ??_8?$basic_fstream@GU?$char_traits@G@std@@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
517 const int basic_fstream_wchar_vbtable2
[] = {0,
518 VBTABLE_BASIC_IOS_ENTRY(basic_fstream_wchar
, FIELD_OFFSET(basic_fstream_wchar
, base
.base2
))};
519 /* ??_7?$basic_fstream@_WU?$char_traits@_W@std@@@std@@6B@ */
520 extern const vtable_ptr MSVCP_basic_fstream_wchar_vtable
;
521 /* ??_7?$basic_fstream@GU?$char_traits@G@std@@@std@@6B@ */
522 extern const vtable_ptr MSVCP_basic_fstream_short_vtable
;
524 /* ??_8?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@ */
525 const int basic_ostringstream_char_vbtable
[] = {0,
526 VBTABLE_BASIC_IOS_ENTRY(basic_ostringstream_char
, 0)};
527 /* ??_7?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
528 extern const vtable_ptr MSVCP_basic_ostringstream_char_vtable
;
530 /* ??_8?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B@ */
531 const int basic_ostringstream_wchar_vbtable
[] = {0,
532 VBTABLE_BASIC_IOS_ENTRY(basic_ostringstream_wchar
, 0)};
533 /* ??_7?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
534 extern const vtable_ptr MSVCP_basic_ostringstream_wchar_vtable
;
536 /* ??_8?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B@ */
537 const int basic_ostringstream_short_vbtable
[] = {0,
538 VBTABLE_BASIC_IOS_ENTRY(basic_ostringstream_wchar
, 0)};
539 /* ??_7?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
540 extern const vtable_ptr MSVCP_basic_ostringstream_short_vtable
;
542 /* ??_8?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B@ */
543 const int basic_istringstream_char_vbtable
[] = {0,
544 VBTABLE_BASIC_IOS_ENTRY(basic_istringstream_char
, 0)};
545 /* ??_7?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
546 extern const vtable_ptr MSVCP_basic_istringstream_char_vtable
;
548 /* ??_8?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B@ */
549 const int basic_istringstream_wchar_vbtable
[] = {0,
550 VBTABLE_BASIC_IOS_ENTRY(basic_istringstream_wchar
, 0)};
551 /* ??_7?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
552 extern const vtable_ptr MSVCP_basic_istringstream_wchar_vtable
;
554 /* ??_8?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B@ */
555 const int basic_istringstream_short_vbtable
[] = {0,
556 VBTABLE_BASIC_IOS_ENTRY(basic_istringstream_wchar
, 0)};
557 /* ??_7?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
558 extern const vtable_ptr MSVCP_basic_istringstream_short_vtable
;
560 /* ??_8?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B?$basic_istream@DU?$char_traits@D@std@@@1@@ */
561 const int basic_stringstream_char_vbtable1
[] = {0,
562 VBTABLE_BASIC_IOS_ENTRY(basic_stringstream_char
, 0)};
563 /* ??_8?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@7B?$basic_ostream@DU?$char_traits@D@std@@@1@@ */
564 const int basic_stringstream_char_vbtable2
[] = {0,
565 VBTABLE_BASIC_IOS_ENTRY(basic_stringstream_char
, FIELD_OFFSET(basic_stringstream_char
, base
.base2
))};
566 /* ??_7?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@6B@ */
567 extern const vtable_ptr MSVCP_basic_stringstream_char_vtable
;
569 /* ??_8?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B?$basic_istream@_WU?$char_traits@_W@std@@@1@@ */
570 const int basic_stringstream_wchar_vbtable1
[] = {0,
571 VBTABLE_BASIC_IOS_ENTRY(basic_stringstream_wchar
, 0)};
572 /* ??_8?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@7B?$basic_ostream@_WU?$char_traits@_W@std@@@1@@ */
573 const int basic_stringstream_wchar_vbtable2
[] = {0,
574 VBTABLE_BASIC_IOS_ENTRY(basic_stringstream_wchar
, FIELD_OFFSET(basic_stringstream_wchar
, base
.base2
))};
575 /* ??_7?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@6B@ */
576 extern const vtable_ptr MSVCP_basic_stringstream_wchar_vtable
;
578 /* ??_8?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B?$basic_istream@GU?$char_traits@G@std@@@1@@ */
579 const int basic_stringstream_short_vbtable1
[] = {0,
580 VBTABLE_BASIC_IOS_ENTRY(basic_stringstream_wchar
, 0)};
581 /* ??_8?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@7B?$basic_ostream@GU?$char_traits@G@std@@@1@@ */
582 const int basic_stringstream_short_vbtable2
[] = {0,
583 VBTABLE_BASIC_IOS_ENTRY(basic_stringstream_wchar
, FIELD_OFFSET(basic_stringstream_wchar
, base
.base2
))};
584 /* ??_7?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@6B@ */
585 extern const vtable_ptr MSVCP_basic_stringstream_short_vtable
;
587 /* ??_7strstreambuf@std@@6B */
588 extern const vtable_ptr MSVCP_strstreambuf_vtable
;
590 static const int ostrstream_vbtable
[] = {0, VBTABLE_BASIC_IOS_ENTRY(ostrstream
, 0)};
591 extern const vtable_ptr MSVCP_ostrstream_vtable
;
593 static const int istrstream_vbtable
[] = {0, VBTABLE_BASIC_IOS_ENTRY(istrstream
, 0)};
595 static const int strstream_vbtable1
[] = {0, VBTABLE_BASIC_IOS_ENTRY(strstream
, 0)};
596 static const int strstream_vbtable2
[] = {0,
597 VBTABLE_BASIC_IOS_ENTRY(strstream
, FIELD_OFFSET(strstream
, base
.base2
))};
598 extern const vtable_ptr MSVCP_strstream_vtable
;
600 DEFINE_RTTI_DATA0(iosb
, 0, ".?AV?$_Iosb@H@std@@")
601 DEFINE_RTTI_DATA1(ios_base
, 0, &iosb_rtti_base_descriptor
, ".?AV?$_Iosb@H@std@@")
602 DEFINE_RTTI_DATA2(basic_ios_char
, 0, &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
603 ".?AV?$basic_ios@DU?$char_traits@D@std@@@std@@")
604 DEFINE_RTTI_DATA2(basic_ios_wchar
, 0, &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
605 ".?AV?$basic_ios@_WU?$char_traits@_W@std@@@std@@")
606 DEFINE_RTTI_DATA2(basic_ios_short
, 0, &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
607 ".?AV?$basic_ios@GU?$char_traits@G@std@@@std@@")
608 DEFINE_RTTI_DATA0(basic_streambuf_char
, 0,
609 ".?AV?$basic_streambuf@DU?$char_traits@D@std@@@std@@")
610 DEFINE_RTTI_DATA0(basic_streambuf_wchar
, 0,
611 ".?AV?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@")
612 DEFINE_RTTI_DATA0(basic_streambuf_short
, 0,
613 ".?AV?$basic_streambuf@GU?$char_traits@G@std@@@std@@")
614 DEFINE_RTTI_DATA1(basic_filebuf_char
, 0, &basic_streambuf_char_rtti_base_descriptor
,
615 ".?AV?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@")
616 DEFINE_RTTI_DATA1(basic_filebuf_wchar
, 0, &basic_streambuf_wchar_rtti_base_descriptor
,
617 ".?AV?$basic_filebuf@GU?$char_traits@G@std@@@std@@")
618 DEFINE_RTTI_DATA1(basic_filebuf_short
, 0, &basic_streambuf_short_rtti_base_descriptor
,
619 ".?AV?$basic_filebuf@DU?$char_traits@D@std@@@std@@")
620 DEFINE_RTTI_DATA1(basic_stringbuf_char
, 0, &basic_streambuf_char_rtti_base_descriptor
,
621 ".?AV?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
622 DEFINE_RTTI_DATA1(basic_stringbuf_wchar
, 0, &basic_streambuf_wchar_rtti_base_descriptor
,
623 ".?AV?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
624 DEFINE_RTTI_DATA1(basic_stringbuf_short
, 0, &basic_streambuf_short_rtti_base_descriptor
,
625 ".?AV?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
626 DEFINE_RTTI_DATA3(basic_ostream_char
, sizeof(basic_ostream_char
), &basic_ios_char_rtti_base_descriptor
,
627 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
628 ".?AV?$basic_ostream@DU?$char_traits@D@std@@@std@@")
629 DEFINE_RTTI_DATA3(basic_ostream_wchar
, sizeof(basic_ostream_wchar
), &basic_ios_wchar_rtti_base_descriptor
,
630 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
631 ".?AV?$basic_ostream@_WU?$char_traits@_W@std@@@std@@")
632 DEFINE_RTTI_DATA3(basic_ostream_short
, sizeof(basic_ostream_wchar
), &basic_ios_short_rtti_base_descriptor
,
633 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
634 ".?AV?$basic_ostream@GU?$char_traits@G@std@@@std@@")
635 DEFINE_RTTI_DATA3(basic_istream_char
, sizeof(basic_istream_char
), &basic_ios_char_rtti_base_descriptor
,
636 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
637 ".?AV?$basic_istream@DU?$char_traits@D@std@@@std@@")
638 DEFINE_RTTI_DATA3(basic_istream_wchar
, sizeof(basic_istream_wchar
), &basic_ios_wchar_rtti_base_descriptor
,
639 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
640 ".?AV?$basic_istream@_WU?$char_traits@_W@std@@@std@@")
641 DEFINE_RTTI_DATA3(basic_istream_short
, sizeof(basic_istream_wchar
), &basic_ios_short_rtti_base_descriptor
,
642 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
643 ".?AV?$basic_istream@GU?$char_traits@G@std@@@std@@")
644 DEFINE_RTTI_DATA8(basic_iostream_char
, sizeof(basic_iostream_char
),
645 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
646 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
647 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
648 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
649 ".?AV?$basic_iostream@DU?$char_traits@D@std@@@std@@")
650 DEFINE_RTTI_DATA8(basic_iostream_wchar
, sizeof(basic_iostream_wchar
),
651 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
652 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
653 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
654 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
655 ".?AV?$basic_iostream@_WU?$char_traits@_W@std@@@std@@")
656 DEFINE_RTTI_DATA8(basic_iostream_short
, sizeof(basic_iostream_wchar
),
657 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
658 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
659 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
660 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
661 ".?AV?$basic_iostream@GU?$char_traits@G@std@@@std@@")
662 DEFINE_RTTI_DATA4(basic_ofstream_char
, sizeof(basic_ofstream_char
),
663 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
664 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
665 ".?AV?$basic_ofstream@DU?$char_traits@D@std@@@std@@")
666 DEFINE_RTTI_DATA4(basic_ofstream_wchar
, sizeof(basic_ofstream_wchar
),
667 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
668 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
669 ".?AV?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@")
670 DEFINE_RTTI_DATA4(basic_ofstream_short
, sizeof(basic_ofstream_wchar
),
671 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
672 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
673 ".?AV?$basic_ofstream@GU?$char_traits@G@std@@@std@@")
674 DEFINE_RTTI_DATA4(basic_ifstream_char
, sizeof(basic_ifstream_char
),
675 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
676 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
677 ".?AV?$basic_ifstream@DU?$char_traits@D@std@@@std@@")
678 DEFINE_RTTI_DATA4(basic_ifstream_wchar
, sizeof(basic_ifstream_wchar
),
679 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
680 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
681 ".?AV?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@")
682 DEFINE_RTTI_DATA4(basic_ifstream_short
, sizeof(basic_ifstream_wchar
),
683 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
684 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
685 ".?AV?$basic_ifstream@GU?$char_traits@G@std@@@std@@")
686 DEFINE_RTTI_DATA8(basic_fstream_char
, sizeof(basic_fstream_char
),
687 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
688 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
689 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
690 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
691 ".?AV?$basic_fstream@DU?$char_traits@D@std@@@std@@")
692 DEFINE_RTTI_DATA8(basic_fstream_wchar
, sizeof(basic_fstream_wchar
),
693 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
694 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
695 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
696 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
697 ".?AV?$basic_fstream@_WU?$char_traits@_W@std@@@std@@")
698 DEFINE_RTTI_DATA8(basic_fstream_short
, sizeof(basic_fstream_wchar
),
699 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
700 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
701 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
702 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
703 ".?AV?$basic_fstream@GU?$char_traits@G@std@@@std@@")
704 DEFINE_RTTI_DATA4(basic_ostringstream_char
, sizeof(basic_ostringstream_char
),
705 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
706 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
707 ".?AV?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
708 DEFINE_RTTI_DATA4(basic_ostringstream_wchar
, sizeof(basic_ostringstream_wchar
),
709 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
710 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
711 ".?AV?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
712 DEFINE_RTTI_DATA4(basic_ostringstream_short
, sizeof(basic_ostringstream_wchar
),
713 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
714 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
715 ".?AV?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
716 DEFINE_RTTI_DATA4(basic_istringstream_char
, sizeof(basic_istringstream_char
),
717 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
718 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
719 ".?AV?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
720 DEFINE_RTTI_DATA4(basic_istringstream_wchar
, sizeof(basic_istringstream_wchar
),
721 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
722 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
723 ".?AV?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
724 DEFINE_RTTI_DATA4(basic_istringstream_short
, sizeof(basic_istringstream_wchar
),
725 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
726 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
727 ".?AV?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
728 DEFINE_RTTI_DATA8(basic_stringstream_char
, sizeof(basic_stringstream_char
),
729 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
730 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
731 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
732 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
733 ".?AV?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@")
734 DEFINE_RTTI_DATA8(basic_stringstream_wchar
, sizeof(basic_stringstream_wchar
),
735 &basic_istream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
736 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
737 &basic_ostream_wchar_rtti_base_descriptor
, &basic_ios_wchar_rtti_base_descriptor
,
738 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
739 ".?AV?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@")
740 DEFINE_RTTI_DATA8(basic_stringstream_short
, sizeof(basic_stringstream_wchar
),
741 &basic_istream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
742 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
743 &basic_ostream_short_rtti_base_descriptor
, &basic_ios_short_rtti_base_descriptor
,
744 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
745 ".?AV?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@")
746 DEFINE_RTTI_DATA1(strstreambuf
, sizeof(strstreambuf
),
747 &basic_streambuf_char_rtti_base_descriptor
, ".?AVstrstreambuf@std@@")
748 DEFINE_RTTI_DATA4(ostrstream
, sizeof(ostrstream
),
749 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
750 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
751 "?AVostrstream@std@@")
752 DEFINE_RTTI_DATA8(strstream
, sizeof(strstream
),
753 &basic_istream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
754 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
755 &basic_ostream_char_rtti_base_descriptor
, &basic_ios_char_rtti_base_descriptor
,
756 &ios_base_rtti_base_descriptor
, &iosb_rtti_base_descriptor
,
757 "?AVstrstream@std@@")
759 __ASM_BLOCK_BEGIN(ios_vtables
)
761 VTABLE_ADD_FUNC(iosb_vector_dtor
));
762 __ASM_VTABLE(ios_base
,
763 VTABLE_ADD_FUNC(ios_base_vector_dtor
));
764 __ASM_VTABLE(basic_ios_char
,
765 VTABLE_ADD_FUNC(basic_ios_char_vector_dtor
)
766 #if _MSVCP_VER == 110
767 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
768 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
771 __ASM_VTABLE(basic_ios_wchar
,
772 VTABLE_ADD_FUNC(basic_ios_wchar_vector_dtor
)
773 #if _MSVCP_VER == 110
774 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
775 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
778 __ASM_VTABLE(basic_ios_short
,
779 VTABLE_ADD_FUNC(basic_ios_wchar_vector_dtor
)
780 #if _MSVCP_VER == 110
781 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
782 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
785 __ASM_VTABLE(basic_streambuf_char
,
786 VTABLE_ADD_FUNC(basic_streambuf_char_vector_dtor
)
787 #if _MSVCP_VER >= 100
788 VTABLE_ADD_FUNC(basic_streambuf_char__Lock
)
789 VTABLE_ADD_FUNC(basic_streambuf_char__Unlock
)
791 VTABLE_ADD_FUNC(basic_streambuf_char_overflow
)
792 VTABLE_ADD_FUNC(basic_streambuf_char_pbackfail
)
793 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
794 VTABLE_ADD_FUNC(basic_streambuf_char_underflow
)
795 VTABLE_ADD_FUNC(basic_streambuf_char_uflow
)
796 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
797 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
798 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
800 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
801 VTABLE_ADD_FUNC(basic_streambuf_char_seekoff
)
802 VTABLE_ADD_FUNC(basic_streambuf_char_seekpos
)
803 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf
)
804 VTABLE_ADD_FUNC(basic_streambuf_char_sync
)
805 VTABLE_ADD_FUNC(basic_streambuf_char_imbue
));
806 __ASM_VTABLE(basic_streambuf_wchar
,
807 VTABLE_ADD_FUNC(basic_streambuf_wchar_vector_dtor
)
808 #if _MSVCP_VER >= 100
809 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
810 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
812 VTABLE_ADD_FUNC(basic_streambuf_wchar_overflow
)
813 VTABLE_ADD_FUNC(basic_streambuf_wchar_pbackfail
)
814 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
815 VTABLE_ADD_FUNC(basic_streambuf_wchar_underflow
)
816 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
817 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
818 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
819 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
821 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
822 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekoff
)
823 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekpos
)
824 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
825 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
826 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
827 __ASM_VTABLE(basic_streambuf_short
,
828 VTABLE_ADD_FUNC(basic_streambuf_wchar_vector_dtor
)
829 #if _MSVCP_VER >= 100
830 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
831 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
833 VTABLE_ADD_FUNC(basic_streambuf_wchar_overflow
)
834 VTABLE_ADD_FUNC(basic_streambuf_wchar_pbackfail
)
835 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
836 VTABLE_ADD_FUNC(basic_streambuf_wchar_underflow
)
837 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
838 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
839 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
840 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
842 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
843 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekoff
)
844 VTABLE_ADD_FUNC(basic_streambuf_wchar_seekpos
)
845 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
846 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
847 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
848 __ASM_VTABLE(basic_filebuf_char
,
849 VTABLE_ADD_FUNC(basic_filebuf_char_vector_dtor
)
850 #if _MSVCP_VER >= 100
851 VTABLE_ADD_FUNC(basic_streambuf_char__Lock
)
852 VTABLE_ADD_FUNC(basic_streambuf_char__Unlock
)
854 VTABLE_ADD_FUNC(basic_filebuf_char_overflow
)
855 VTABLE_ADD_FUNC(basic_filebuf_char_pbackfail
)
856 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
857 VTABLE_ADD_FUNC(basic_filebuf_char_underflow
)
858 VTABLE_ADD_FUNC(basic_filebuf_char_uflow
)
859 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
860 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
861 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
863 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
864 VTABLE_ADD_FUNC(basic_filebuf_char_seekoff
)
865 VTABLE_ADD_FUNC(basic_filebuf_char_seekpos
)
866 VTABLE_ADD_FUNC(basic_filebuf_char_setbuf
)
867 VTABLE_ADD_FUNC(basic_filebuf_char_sync
)
868 VTABLE_ADD_FUNC(basic_filebuf_char_imbue
));
869 __ASM_VTABLE(basic_filebuf_wchar
,
870 VTABLE_ADD_FUNC(basic_filebuf_wchar_vector_dtor
)
871 #if _MSVCP_VER >= 100
872 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
873 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
875 VTABLE_ADD_FUNC(basic_filebuf_wchar_overflow
)
876 VTABLE_ADD_FUNC(basic_filebuf_wchar_pbackfail
)
877 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
878 VTABLE_ADD_FUNC(basic_filebuf_wchar_underflow
)
879 VTABLE_ADD_FUNC(basic_filebuf_wchar_uflow
)
880 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
881 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
882 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
884 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
885 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekoff
)
886 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekpos
)
887 VTABLE_ADD_FUNC(basic_filebuf_wchar_setbuf
)
888 VTABLE_ADD_FUNC(basic_filebuf_wchar_sync
)
889 VTABLE_ADD_FUNC(basic_filebuf_wchar_imbue
));
890 __ASM_VTABLE(basic_filebuf_short
,
891 VTABLE_ADD_FUNC(basic_filebuf_wchar_vector_dtor
)
892 #if _MSVCP_VER >= 100
893 VTABLE_ADD_FUNC(basic_streambuf_wchar__Lock
)
894 VTABLE_ADD_FUNC(basic_streambuf_wchar__Unlock
)
896 VTABLE_ADD_FUNC(basic_filebuf_wchar_overflow
)
897 VTABLE_ADD_FUNC(basic_filebuf_wchar_pbackfail
)
898 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
899 VTABLE_ADD_FUNC(basic_filebuf_wchar_underflow
)
900 VTABLE_ADD_FUNC(basic_filebuf_wchar_uflow
)
901 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
902 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
903 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
905 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
906 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekoff
)
907 VTABLE_ADD_FUNC(basic_filebuf_wchar_seekpos
)
908 VTABLE_ADD_FUNC(basic_filebuf_short_setbuf
)
909 VTABLE_ADD_FUNC(basic_filebuf_wchar_sync
)
910 VTABLE_ADD_FUNC(basic_filebuf_short_imbue
));
911 __ASM_VTABLE(basic_stringbuf_char
,
912 VTABLE_ADD_FUNC(basic_stringbuf_char_vector_dtor
)
913 VTABLE_ADD_FUNC(basic_stringbuf_char_overflow
)
914 VTABLE_ADD_FUNC(basic_stringbuf_char_pbackfail
)
915 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
916 VTABLE_ADD_FUNC(basic_stringbuf_char_underflow
)
917 VTABLE_ADD_FUNC(basic_streambuf_char_uflow
)
918 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
919 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
920 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
922 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
923 VTABLE_ADD_FUNC(basic_stringbuf_char_seekoff
)
924 VTABLE_ADD_FUNC(basic_stringbuf_char_seekpos
)
925 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf
)
926 VTABLE_ADD_FUNC(basic_streambuf_char_sync
)
927 VTABLE_ADD_FUNC(basic_streambuf_char_imbue
));
928 __ASM_VTABLE(basic_stringbuf_wchar
,
929 VTABLE_ADD_FUNC(basic_stringbuf_wchar_vector_dtor
)
930 VTABLE_ADD_FUNC(basic_stringbuf_wchar_overflow
)
931 VTABLE_ADD_FUNC(basic_stringbuf_wchar_pbackfail
)
932 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
933 VTABLE_ADD_FUNC(basic_stringbuf_wchar_underflow
)
934 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
935 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
936 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
937 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
939 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
940 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekoff
)
941 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekpos
)
942 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
943 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
944 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
945 __ASM_VTABLE(basic_stringbuf_short
,
946 VTABLE_ADD_FUNC(basic_stringbuf_wchar_vector_dtor
)
947 VTABLE_ADD_FUNC(basic_stringbuf_wchar_overflow
)
948 VTABLE_ADD_FUNC(basic_stringbuf_wchar_pbackfail
)
949 VTABLE_ADD_FUNC(basic_streambuf_wchar_showmanyc
)
950 VTABLE_ADD_FUNC(basic_stringbuf_wchar_underflow
)
951 VTABLE_ADD_FUNC(basic_streambuf_wchar_uflow
)
952 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsgetn
)
953 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
954 VTABLE_ADD_FUNC(basic_streambuf_wchar__Xsgetn_s
)
956 VTABLE_ADD_FUNC(basic_streambuf_wchar_xsputn
)
957 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekoff
)
958 VTABLE_ADD_FUNC(basic_stringbuf_wchar_seekpos
)
959 VTABLE_ADD_FUNC(basic_streambuf_wchar_setbuf
)
960 VTABLE_ADD_FUNC(basic_streambuf_wchar_sync
)
961 VTABLE_ADD_FUNC(basic_streambuf_wchar_imbue
));
962 __ASM_VTABLE(basic_ostream_char
,
963 VTABLE_ADD_FUNC(basic_ostream_char_vector_dtor
)
964 #if _MSVCP_VER == 110
965 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
966 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
969 __ASM_VTABLE(basic_ostream_wchar
,
970 VTABLE_ADD_FUNC(basic_ostream_wchar_vector_dtor
)
971 #if _MSVCP_VER == 110
972 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
973 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
976 __ASM_VTABLE(basic_ostream_short
,
977 VTABLE_ADD_FUNC(basic_ostream_wchar_vector_dtor
)
978 #if _MSVCP_VER == 110
979 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
980 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
983 __ASM_VTABLE(basic_istream_char
,
984 VTABLE_ADD_FUNC(basic_istream_char_vector_dtor
)
985 #if _MSVCP_VER == 110
986 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
987 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
990 __ASM_VTABLE(basic_istream_wchar
,
991 VTABLE_ADD_FUNC(basic_istream_wchar_vector_dtor
)
992 #if _MSVCP_VER == 110
993 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
994 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
997 __ASM_VTABLE(basic_istream_short
,
998 VTABLE_ADD_FUNC(basic_istream_wchar_vector_dtor
)
999 #if _MSVCP_VER == 110
1000 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1001 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1004 __ASM_VTABLE(basic_iostream_char
,
1005 VTABLE_ADD_FUNC(basic_iostream_char_vector_dtor
)
1006 #if _MSVCP_VER == 110
1007 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1008 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1011 __ASM_VTABLE(basic_iostream_wchar
,
1012 VTABLE_ADD_FUNC(basic_iostream_wchar_vector_dtor
)
1013 #if _MSVCP_VER == 110
1014 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1015 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1018 __ASM_VTABLE(basic_iostream_short
,
1019 VTABLE_ADD_FUNC(basic_iostream_wchar_vector_dtor
)
1020 #if _MSVCP_VER == 110
1021 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1022 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1025 __ASM_VTABLE(basic_ofstream_char
,
1026 VTABLE_ADD_FUNC(basic_ofstream_char_vector_dtor
)
1027 #if _MSVCP_VER == 110
1028 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1029 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1032 __ASM_VTABLE(basic_ofstream_wchar
,
1033 VTABLE_ADD_FUNC(basic_ofstream_wchar_vector_dtor
)
1034 #if _MSVCP_VER == 110
1035 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1036 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1039 __ASM_VTABLE(basic_ofstream_short
,
1040 VTABLE_ADD_FUNC(basic_ofstream_wchar_vector_dtor
)
1041 #if _MSVCP_VER == 110
1042 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1043 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1046 __ASM_VTABLE(basic_ifstream_char
,
1047 VTABLE_ADD_FUNC(basic_ifstream_char_vector_dtor
)
1048 #if _MSVCP_VER == 110
1049 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1050 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1053 __ASM_VTABLE(basic_ifstream_wchar
,
1054 VTABLE_ADD_FUNC(basic_ifstream_wchar_vector_dtor
)
1055 #if _MSVCP_VER == 110
1056 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1057 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1060 __ASM_VTABLE(basic_ifstream_short
,
1061 VTABLE_ADD_FUNC(basic_ifstream_wchar_vector_dtor
)
1062 #if _MSVCP_VER == 110
1063 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1064 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1067 __ASM_VTABLE(basic_fstream_char
,
1068 VTABLE_ADD_FUNC(basic_fstream_char_vector_dtor
)
1069 #if _MSVCP_VER == 110
1070 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1071 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1074 __ASM_VTABLE(basic_fstream_wchar
,
1075 VTABLE_ADD_FUNC(basic_fstream_wchar_vector_dtor
)
1076 #if _MSVCP_VER == 110
1077 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1078 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1081 __ASM_VTABLE(basic_fstream_short
,
1082 VTABLE_ADD_FUNC(basic_fstream_wchar_vector_dtor
)
1083 #if _MSVCP_VER == 110
1084 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1085 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1088 __ASM_VTABLE(basic_ostringstream_char
,
1089 VTABLE_ADD_FUNC(basic_ostringstream_char_vector_dtor
)
1090 #if _MSVCP_VER == 110
1091 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1092 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1095 __ASM_VTABLE(basic_ostringstream_wchar
,
1096 VTABLE_ADD_FUNC(basic_ostringstream_wchar_vector_dtor
)
1097 #if _MSVCP_VER == 110
1098 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1099 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1102 __ASM_VTABLE(basic_ostringstream_short
,
1103 VTABLE_ADD_FUNC(basic_ostringstream_wchar_vector_dtor
)
1104 #if _MSVCP_VER == 110
1105 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1106 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1109 __ASM_VTABLE(basic_istringstream_char
,
1110 VTABLE_ADD_FUNC(basic_istringstream_char_vector_dtor
)
1111 #if _MSVCP_VER == 110
1112 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1113 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1116 __ASM_VTABLE(basic_istringstream_wchar
,
1117 VTABLE_ADD_FUNC(basic_istringstream_wchar_vector_dtor
)
1118 #if _MSVCP_VER == 110
1119 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1120 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1123 __ASM_VTABLE(basic_istringstream_short
,
1124 VTABLE_ADD_FUNC(basic_istringstream_wchar_vector_dtor
)
1125 #if _MSVCP_VER == 110
1126 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1127 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1130 __ASM_VTABLE(basic_stringstream_char
,
1131 VTABLE_ADD_FUNC(basic_stringstream_char_vector_dtor
)
1132 #if _MSVCP_VER == 110
1133 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1134 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1137 __ASM_VTABLE(basic_stringstream_wchar
,
1138 VTABLE_ADD_FUNC(basic_stringstream_wchar_vector_dtor
)
1139 #if _MSVCP_VER == 110
1140 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1141 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1144 __ASM_VTABLE(basic_stringstream_short
,
1145 VTABLE_ADD_FUNC(basic_stringstream_wchar_vector_dtor
)
1146 #if _MSVCP_VER == 110
1147 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1148 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1151 __ASM_VTABLE(strstreambuf
,
1152 VTABLE_ADD_FUNC(strstreambuf_vector_dtor
)
1153 VTABLE_ADD_FUNC(strstreambuf_overflow
)
1154 VTABLE_ADD_FUNC(strstreambuf_pbackfail
)
1155 VTABLE_ADD_FUNC(basic_streambuf_char_showmanyc
)
1156 VTABLE_ADD_FUNC(strstreambuf_underflow
)
1157 VTABLE_ADD_FUNC(basic_streambuf_char_uflow
)
1158 VTABLE_ADD_FUNC(basic_streambuf_char_xsgetn
)
1159 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
1160 VTABLE_ADD_FUNC(basic_streambuf_char__Xsgetn_s
)
1162 VTABLE_ADD_FUNC(basic_streambuf_char_xsputn
)
1163 VTABLE_ADD_FUNC(strstreambuf_seekoff
)
1164 VTABLE_ADD_FUNC(strstreambuf_seekpos
)
1165 VTABLE_ADD_FUNC(basic_streambuf_char_setbuf
)
1166 VTABLE_ADD_FUNC(basic_streambuf_char_sync
)
1167 VTABLE_ADD_FUNC(basic_streambuf_char_imbue
));
1168 __ASM_VTABLE(ostrstream
,
1169 VTABLE_ADD_FUNC(ostrstream_vector_dtor
)
1170 #if _MSVCP_VER == 110
1171 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1172 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1175 __ASM_VTABLE(strstream
,
1176 VTABLE_ADD_FUNC(strstream_vector_dtor
)
1177 #if _MSVCP_VER == 110
1178 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp1
)
1179 VTABLE_ADD_FUNC(basic_ios__Add_vtordisp2
)
1184 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z */
1185 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z */
1186 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setp_next
, 16)
1187 void __thiscall
basic_streambuf_char_setp_next(basic_streambuf_char
*this, char *first
, char *next
, char *last
)
1189 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
1193 this->wsize
= last
-next
;
1196 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD0@Z */
1197 /* ?setp@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD0@Z */
1198 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setp
, 12)
1199 void __thiscall
basic_streambuf_char_setp(basic_streambuf_char
*this, char *first
, char *last
)
1201 basic_streambuf_char_setp_next(this, first
, first
, last
);
1204 /* ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAD00@Z */
1205 /* ?setg@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAD00@Z */
1206 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setg
, 16)
1207 void __thiscall
basic_streambuf_char_setg(basic_streambuf_char
*this, char *first
, char *next
, char *last
)
1209 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
1213 this->rsize
= last
-next
;
1216 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXXZ */
1217 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXXZ */
1218 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Init_empty
, 4)
1219 void __thiscall
basic_streambuf_char__Init_empty(basic_streambuf_char
*this)
1221 TRACE("(%p)\n", this);
1223 this->prbuf
= &this->rbuf
;
1224 this->pwbuf
= &this->wbuf
;
1225 this->prpos
= &this->rpos
;
1226 this->pwpos
= &this->wpos
;
1227 this->prsize
= &this->rsize
;
1228 this->pwsize
= &this->wsize
;
1230 basic_streambuf_char_setp(this, NULL
, NULL
);
1231 basic_streambuf_char_setg(this, NULL
, NULL
, NULL
);
1234 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@W4_Uninitialized@1@@Z */
1235 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
1236 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_ctor_uninitialized
, 8)
1237 basic_streambuf_char
* __thiscall
basic_streambuf_char_ctor_uninitialized(basic_streambuf_char
*this, int uninitialized
)
1239 TRACE("(%p %d)\n", this, uninitialized
);
1240 this->vtable
= &MSVCP_basic_streambuf_char_vtable
;
1241 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1242 mutex_ctor(&this->lock
);
1247 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAE@XZ */
1248 /* ??0?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAA@XZ */
1249 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_ctor
, 4)
1250 basic_streambuf_char
* __thiscall
basic_streambuf_char_ctor(basic_streambuf_char
*this)
1252 TRACE("(%p)\n", this);
1254 this->vtable
= &MSVCP_basic_streambuf_char_vtable
;
1255 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1256 mutex_ctor(&this->lock
);
1258 #if _MSVCP_VER >= 70
1259 this->loc
= MSVCRT_operator_new(sizeof(locale
));
1261 locale_ctor(IOS_LOCALE(this));
1262 basic_streambuf_char__Init_empty(this);
1267 /* ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UAE@XZ */
1268 /* ??1?$basic_streambuf@DU?$char_traits@D@std@@@std@@UEAA@XZ */
1269 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_dtor
, 4)
1270 void __thiscall
basic_streambuf_char_dtor(basic_streambuf_char
*this)
1272 TRACE("(%p)\n", this);
1274 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1275 mutex_dtor(&this->lock
);
1277 locale_dtor(IOS_LOCALE(this));
1278 #if _MSVCP_VER >= 70
1279 MSVCRT_operator_delete(this->loc
);
1283 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_vector_dtor
, 8)
1284 basic_streambuf_char
* __thiscall
basic_streambuf_char_vector_dtor(basic_streambuf_char
*this, unsigned int flags
)
1286 TRACE("(%p %x)\n", this, flags
);
1288 /* we have an array, with the number of elements stored before the first object */
1289 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
1291 for(i
=*ptr
-1; i
>=0; i
--)
1292 basic_streambuf_char_dtor(this+i
);
1293 MSVCRT_operator_delete(ptr
);
1295 basic_streambuf_char_dtor(this);
1297 MSVCRT_operator_delete(this);
1303 /* ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEHXZ */
1304 /* ?_Gnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ */
1305 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gnavail
, 4)
1306 streamsize __thiscall
basic_streambuf_char__Gnavail(const basic_streambuf_char
*this)
1308 TRACE("(%p)\n", this);
1309 return *this->prpos
? *this->prsize
: 0;
1312 /* ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1313 /* ?_Gndec@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1314 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gndec
, 4)
1315 char* __thiscall
basic_streambuf_char__Gndec(basic_streambuf_char
*this)
1317 TRACE("(%p)\n", this);
1320 return *this->prpos
;
1323 /* ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1324 /* ?_Gninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1325 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gninc
, 4)
1326 char* __thiscall
basic_streambuf_char__Gninc(basic_streambuf_char
*this)
1328 TRACE("(%p)\n", this);
1330 return (*this->prpos
)++;
1333 /* ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1334 /* ?_Gnpreinc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1335 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Gnpreinc
, 4)
1336 char* __thiscall
basic_streambuf_char__Gnpreinc(basic_streambuf_char
*this)
1338 TRACE("(%p)\n", this);
1341 return *this->prpos
;
1344 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXPAPAD0PAH001@Z */
1345 /* ?_Init@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXPEAPEAD0PEAH001@Z */
1346 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Init
, 28)
1347 void __thiscall
basic_streambuf_char__Init(basic_streambuf_char
*this, char **gf
, char **gn
, int *gc
, char **pf
, char **pn
, int *pc
)
1349 TRACE("(%p %p %p %p %p %p %p)\n", this, gf
, gn
, gc
, pf
, pn
, pc
);
1359 /* ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1360 /* ?_Lock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1361 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Lock
, 4)
1362 #if _MSVCP_VER >= 100
1363 #define call_basic_streambuf_char__Lock(this) CALL_VTBL_FUNC(this, 4, void, (basic_streambuf_char*), (this))
1365 #define call_basic_streambuf_char__Lock(this) basic_streambuf_char__Lock(this)
1367 void __thiscall
basic_streambuf_char__Lock(basic_streambuf_char
*this)
1369 TRACE("(%p)\n", this);
1370 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1371 mutex_lock(&this->lock
);
1375 /* ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEHXZ */
1376 /* ?_Pnavail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBA_JXZ */
1377 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Pnavail
, 4)
1378 streamsize __thiscall
basic_streambuf_char__Pnavail(const basic_streambuf_char
*this)
1380 TRACE("(%p)\n", this);
1381 return *this->pwpos
? *this->pwsize
: 0;
1384 /* ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEPADXZ */
1385 /* ?_Pninc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAPEADXZ */
1386 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Pninc
, 4)
1387 char* __thiscall
basic_streambuf_char__Pninc(basic_streambuf_char
*this)
1389 TRACE("(%p)\n", this);
1391 return (*this->pwpos
)++;
1394 /* ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1395 /* ?underflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1396 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_underflow
, 4)
1397 #if _MSVCP_VER >= 100
1398 #define call_basic_streambuf_char_underflow(this) CALL_VTBL_FUNC(this, 24, int, (basic_streambuf_char*), (this))
1400 #define call_basic_streambuf_char_underflow(this) CALL_VTBL_FUNC(this, 16, int, (basic_streambuf_char*), (this))
1402 int __thiscall
basic_streambuf_char_underflow(basic_streambuf_char
*this)
1404 TRACE("(%p)\n", this);
1408 /* ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1409 /* ?uflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1410 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_uflow
, 4)
1411 #if _MSVCP_VER >= 100
1412 #define call_basic_streambuf_char_uflow(this) CALL_VTBL_FUNC(this, 28, int, (basic_streambuf_char*), (this))
1414 #define call_basic_streambuf_char_uflow(this) CALL_VTBL_FUNC(this, 20, int, (basic_streambuf_char*), (this))
1416 int __thiscall
basic_streambuf_char_uflow(basic_streambuf_char
*this)
1420 TRACE("(%p)\n", this);
1422 if(call_basic_streambuf_char_underflow(this)==EOF
)
1425 ret
= (unsigned char)**this->prpos
;
1431 /* ?_Xsgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPADIH@Z */
1432 /* ?_Xsgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_K_J@Z */
1433 #if STREAMSIZE_BITS == 64
1434 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Xsgetn_s
, 20)
1436 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Xsgetn_s
, 16)
1438 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
1439 #define call_basic_streambuf_char__Xsgetn_s(this, ptr, size, count) CALL_VTBL_FUNC(this, 28, \
1440 streamsize, (basic_streambuf_char*, char*, size_t, streamsize), (this, ptr, size, count))
1442 #define call_basic_streambuf_char__Xsgetn_s(this, ptr, size, count) basic_streambuf_char__Xsgetn_s(this, ptr, size, count)
1444 streamsize __thiscall
basic_streambuf_char__Xsgetn_s(basic_streambuf_char
*this, char *ptr
, size_t size
, streamsize count
)
1446 streamsize copied
, chunk
;
1449 TRACE("(%p %p %Iu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
1451 for(copied
=0; copied
<count
&& size
;) {
1452 chunk
= basic_streambuf_char__Gnavail(this);
1453 if(chunk
> count
-copied
)
1454 chunk
= count
-copied
;
1457 memcpy_s(ptr
+copied
, size
, *this->prpos
, chunk
);
1458 *this->prpos
+= chunk
;
1459 *this->prsize
-= chunk
;
1462 }else if((c
= call_basic_streambuf_char_uflow(this)) != EOF
) {
1474 /* ?_Sgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPADIH@Z */
1475 /* ?_Sgetn_s@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_K_J@Z */
1476 #if STREAMSIZE_BITS == 64
1477 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Sgetn_s
, 20)
1479 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Sgetn_s
, 16)
1481 streamsize __thiscall
basic_streambuf_char__Sgetn_s(basic_streambuf_char
*this, char *ptr
, size_t size
, streamsize count
)
1483 TRACE("(%p %p %Iu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
1484 return call_basic_streambuf_char__Xsgetn_s(this, ptr
, size
, count
);
1487 /* ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1488 /* ?_Unlock@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1489 DEFINE_THISCALL_WRAPPER(basic_streambuf_char__Unlock
, 4)
1490 #if _MSVCP_VER >= 100
1491 #define call_basic_streambuf_char__Unlock(this) CALL_VTBL_FUNC(this, 8, void, (basic_streambuf_char*), (this))
1493 #define call_basic_streambuf_char__Unlock(this) basic_streambuf_char__Unlock(this)
1495 void __thiscall
basic_streambuf_char__Unlock(basic_streambuf_char
*this)
1497 TRACE("(%p)\n", this);
1498 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
1499 mutex_unlock(&this->lock
);
1503 /* ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1504 /* ?eback@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1505 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_eback
, 4)
1506 char* __thiscall
basic_streambuf_char_eback(const basic_streambuf_char
*this)
1508 TRACE("(%p)\n", this);
1509 return *this->prbuf
;
1512 /* ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1513 /* ?gptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1514 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_gptr
, 4)
1515 char* __thiscall
basic_streambuf_char_gptr(const basic_streambuf_char
*this)
1517 TRACE("(%p)\n", this);
1518 return *this->prpos
;
1521 /* ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1522 /* ?egptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1523 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_egptr
, 4)
1524 char* __thiscall
basic_streambuf_char_egptr(const basic_streambuf_char
*this)
1526 TRACE("(%p)\n", this);
1527 return *this->prpos
+*this->prsize
;
1530 /* ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1531 /* ?epptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1532 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_epptr
, 4)
1533 char* __thiscall
basic_streambuf_char_epptr(const basic_streambuf_char
*this)
1535 TRACE("(%p)\n", this);
1536 return *this->pwpos
+*this->pwsize
;
1539 /* ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z */
1540 /* ?gbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z */
1541 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_gbump
, 8)
1542 void __thiscall
basic_streambuf_char_gbump(basic_streambuf_char
*this, int off
)
1544 TRACE("(%p %d)\n", this, off
);
1545 *this->prpos
+= off
;
1546 *this->prsize
-= off
;
1549 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@XZ */
1550 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QBE?AVlocale@2@XZ */
1551 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@XZ */
1552 /* ?getloc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEBA?AVlocale@2@XZ */
1553 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_getloc
, 8)
1554 locale
* __thiscall
basic_streambuf_char_getloc(const basic_streambuf_char
*this, locale
*ret
)
1556 TRACE("(%p)\n", this);
1557 return locale_copy_ctor(ret
, IOS_LOCALE(this));
1560 /* ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z */
1561 /* ?imbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z */
1562 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_imbue
, 8)
1563 #if _MSVCP_VER >= 100
1564 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 56, void, (basic_streambuf_char*, const locale*), (this, loc))
1565 #elif _MSVCP_VER >= 80
1566 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 52, void, (basic_streambuf_char*, const locale*), (this, loc))
1568 #define call_basic_streambuf_char_imbue(this, loc) CALL_VTBL_FUNC(this, 48, void, (basic_streambuf_char*, const locale*), (this, loc))
1570 void __thiscall
basic_streambuf_char_imbue(basic_streambuf_char
*this, const locale
*loc
)
1572 TRACE("(%p %p)\n", this, loc
);
1575 /* ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
1576 /* ?overflow@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
1577 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_overflow
, 8)
1578 #if _MSVCP_VER >= 100
1579 #define call_basic_streambuf_char_overflow(this, ch) CALL_VTBL_FUNC(this, 12, int, (basic_streambuf_char*, int), (this, ch))
1581 #define call_basic_streambuf_char_overflow(this, ch) CALL_VTBL_FUNC(this, 4, int, (basic_streambuf_char*, int), (this, ch))
1583 int __thiscall
basic_streambuf_char_overflow(basic_streambuf_char
*this, int ch
)
1585 TRACE("(%p %d)\n", this, ch
);
1589 /* ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
1590 /* ?pbackfail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
1591 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbackfail
, 8)
1592 #if _MSVCP_VER >= 100
1593 #define call_basic_streambuf_char_pbackfail(this, ch) CALL_VTBL_FUNC(this, 16, int, (basic_streambuf_char*, int), (this, ch))
1595 #define call_basic_streambuf_char_pbackfail(this, ch) CALL_VTBL_FUNC(this, 8, int, (basic_streambuf_char*, int), (this, ch))
1597 int __thiscall
basic_streambuf_char_pbackfail(basic_streambuf_char
*this, int ch
)
1599 TRACE("(%p %d)\n", this, ch
);
1603 /* ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1604 /* ?pbase@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1605 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbase
, 4)
1606 char* __thiscall
basic_streambuf_char_pbase(const basic_streambuf_char
*this)
1608 TRACE("(%p)\n", this);
1609 return *this->pwbuf
;
1612 /* ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXH@Z */
1613 /* ?pbump@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXH@Z */
1614 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pbump
, 8)
1615 void __thiscall
basic_streambuf_char_pbump(basic_streambuf_char
*this, int off
)
1617 TRACE("(%p %d)\n", this, off
);
1618 *this->pwpos
+= off
;
1619 *this->pwsize
-= off
;
1622 /* ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IBEPADXZ */
1623 /* ?pptr@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEBAPEADXZ */
1624 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pptr
, 4)
1625 char* __thiscall
basic_streambuf_char_pptr(const basic_streambuf_char
*this)
1627 TRACE("(%p)\n", this);
1628 return *this->pwpos
;
1631 /* ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
1632 /* ?pubimbue@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
1633 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubimbue
, 12)
1634 locale
* __thiscall
basic_streambuf_char_pubimbue(basic_streambuf_char
*this, locale
*ret
, const locale
*loc
)
1636 TRACE("(%p %p)\n", this, loc
);
1637 memcpy(ret
, IOS_LOCALE(this), sizeof(locale
));
1638 call_basic_streambuf_char_imbue(this, loc
);
1639 locale_copy_ctor(IOS_LOCALE(this), loc
);
1643 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
1644 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
1645 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
1646 /* ?seekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
1647 #if STREAMOFF_BITS == 64
1648 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekoff
, 24)
1650 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekoff
, 20)
1652 #if _MSVCP_VER >= 100
1653 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) \
1654 CALL_VTBL_FUNC(this, 40, fpos_mbstatet*, (basic_streambuf_char*, fpos_mbstatet*, streamoff, int, int), (this, ret, off, way, mode))
1655 #elif _MSVCP_VER >= 80
1656 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) \
1657 CALL_VTBL_FUNC(this, 36, fpos_mbstatet*, (basic_streambuf_char*, fpos_mbstatet*, streamoff, int, int), (this, ret, off, way, mode))
1659 #define call_basic_streambuf_char_seekoff(this, ret, off, way, mode) \
1660 CALL_VTBL_FUNC(this, 32, fpos_mbstatet*, (basic_streambuf_char*, fpos_mbstatet*, streamoff, int, int), (this, ret, off, way, mode))
1662 fpos_mbstatet
* __thiscall
basic_streambuf_char_seekoff(basic_streambuf_char
*this,
1663 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
1665 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
1668 memset(&ret
->state
, 0, sizeof(ret
->state
));
1672 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
1673 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
1674 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JFF@Z */
1675 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JFF@Z */
1676 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
1677 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
1678 #if STREAMOFF_BITS == 64
1679 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff
, 24)
1681 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff
, 20)
1683 fpos_mbstatet
* __thiscall
basic_streambuf_char_pubseekoff(basic_streambuf_char
*this,
1684 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
1686 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
1687 return call_basic_streambuf_char_seekoff(this, ret
, off
, way
, mode
);
1690 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
1691 /* ?pubseekoff@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
1692 #if STREAMOFF_BITS == 64
1693 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff_old
, 24)
1695 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekoff_old
, 20)
1697 fpos_mbstatet
* __thiscall
basic_streambuf_char_pubseekoff_old(basic_streambuf_char
*this,
1698 fpos_mbstatet
*ret
, streamoff off
, unsigned int way
, unsigned int mode
)
1700 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
1701 return basic_streambuf_char_pubseekoff(this, ret
, off
, way
, mode
);
1704 /* ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
1705 /* ?seekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
1706 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_seekpos
, 36)
1707 #if _MSVCP_VER >= 100
1708 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) \
1709 CALL_VTBL_FUNC(this, 44, fpos_mbstatet*, (basic_streambuf_char*, fpos_mbstatet*, fpos_mbstatet, int), (this, ret, pos, mode))
1710 #elif _MSVCP_VER >= 80
1711 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) \
1712 CALL_VTBL_FUNC(this, 40, fpos_mbstatet*, (basic_streambuf_char*, fpos_mbstatet*, fpos_mbstatet, int), (this, ret, pos, mode))
1714 #define call_basic_streambuf_char_seekpos(this, ret, pos, mode) \
1715 CALL_VTBL_FUNC(this, 36, fpos_mbstatet*, (basic_streambuf_char*, fpos_mbstatet*, fpos_mbstatet, int), (this, ret, pos, mode))
1717 fpos_mbstatet
* __thiscall
basic_streambuf_char_seekpos(basic_streambuf_char
*this,
1718 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
1720 TRACE("(%p %s %d)\n", this, debugstr_fpos_mbstatet(&pos
), mode
);
1723 memset(&ret
->state
, 0, sizeof(ret
->state
));
1727 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
1728 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
1729 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekpos
, 36)
1730 fpos_mbstatet
* __thiscall
basic_streambuf_char_pubseekpos(basic_streambuf_char
*this,
1731 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
1733 TRACE("(%p %s %d)\n", this, debugstr_fpos_mbstatet(&pos
), mode
);
1734 return call_basic_streambuf_char_seekpos(this, ret
, pos
, mode
);
1737 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
1738 /* ?pubseekpos@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
1739 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubseekpos_old
, 36)
1740 fpos_mbstatet
* __thiscall
basic_streambuf_char_pubseekpos_old(basic_streambuf_char
*this,
1741 fpos_mbstatet
*ret
, fpos_mbstatet pos
, unsigned int mode
)
1743 TRACE("(%p %s %d)\n", this, debugstr_fpos_mbstatet(&pos
), mode
);
1744 return basic_streambuf_char_pubseekpos(this, ret
, pos
, mode
);
1747 /* ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEPAV12@PADH@Z */
1748 /* ?setbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAPEAV12@PEAD_J@Z */
1749 #if STREAMSIZE_BITS == 64
1750 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setbuf
, 16)
1752 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_setbuf
, 12)
1754 #if _MSVCP_VER >= 100
1755 #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))
1756 #elif _MSVCP_VER >= 80
1757 #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))
1759 #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))
1761 basic_streambuf_char
* __thiscall
basic_streambuf_char_setbuf(basic_streambuf_char
*this, char *buf
, streamsize count
)
1763 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
1767 /* ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PADH@Z */
1768 /* ?pubsetbuf@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEAD_J@Z */
1769 #if STREAMSIZE_BITS == 64
1770 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsetbuf
, 16)
1772 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsetbuf
, 12)
1774 basic_streambuf_char
* __thiscall
basic_streambuf_char_pubsetbuf(basic_streambuf_char
*this, char *buf
, streamsize count
)
1776 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
1777 return call_basic_streambuf_char_setbuf(this, buf
, count
);
1780 /* ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1781 /* ?sync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
1782 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sync
, 4)
1783 #if _MSVCP_VER >= 100
1784 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 52, int, (basic_streambuf_char*), (this))
1785 #elif _MSVCP_VER >= 80
1786 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 48, int, (basic_streambuf_char*), (this))
1788 #define call_basic_streambuf_char_sync(this) CALL_VTBL_FUNC(this, 44, int, (basic_streambuf_char*), (this))
1790 int __thiscall
basic_streambuf_char_sync(basic_streambuf_char
*this)
1792 TRACE("(%p)\n", this);
1796 /* ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1797 /* ?pubsync@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1798 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_pubsync
, 4)
1799 int __thiscall
basic_streambuf_char_pubsync(basic_streambuf_char
*this)
1801 TRACE("(%p)\n", this);
1802 return call_basic_streambuf_char_sync(this);
1805 /* ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPADH@Z */
1806 /* ?sgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z */
1807 #if STREAMSIZE_BITS == 64
1808 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetn
, 16)
1810 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetn
, 12)
1812 streamsize __thiscall
basic_streambuf_char_sgetn(basic_streambuf_char
*this, char *ptr
, streamsize count
)
1814 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1815 return call_basic_streambuf_char__Xsgetn_s(this, ptr
, -1, count
);
1818 /* ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
1819 /* ?showmanyc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JXZ */
1820 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_showmanyc
, 4)
1821 #if _MSVCP_VER >= 100
1822 #define call_basic_streambuf_char_showmanyc(this) CALL_VTBL_FUNC(this, 20, streamsize, (basic_streambuf_char*), (this))
1824 #define call_basic_streambuf_char_showmanyc(this) CALL_VTBL_FUNC(this, 12, streamsize, (basic_streambuf_char*), (this))
1826 streamsize __thiscall
basic_streambuf_char_showmanyc(basic_streambuf_char
*this)
1828 TRACE("(%p)\n", this);
1832 /* ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1833 /* ?in_avail@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JXZ */
1834 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_in_avail
, 4)
1835 streamsize __thiscall
basic_streambuf_char_in_avail(basic_streambuf_char
*this)
1839 TRACE("(%p)\n", this);
1841 ret
= basic_streambuf_char__Gnavail(this);
1842 return ret
? ret
: call_basic_streambuf_char_showmanyc(this);
1845 /* ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z */
1846 /* ?sputbackc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z */
1847 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputbackc
, 8)
1848 int __thiscall
basic_streambuf_char_sputbackc(basic_streambuf_char
*this, char ch
)
1850 TRACE("(%p %d)\n", this, ch
);
1851 if(*this->prpos
&& *this->prpos
>*this->prbuf
&& (*this->prpos
)[-1]==ch
) {
1854 return (unsigned char)ch
;
1857 return call_basic_streambuf_char_pbackfail(this, (unsigned char)ch
);
1860 /* ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHD@Z */
1861 /* ?sputc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHD@Z */
1862 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputc
, 8)
1863 int __thiscall
basic_streambuf_char_sputc(basic_streambuf_char
*this, char ch
)
1865 TRACE("(%p %d)\n", this, ch
);
1866 return basic_streambuf_char__Pnavail(this) ?
1867 (unsigned char)(*basic_streambuf_char__Pninc(this) = ch
) :
1868 call_basic_streambuf_char_overflow(this, (unsigned char)ch
);
1871 /* ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1872 /* ?sungetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1873 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sungetc
, 4)
1874 int __thiscall
basic_streambuf_char_sungetc(basic_streambuf_char
*this)
1876 TRACE("(%p)\n", this);
1877 if(*this->prpos
&& *this->prpos
>*this->prbuf
) {
1880 return (unsigned char)**this->prpos
;
1883 return call_basic_streambuf_char_pbackfail(this, EOF
);
1886 /* ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
1887 /* ?stossc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
1888 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_stossc
, 4)
1889 void __thiscall
basic_streambuf_char_stossc(basic_streambuf_char
*this)
1891 TRACE("(%p)\n", this);
1892 if(basic_streambuf_char__Gnavail(this))
1893 basic_streambuf_char__Gninc(this);
1895 call_basic_streambuf_char_uflow(this);
1898 /* ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1899 /* ?sbumpc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1900 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sbumpc
, 4)
1901 int __thiscall
basic_streambuf_char_sbumpc(basic_streambuf_char
*this)
1903 TRACE("(%p)\n", this);
1904 return basic_streambuf_char__Gnavail(this) ?
1905 (int)(unsigned char)*basic_streambuf_char__Gninc(this) : call_basic_streambuf_char_uflow(this);
1908 /* ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1909 /* ?sgetc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1910 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sgetc
, 4)
1911 int __thiscall
basic_streambuf_char_sgetc(basic_streambuf_char
*this)
1913 TRACE("(%p)\n", this);
1914 return basic_streambuf_char__Gnavail(this) ?
1915 (int)(unsigned char)*basic_streambuf_char_gptr(this) : call_basic_streambuf_char_underflow(this);
1918 /* ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHXZ */
1919 /* ?snextc@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAAHXZ */
1920 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_snextc
, 4)
1921 int __thiscall
basic_streambuf_char_snextc(basic_streambuf_char
*this)
1923 TRACE("(%p)\n", this);
1925 if(basic_streambuf_char__Gnavail(this) > 1)
1926 return (unsigned char)*basic_streambuf_char__Gnpreinc(this);
1927 return basic_streambuf_char_sbumpc(this)==EOF
?
1928 EOF
: basic_streambuf_char_sgetc(this);
1931 /* ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPADH@Z */
1932 /* ?xsgetn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEAD_J@Z */
1933 #if STREAMSIZE_BITS == 64
1934 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsgetn
, 16)
1936 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsgetn
, 12)
1938 #if _MSVCP_VER >= 100
1939 #define call_basic_streambuf_char_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_char*, char*, streamsize), (this, ptr, count))
1941 #define call_basic_streambuf_char_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 24, streamsize, (basic_streambuf_char*, char*, streamsize), (this, ptr, count))
1943 streamsize __thiscall
basic_streambuf_char_xsgetn(basic_streambuf_char
*this, char *ptr
, streamsize count
)
1945 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1946 return call_basic_streambuf_char__Xsgetn_s(this, ptr
, -1, count
);
1949 /* ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MAEHPBDH@Z */
1950 /* ?xsputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@MEAA_JPEBD_J@Z */
1951 #if STREAMSIZE_BITS == 64
1952 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsputn
, 16)
1954 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_xsputn
, 12)
1956 #if _MSVCP_VER >= 100
1957 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 36, streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1958 #elif _MSVCP_VER >= 80
1959 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1961 #define call_basic_streambuf_char_xsputn(this, ptr, count) CALL_VTBL_FUNC(this, 28, streamsize, (basic_streambuf_char*, const char*, streamsize), (this, ptr, count))
1963 streamsize __thiscall
basic_streambuf_char_xsputn(basic_streambuf_char
*this, const char *ptr
, streamsize count
)
1965 streamsize copied
, chunk
;
1967 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1969 for(copied
=0; copied
<count
;) {
1970 chunk
= basic_streambuf_char__Pnavail(this);
1971 if(chunk
> count
-copied
)
1972 chunk
= count
-copied
;
1975 memcpy(*this->pwpos
, ptr
+copied
, chunk
);
1976 *this->pwpos
+= chunk
;
1977 *this->pwsize
-= chunk
;
1979 }else if(call_basic_streambuf_char_overflow(this, (unsigned char)ptr
[copied
]) != EOF
) {
1989 /* ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QAEHPBDH@Z */
1990 /* ?sputn@?$basic_streambuf@DU?$char_traits@D@std@@@std@@QEAA_JPEBD_J@Z */
1991 #if STREAMSIZE_BITS == 64
1992 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputn
, 16)
1994 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_sputn
, 12)
1996 streamsize __thiscall
basic_streambuf_char_sputn(basic_streambuf_char
*this, const char *ptr
, streamsize count
)
1998 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
1999 return call_basic_streambuf_char_xsputn(this, ptr
, count
);
2002 /* ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z */
2003 /* ?swap@?$basic_streambuf@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z */
2004 DEFINE_THISCALL_WRAPPER(basic_streambuf_char_swap
, 8)
2005 void __thiscall
basic_streambuf_char_swap(basic_streambuf_char
*this, basic_streambuf_char
*r
)
2007 char *wfirst
, *wnext
, *wlast
, *rfirst
, *rnext
, *rlast
;
2014 TRACE("(%p %p)\n", this, r
);
2019 wfirst
= *this->pwbuf
;
2020 wnext
= *this->pwpos
;
2021 wlast
= *this->pwpos
+ *this->pwsize
;
2022 rfirst
= *this->prbuf
;
2023 rnext
= *this->prpos
;
2024 rlast
= *this->prpos
+ *this->prsize
;
2027 basic_streambuf_char_setp_next(this, *r
->pwbuf
, *r
->pwpos
, *r
->pwpos
+ *r
->pwsize
);
2028 basic_streambuf_char_setg(this, *r
->prbuf
, *r
->prpos
, *r
->prpos
+ *r
->prsize
);
2031 basic_streambuf_char_setp_next(r
, wfirst
, wnext
, wlast
);
2032 basic_streambuf_char_setg(r
, rfirst
, rnext
, rlast
);
2036 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z */
2037 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z */
2038 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z */
2039 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z */
2040 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setp_next
, 16)
2041 void __thiscall
basic_streambuf_wchar_setp_next(basic_streambuf_wchar
*this, wchar_t *first
, wchar_t *next
, wchar_t *last
)
2043 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
2047 this->wsize
= last
-next
;
2050 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W0@Z */
2051 /* ?setp@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W0@Z */
2052 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG0@Z */
2053 /* ?setp@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG0@Z */
2054 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setp
, 12)
2055 void __thiscall
basic_streambuf_wchar_setp(basic_streambuf_wchar
*this, wchar_t *first
, wchar_t *last
)
2057 basic_streambuf_wchar_setp_next(this, first
, first
, last
);
2060 /* ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPA_W00@Z */
2061 /* ?setg@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEA_W00@Z */
2062 /* ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAG00@Z */
2063 /* ?setg@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAG00@Z */
2064 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setg
, 16)
2065 void __thiscall
basic_streambuf_wchar_setg(basic_streambuf_wchar
*this, wchar_t *first
, wchar_t *next
, wchar_t *last
)
2067 TRACE("(%p %p %p %p)\n", this, first
, next
, last
);
2071 this->rsize
= last
-next
;
2074 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXXZ */
2075 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXXZ */
2076 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXXZ */
2077 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXXZ */
2078 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Init_empty
, 4)
2079 void __thiscall
basic_streambuf_wchar__Init_empty(basic_streambuf_wchar
*this)
2081 TRACE("(%p)\n", this);
2083 this->prbuf
= &this->rbuf
;
2084 this->pwbuf
= &this->wbuf
;
2085 this->prpos
= &this->rpos
;
2086 this->pwpos
= &this->wpos
;
2087 this->prsize
= &this->rsize
;
2088 this->pwsize
= &this->wsize
;
2090 basic_streambuf_wchar_setp(this, NULL
, NULL
);
2091 basic_streambuf_wchar_setg(this, NULL
, NULL
, NULL
);
2094 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@W4_Uninitialized@1@@Z */
2095 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
2096 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_ctor_uninitialized
, 8)
2097 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_ctor_uninitialized(basic_streambuf_wchar
*this, int uninitialized
)
2099 TRACE("(%p %d)\n", this, uninitialized
);
2100 this->vtable
= &MSVCP_basic_streambuf_wchar_vtable
;
2101 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2102 mutex_ctor(&this->lock
);
2107 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@W4_Uninitialized@1@@Z */
2108 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@W4_Uninitialized@1@@Z */
2109 DEFINE_THISCALL_WRAPPER(basic_streambuf_short_ctor_uninitialized
, 8)
2110 basic_streambuf_wchar
* __thiscall
basic_streambuf_short_ctor_uninitialized(basic_streambuf_wchar
*this, int uninitialized
)
2112 TRACE("(%p %d)\n", this, uninitialized
);
2113 basic_streambuf_wchar_ctor_uninitialized(this, uninitialized
);
2114 this->vtable
= &MSVCP_basic_streambuf_short_vtable
;
2118 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAE@XZ */
2119 /* ??0?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAA@XZ */
2120 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_ctor
, 4)
2121 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_ctor(basic_streambuf_wchar
*this)
2123 TRACE("(%p)\n", this);
2125 this->vtable
= &MSVCP_basic_streambuf_wchar_vtable
;
2126 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2127 mutex_ctor(&this->lock
);
2129 #if _MSVCP_VER >= 70
2130 this->loc
= MSVCRT_operator_new(sizeof(locale
));
2132 locale_ctor(IOS_LOCALE(this));
2133 basic_streambuf_wchar__Init_empty(this);
2138 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAE@XZ */
2139 /* ??0?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAA@XZ */
2140 DEFINE_THISCALL_WRAPPER(basic_streambuf_short_ctor
, 4)
2141 basic_streambuf_wchar
* __thiscall
basic_streambuf_short_ctor(basic_streambuf_wchar
*this)
2143 TRACE("(%p)\n", this);
2144 basic_streambuf_wchar_ctor(this);
2145 this->vtable
= &MSVCP_basic_streambuf_short_vtable
;
2149 /* ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
2150 /* ??1?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
2151 /* ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UAE@XZ */
2152 /* ??1?$basic_streambuf@GU?$char_traits@G@std@@@std@@UEAA@XZ */
2153 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_dtor
, 4)
2154 void __thiscall
basic_streambuf_wchar_dtor(basic_streambuf_wchar
*this)
2156 TRACE("(%p)\n", this);
2158 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2159 mutex_dtor(&this->lock
);
2161 locale_dtor(IOS_LOCALE(this));
2162 #if _MSVCP_VER >= 70
2163 MSVCRT_operator_delete(this->loc
);
2167 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_vector_dtor
, 8)
2168 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_vector_dtor(basic_streambuf_wchar
*this, unsigned int flags
)
2170 TRACE("(%p %x)\n", this, flags
);
2172 /* we have an array, with the number of elements stored before the first object */
2173 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
2175 for(i
=*ptr
-1; i
>=0; i
--)
2176 basic_streambuf_wchar_dtor(this+i
);
2177 MSVCRT_operator_delete(ptr
);
2179 basic_streambuf_wchar_dtor(this);
2181 MSVCRT_operator_delete(this);
2187 /* ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
2188 /* ?_Gnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ */
2189 /* ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEHXZ */
2190 /* ?_Gnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ */
2191 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gnavail
, 4)
2192 streamsize __thiscall
basic_streambuf_wchar__Gnavail(const basic_streambuf_wchar
*this)
2194 TRACE("(%p)\n", this);
2195 return *this->prpos
? *this->prsize
: 0;
2198 /* ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
2199 /* ?_Gndec@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
2200 /* ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
2201 /* ?_Gndec@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
2202 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gndec
, 4)
2203 wchar_t* __thiscall
basic_streambuf_wchar__Gndec(basic_streambuf_wchar
*this)
2205 TRACE("(%p)\n", this);
2208 return *this->prpos
;
2211 /* ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
2212 /* ?_Gninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
2213 /* ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
2214 /* ?_Gninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
2215 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gninc
, 4)
2216 wchar_t* __thiscall
basic_streambuf_wchar__Gninc(basic_streambuf_wchar
*this)
2218 TRACE("(%p)\n", this);
2220 return (*this->prpos
)++;
2223 /* ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
2224 /* ?_Gnpreinc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
2225 /* ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
2226 /* ?_Gnpreinc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
2227 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Gnpreinc
, 4)
2228 wchar_t* __thiscall
basic_streambuf_wchar__Gnpreinc(basic_streambuf_wchar
*this)
2230 TRACE("(%p)\n", this);
2233 return *this->prpos
;
2236 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXPAPA_W0PAH001@Z */
2237 /* ?_Init@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAPEA_W0PEAH001@Z */
2238 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXPAPAG0PAH001@Z */
2239 /* ?_Init@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXPEAPEAG0PEAH001@Z */
2240 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Init
, 28)
2241 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
)
2243 TRACE("(%p %p %p %p %p %p %p)\n", this, gf
, gn
, gc
, pf
, pn
, pc
);
2253 /* ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2254 /* ?_Lock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2255 /* ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2256 /* ?_Lock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2257 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Lock
, 4)
2258 void __thiscall
basic_streambuf_wchar__Lock(basic_streambuf_wchar
*this)
2260 TRACE("(%p)\n", this);
2261 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2262 mutex_lock(&this->lock
);
2266 /* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEHXZ */
2267 /* ?_Pnavail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBA_JXZ */
2268 /* ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEHXZ */
2269 /* ?_Pnavail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBA_JXZ */
2270 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Pnavail
, 4)
2271 streamsize __thiscall
basic_streambuf_wchar__Pnavail(const basic_streambuf_wchar
*this)
2273 TRACE("(%p)\n", this);
2274 return *this->pwpos
? *this->pwsize
: 0;
2277 /* ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEPA_WXZ */
2278 /* ?_Pninc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAPEA_WXZ */
2279 /* ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEPAGXZ */
2280 /* ?_Pninc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAPEAGXZ */
2281 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Pninc
, 4)
2282 wchar_t* __thiscall
basic_streambuf_wchar__Pninc(basic_streambuf_wchar
*this)
2284 TRACE("(%p)\n", this);
2286 return (*this->pwpos
)++;
2289 /* ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
2290 /* ?underflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
2291 /* ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
2292 /* ?underflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
2293 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_underflow
, 4)
2294 #if _MSVCP_VER >= 100
2295 #define call_basic_streambuf_wchar_underflow(this) CALL_VTBL_FUNC(this, 24, unsigned short, (basic_streambuf_wchar*), (this))
2297 #define call_basic_streambuf_wchar_underflow(this) CALL_VTBL_FUNC(this, 16, unsigned short, (basic_streambuf_wchar*), (this))
2299 unsigned short __thiscall
basic_streambuf_wchar_underflow(basic_streambuf_wchar
*this)
2301 TRACE("(%p)\n", this);
2305 /* ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
2306 /* ?uflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
2307 /* ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
2308 /* ?uflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
2309 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_uflow
, 4)
2310 #if _MSVCP_VER >= 100
2311 #define call_basic_streambuf_wchar_uflow(this) CALL_VTBL_FUNC(this, 28, unsigned short, (basic_streambuf_wchar*), (this))
2313 #define call_basic_streambuf_wchar_uflow(this) CALL_VTBL_FUNC(this, 20, unsigned short, (basic_streambuf_wchar*), (this))
2315 unsigned short __thiscall
basic_streambuf_wchar_uflow(basic_streambuf_wchar
*this)
2319 TRACE("(%p)\n", this);
2321 if(call_basic_streambuf_wchar_underflow(this)==WEOF
)
2324 ret
= **this->prpos
;
2330 /* ?_Xsgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPA_WIH@Z */
2331 /* ?_Xsgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_K_J@Z */
2332 /* ?_Xsgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPAGIH@Z */
2333 /* ?_Xsgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_K_J@Z */
2334 #if STREAMSIZE_BITS == 64
2335 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Xsgetn_s
, 20)
2337 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Xsgetn_s
, 16)
2339 #if _MSVCP_VER >= 80 && _MSVCP_VER <= 90
2340 #define call_basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count) CALL_VTBL_FUNC(this, 28, \
2341 streamsize, (basic_streambuf_wchar*, wchar_t*, size_t, streamsize), (this, ptr, size, count))
2343 #define call_basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count) basic_streambuf_wchar__Xsgetn_s(this, ptr, size, count)
2345 streamsize __thiscall
basic_streambuf_wchar__Xsgetn_s(basic_streambuf_wchar
*this, wchar_t *ptr
, size_t size
, streamsize count
)
2347 streamsize copied
, chunk
;
2350 TRACE("(%p %p %Iu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
2352 for(copied
=0; copied
<count
&& size
;) {
2353 chunk
= basic_streambuf_wchar__Gnavail(this);
2354 if(chunk
> count
-copied
)
2355 chunk
= count
-copied
;
2358 memcpy_s(ptr
+copied
, size
, *this->prpos
, chunk
*sizeof(wchar_t));
2359 *this->prpos
+= chunk
;
2360 *this->prsize
-= chunk
;
2362 size
-= chunk
*sizeof(wchar_t);
2363 }else if((c
= call_basic_streambuf_wchar_uflow(this)) != WEOF
) {
2375 /* ?_Sgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPA_WIH@Z */
2376 /* ?_Sgetn_s@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_K_J@Z */
2377 /* ?_Sgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPAGIH@Z */
2378 /* ?_Sgetn_s@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_K_J@Z */
2379 #if STREAMSIZE_BITS == 64
2380 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Sgetn_s
, 20)
2382 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Sgetn_s
, 16)
2384 streamsize __thiscall
basic_streambuf_wchar__Sgetn_s(basic_streambuf_wchar
*this, wchar_t *ptr
, size_t size
, streamsize count
)
2386 TRACE("(%p %p %Iu %s)\n", this, ptr
, size
, wine_dbgstr_longlong(count
));
2387 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr
, size
, count
);
2390 /* ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2391 /* ?_Unlock@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2392 /* ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2393 /* ?_Unlock@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2394 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar__Unlock
, 4)
2395 void __thiscall
basic_streambuf_wchar__Unlock(basic_streambuf_wchar
*this)
2397 TRACE("(%p)\n", this);
2398 #if _MSVCP_VER >= 70 && _MSVCP_VER <= 100
2399 mutex_unlock(&this->lock
);
2403 /* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2404 /* ?eback@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2405 /* ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2406 /* ?eback@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2407 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_eback
, 4)
2408 wchar_t* __thiscall
basic_streambuf_wchar_eback(const basic_streambuf_wchar
*this)
2410 TRACE("(%p)\n", this);
2411 return *this->prbuf
;
2414 /* ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2415 /* ?gptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2416 /* ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2417 /* ?gptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2418 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_gptr
, 4)
2419 wchar_t* __thiscall
basic_streambuf_wchar_gptr(const basic_streambuf_wchar
*this)
2421 TRACE("(%p)\n", this);
2422 return *this->prpos
;
2425 /* ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2426 /* ?egptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2427 /* ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2428 /* ?egptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2429 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_egptr
, 4)
2430 wchar_t* __thiscall
basic_streambuf_wchar_egptr(const basic_streambuf_wchar
*this)
2432 TRACE("(%p)\n", this);
2433 return *this->prpos
+*this->prsize
;
2436 /* ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2437 /* ?epptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2438 /* ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2439 /* ?epptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2440 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_epptr
, 4)
2441 wchar_t* __thiscall
basic_streambuf_wchar_epptr(const basic_streambuf_wchar
*this)
2443 TRACE("(%p)\n", this);
2444 return *this->pwpos
+*this->pwsize
;
2447 /* ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z */
2448 /* ?gbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z */
2449 /* ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z */
2450 /* ?gbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z */
2451 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_gbump
, 8)
2452 void __thiscall
basic_streambuf_wchar_gbump(basic_streambuf_wchar
*this, int off
)
2454 TRACE("(%p %d)\n", this, off
);
2455 *this->prpos
+= off
;
2456 *this->prsize
-= off
;
2459 /* ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QBE?AVlocale@2@XZ */
2460 /* ?getloc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEBA?AVlocale@2@XZ */
2461 /* ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QBE?AVlocale@2@XZ */
2462 /* ?getloc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEBA?AVlocale@2@XZ */
2463 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_getloc
, 8)
2464 locale
* __thiscall
basic_streambuf_wchar_getloc(const basic_streambuf_wchar
*this, locale
*ret
)
2466 TRACE("(%p)\n", this);
2467 return locale_copy_ctor(ret
, IOS_LOCALE(this));
2470 /* ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z */
2471 /* ?imbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z */
2472 /* ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z */
2473 /* ?imbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z */
2474 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_imbue
, 8)
2475 #if _MSVCP_VER >= 100
2476 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 56, void, (basic_streambuf_wchar*, const locale*), (this, loc))
2477 #elif _MSVCP_VER >= 80
2478 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 52, void, (basic_streambuf_wchar*, const locale*), (this, loc))
2480 #define call_basic_streambuf_wchar_imbue(this, loc) CALL_VTBL_FUNC(this, 48, void, (basic_streambuf_wchar*, const locale*), (this, loc))
2482 void __thiscall
basic_streambuf_wchar_imbue(basic_streambuf_wchar
*this, const locale
*loc
)
2484 TRACE("(%p %p)\n", this, loc
);
2487 /* ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
2488 /* ?overflow@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
2489 /* ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
2490 /* ?overflow@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
2491 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_overflow
, 8)
2492 #if _MSVCP_VER >= 100
2493 #define call_basic_streambuf_wchar_overflow(this, ch) CALL_VTBL_FUNC(this, 12, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2495 #define call_basic_streambuf_wchar_overflow(this, ch) CALL_VTBL_FUNC(this, 4, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2497 unsigned short __thiscall
basic_streambuf_wchar_overflow(basic_streambuf_wchar
*this, unsigned short ch
)
2499 TRACE("(%p %d)\n", this, ch
);
2503 /* ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
2504 /* ?pbackfail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
2505 /* ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
2506 /* ?pbackfail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
2507 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbackfail
, 8)
2508 #if _MSVCP_VER >= 100
2509 #define call_basic_streambuf_wchar_pbackfail(this, ch) CALL_VTBL_FUNC(this, 16, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2511 #define call_basic_streambuf_wchar_pbackfail(this, ch) CALL_VTBL_FUNC(this, 8, unsigned short, (basic_streambuf_wchar*, unsigned short), (this, ch))
2513 unsigned short __thiscall
basic_streambuf_wchar_pbackfail(basic_streambuf_wchar
*this, unsigned short ch
)
2515 TRACE("(%p %d)\n", this, ch
);
2519 /* ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2520 /* ?pbase@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2521 /* ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2522 /* ?pbase@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2523 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbase
, 4)
2524 wchar_t* __thiscall
basic_streambuf_wchar_pbase(const basic_streambuf_wchar
*this)
2526 TRACE("(%p)\n", this);
2527 return *this->pwbuf
;
2530 /* ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXH@Z */
2531 /* ?pbump@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEAAXH@Z */
2532 /* ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXH@Z */
2533 /* ?pbump@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXH@Z */
2534 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pbump
, 8)
2535 void __thiscall
basic_streambuf_wchar_pbump(basic_streambuf_wchar
*this, int off
)
2537 TRACE("(%p %d)\n", this, off
);
2538 *this->pwpos
+= off
;
2539 *this->pwsize
-= off
;
2542 /* ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IBEPA_WXZ */
2543 /* ?pptr@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IEBAPEA_WXZ */
2544 /* ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IBEPAGXZ */
2545 /* ?pptr@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEBAPEAGXZ */
2546 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pptr
, 4)
2547 wchar_t* __thiscall
basic_streambuf_wchar_pptr(const basic_streambuf_wchar
*this)
2549 TRACE("(%p)\n", this);
2550 return *this->pwpos
;
2553 /* ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
2554 /* ?pubimbue@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
2555 /* ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
2556 /* ?pubimbue@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
2557 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubimbue
, 12)
2558 locale
* __thiscall
basic_streambuf_wchar_pubimbue(basic_streambuf_wchar
*this, locale
*ret
, const locale
*loc
)
2560 TRACE("(%p %p)\n", this, loc
);
2561 memcpy(ret
, IOS_LOCALE(this), sizeof(locale
));
2562 call_basic_streambuf_wchar_imbue(this, loc
);
2563 locale_copy_ctor(IOS_LOCALE(this), loc
);
2567 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
2568 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
2569 /* ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2570 /* ?seekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2571 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
2572 /* ?seekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
2573 #if STREAMOFF_BITS == 64
2574 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekoff
, 24)
2576 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekoff
, 20)
2578 #if _MSVCP_VER >= 100
2579 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) \
2580 CALL_VTBL_FUNC(this, 40, fpos_mbstatet*, (basic_streambuf_wchar*, fpos_mbstatet*, streamoff, int, int), (this, ret, off, way, mode))
2581 #elif _MSVCP_VER >= 80
2582 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) \
2583 CALL_VTBL_FUNC(this, 36, fpos_mbstatet*, (basic_streambuf_wchar*, fpos_mbstatet*, streamoff, int, int), (this, ret, off, way, mode))
2585 #define call_basic_streambuf_wchar_seekoff(this, ret, off, way, mode) \
2586 CALL_VTBL_FUNC(this, 32, fpos_mbstatet*, (basic_streambuf_wchar*, fpos_mbstatet*, streamoff, int, int), (this, ret, off, way, mode))
2588 fpos_mbstatet
* __thiscall
basic_streambuf_wchar_seekoff(basic_streambuf_wchar
*this,
2589 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
2591 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
2594 memset(&ret
->state
, 0, sizeof(ret
->state
));
2598 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
2599 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
2600 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JHH@Z */
2601 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JHH@Z */
2602 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JFF@Z */
2603 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JFF@Z */
2604 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
2605 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JW4seekdir@ioos_base@2@H@Z */
2606 #if STREAMOFF_BITS == 64
2607 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff
, 24)
2609 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff
, 20)
2611 fpos_mbstatet
* __thiscall
basic_streambuf_wchar_pubseekoff(basic_streambuf_wchar
*this,
2612 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
2614 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
2615 return call_basic_streambuf_wchar_seekoff(this, ret
, off
, way
, mode
);
2618 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
2619 /* ?pubseekoff@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
2620 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@JII@Z */
2621 /* ?pubseekoff@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@_JII@Z */
2622 #if STREAMOFF_BITS == 64
2623 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff_old
, 24)
2625 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekoff_old
, 20)
2627 fpos_mbstatet
* __thiscall
basic_streambuf_wchar_pubseekoff_old(basic_streambuf_wchar
*this,
2628 fpos_mbstatet
*ret
, streamoff off
, unsigned int way
, unsigned int mode
)
2630 TRACE("(%p %s %d %d)\n", this, wine_dbgstr_longlong(off
), way
, mode
);
2631 return basic_streambuf_wchar_pubseekoff(this, ret
, off
, way
, mode
);
2634 /* ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2635 /* ?seekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2636 /* ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
2637 /* ?seekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
2638 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_seekpos
, 36)
2639 #if _MSVCP_VER >= 100
2640 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) \
2641 CALL_VTBL_FUNC(this, 44, fpos_mbstatet*, (basic_streambuf_wchar*, fpos_mbstatet*, fpos_mbstatet, int), (this, ret, pos, mode))
2642 #elif _MSVCP_VER >= 80
2643 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) \
2644 CALL_VTBL_FUNC(this, 40, fpos_mbstatet*, (basic_streambuf_wchar*, fpos_mbstatet*, fpos_mbstatet, int), (this, ret, pos, mode))
2646 #define call_basic_streambuf_wchar_seekpos(this, ret, pos, mode) \
2647 CALL_VTBL_FUNC(this, 36, fpos_mbstatet*, (basic_streambuf_wchar*, fpos_mbstatet*, fpos_mbstatet, int), (this, ret, pos, mode))
2649 fpos_mbstatet
* __thiscall
basic_streambuf_wchar_seekpos(basic_streambuf_wchar
*this,
2650 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
2652 TRACE("(%p %s %d)\n", this, debugstr_fpos_mbstatet(&pos
), mode
);
2655 memset(&ret
->state
, 0, sizeof(ret
->state
));
2659 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
2660 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
2661 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@H@Z */
2662 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@H@Z */
2663 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekpos
, 36)
2664 fpos_mbstatet
* __thiscall
basic_streambuf_wchar_pubseekpos(basic_streambuf_wchar
*this,
2665 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
2667 TRACE("(%p %s %d)\n", this, debugstr_fpos_mbstatet(&pos
), mode
);
2668 return call_basic_streambuf_wchar_seekpos(this, ret
, pos
, mode
);
2671 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
2672 /* ?pubseekpos@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
2673 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@V32@I@Z */
2674 /* ?pubseekpos@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@V32@I@Z */
2675 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubseekpos_old
, 36)
2676 fpos_mbstatet
* __thiscall
basic_streambuf_wchar_pubseekpos_old(basic_streambuf_wchar
*this,
2677 fpos_mbstatet
*ret
, fpos_mbstatet pos
, unsigned int mode
)
2679 TRACE("(%p %s %d)\n", this, debugstr_fpos_mbstatet(&pos
), mode
);
2680 return basic_streambuf_wchar_pubseekpos(this, ret
, pos
, mode
);
2683 /* ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEPAV12@PA_WH@Z */
2684 /* ?setbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV12@PEA_W_J@Z */
2685 /* ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEPAV12@PAGH@Z */
2686 /* ?setbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAPEAV12@PEAG_J@Z */
2687 #if STREAMSIZE_BITS == 64
2688 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setbuf
, 16)
2690 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_setbuf
, 12)
2692 #if _MSVCP_VER >= 100
2693 #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))
2694 #elif _MSVCP_VER >= 80
2695 #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))
2697 #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))
2699 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_setbuf(basic_streambuf_wchar
*this, wchar_t *buf
, streamsize count
)
2701 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
2705 /* ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PA_WH@Z */
2706 /* ?pubsetbuf@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEA_W_J@Z */
2707 /* ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PAGH@Z */
2708 /* ?pubsetbuf@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEAG_J@Z */
2709 #if STREAMSIZE_BITS == 64
2710 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsetbuf
, 16)
2712 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsetbuf
, 12)
2714 basic_streambuf_wchar
* __thiscall
basic_streambuf_wchar_pubsetbuf(basic_streambuf_wchar
*this, wchar_t *buf
, streamsize count
)
2716 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
2717 return call_basic_streambuf_wchar_setbuf(this, buf
, count
);
2720 /* ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
2721 /* ?sync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ */
2722 /* ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
2723 /* ?sync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAAHXZ */
2724 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sync
, 4)
2725 #if _MSVCP_VER >= 100
2726 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 52, int, (basic_streambuf_wchar*), (this))
2727 #elif _MSVCP_VER >= 80
2728 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 48, int, (basic_streambuf_wchar*), (this))
2730 #define call_basic_streambuf_wchar_sync(this) CALL_VTBL_FUNC(this, 44, int, (basic_streambuf_wchar*), (this))
2732 int __thiscall
basic_streambuf_wchar_sync(basic_streambuf_wchar
*this)
2734 TRACE("(%p)\n", this);
2738 /* ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
2739 /* ?pubsync@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAHXZ */
2740 /* ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ */
2741 /* ?pubsync@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHXZ */
2742 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_pubsync
, 4)
2743 int __thiscall
basic_streambuf_wchar_pubsync(basic_streambuf_wchar
*this)
2745 TRACE("(%p)\n", this);
2746 return call_basic_streambuf_wchar_sync(this);
2749 /* ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPA_WH@Z */
2750 /* ?xsgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEA_W_J@Z */
2751 /* ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPAGH@Z */
2752 /* ?xsgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEAG_J@Z */
2753 #if STREAMSIZE_BITS == 64
2754 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsgetn
, 16)
2756 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsgetn
, 12)
2758 #if _MSVCP_VER >= 100
2759 #define call_basic_streambuf_wchar_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 32, streamsize, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, ptr, count))
2761 #define call_basic_streambuf_wchar_xsgetn(this, ptr, count) CALL_VTBL_FUNC(this, 24, streamsize, (basic_streambuf_wchar*, wchar_t*, streamsize), (this, ptr, count))
2763 streamsize __thiscall
basic_streambuf_wchar_xsgetn(basic_streambuf_wchar
*this, wchar_t *ptr
, streamsize count
)
2765 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2766 return call_basic_streambuf_wchar__Xsgetn_s(this, ptr
, -1, count
);
2769 /* ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPA_WH@Z */
2770 /* ?sgetn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z */
2771 /* ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPAGH@Z */
2772 /* ?sgetn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z */
2773 #if STREAMSIZE_BITS == 64
2774 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetn
, 16)
2776 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetn
, 12)
2778 streamsize __thiscall
basic_streambuf_wchar_sgetn(basic_streambuf_wchar
*this, wchar_t *ptr
, streamsize count
)
2780 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2781 return call_basic_streambuf_wchar_xsgetn(this, ptr
, count
);
2784 /* ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
2785 /* ?showmanyc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JXZ */
2786 /* ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
2787 /* ?showmanyc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JXZ */
2788 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_showmanyc
, 4)
2789 #if _MSVCP_VER >= 100
2790 #define call_basic_streambuf_wchar_showmanyc(this) CALL_VTBL_FUNC(this, 20, streamsize, (basic_streambuf_wchar*), (this))
2792 #define call_basic_streambuf_wchar_showmanyc(this) CALL_VTBL_FUNC(this, 12, streamsize, (basic_streambuf_wchar*), (this))
2794 streamsize __thiscall
basic_streambuf_wchar_showmanyc(basic_streambuf_wchar
*this)
2796 TRACE("(%p)\n", this);
2800 /* ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
2801 /* ?in_avail@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JXZ */
2802 /* ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHXZ */
2803 /* ?in_avail@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JXZ */
2804 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_in_avail
, 4)
2805 streamsize __thiscall
basic_streambuf_wchar_in_avail(basic_streambuf_wchar
*this)
2809 TRACE("(%p)\n", this);
2811 ret
= basic_streambuf_wchar__Gnavail(this);
2812 return ret
? ret
: call_basic_streambuf_wchar_showmanyc(this);
2815 /* ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z */
2816 /* ?sputbackc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z */
2817 /* ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z */
2818 /* ?sputbackc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGG@Z */
2819 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputbackc
, 8)
2820 unsigned short __thiscall
basic_streambuf_wchar_sputbackc(basic_streambuf_wchar
*this, wchar_t ch
)
2822 TRACE("(%p %d)\n", this, ch
);
2823 if(*this->prpos
&& *this->prpos
>*this->prbuf
&& (*this->prpos
)[-1]==ch
) {
2829 return call_basic_streambuf_wchar_pbackfail(this, ch
);
2832 /* ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEG_W@Z */
2833 /* ?sputc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAG_W@Z */
2834 /* ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGG@Z */
2835 /* ?sputc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAHG@Z */
2836 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputc
, 8)
2837 unsigned short __thiscall
basic_streambuf_wchar_sputc(basic_streambuf_wchar
*this, wchar_t ch
)
2839 TRACE("(%p %d)\n", this, ch
);
2840 return basic_streambuf_wchar__Pnavail(this) ?
2841 (*basic_streambuf_wchar__Pninc(this) = ch
) :
2842 call_basic_streambuf_wchar_overflow(this, ch
);
2845 /* ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2846 /* ?sungetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2847 /* ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2848 /* ?sungetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2849 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sungetc
, 4)
2850 unsigned short __thiscall
basic_streambuf_wchar_sungetc(basic_streambuf_wchar
*this)
2852 TRACE("(%p)\n", this);
2853 if(*this->prpos
&& *this->prpos
>*this->prbuf
) {
2856 return **this->prpos
;
2859 return call_basic_streambuf_wchar_pbackfail(this, WEOF
);
2862 /* ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
2863 /* ?stossc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
2864 /* ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
2865 /* ?stossc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
2866 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_stossc
, 4)
2867 void __thiscall
basic_streambuf_wchar_stossc(basic_streambuf_wchar
*this)
2869 TRACE("(%p)\n", this);
2870 if(basic_streambuf_wchar__Gnavail(this))
2871 basic_streambuf_wchar__Gninc(this);
2873 call_basic_streambuf_wchar_uflow(this);
2876 /* ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2877 /* ?sbumpc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2878 /* ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2879 /* ?sbumpc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2880 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sbumpc
, 4)
2881 unsigned short __thiscall
basic_streambuf_wchar_sbumpc(basic_streambuf_wchar
*this)
2883 TRACE("(%p)\n", this);
2884 return basic_streambuf_wchar__Gnavail(this) ?
2885 *basic_streambuf_wchar__Gninc(this) : call_basic_streambuf_wchar_uflow(this);
2888 /* ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2889 /* ?sgetc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2890 /* ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2891 /* ?sgetc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2892 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sgetc
, 4)
2893 unsigned short __thiscall
basic_streambuf_wchar_sgetc(basic_streambuf_wchar
*this)
2895 TRACE("(%p)\n", this);
2896 return basic_streambuf_wchar__Gnavail(this) ?
2897 *basic_streambuf_wchar_gptr(this) : call_basic_streambuf_wchar_underflow(this);
2900 /* ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
2901 /* ?snextc@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
2902 /* ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEGXZ */
2903 /* ?snextc@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAAGXZ */
2904 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_snextc
, 4)
2905 unsigned short __thiscall
basic_streambuf_wchar_snextc(basic_streambuf_wchar
*this)
2907 TRACE("(%p)\n", this);
2909 if(basic_streambuf_wchar__Gnavail(this) > 1)
2910 return *basic_streambuf_wchar__Gnpreinc(this);
2911 return basic_streambuf_wchar_sbumpc(this)==WEOF
?
2912 WEOF
: basic_streambuf_wchar_sgetc(this);
2915 /* ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MAEHPB_WH@Z */
2916 /* ?xsputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@MEAA_JPEB_W_J@Z */
2917 /* ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MAEHPBGH@Z */
2918 /* ?xsputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@MEAA_JPEBG_J@Z */
2919 #if STREAMSIZE_BITS == 64
2920 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsputn
, 16)
2922 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_xsputn
, 12)
2924 #if _MSVCP_VER >= 100
2925 #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))
2926 #elif _MSVCP_VER >= 80
2927 #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))
2929 #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))
2931 streamsize __thiscall
basic_streambuf_wchar_xsputn(basic_streambuf_wchar
*this, const wchar_t *ptr
, streamsize count
)
2933 streamsize copied
, chunk
;
2935 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2937 for(copied
=0; copied
<count
;) {
2938 chunk
= basic_streambuf_wchar__Pnavail(this);
2939 if(chunk
> count
-copied
)
2940 chunk
= count
-copied
;
2943 memcpy(*this->pwpos
, ptr
+copied
, chunk
*sizeof(wchar_t));
2944 *this->pwpos
+= chunk
;
2945 *this->pwsize
-= chunk
;
2947 }else if(call_basic_streambuf_wchar_overflow(this, ptr
[copied
]) != WEOF
) {
2957 /* ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QAEHPB_WH@Z */
2958 /* ?sputn@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@QEAA_JPEB_W_J@Z */
2959 /* ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QAEHPBGH@Z */
2960 /* ?sputn@?$basic_streambuf@GU?$char_traits@G@std@@@std@@QEAA_JPEBG_J@Z */
2961 #if STREAMSIZE_BITS == 64
2962 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputn
, 16)
2964 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_sputn
, 12)
2966 streamsize __thiscall
basic_streambuf_wchar_sputn(basic_streambuf_wchar
*this, const wchar_t *ptr
, streamsize count
)
2968 TRACE("(%p %p %s)\n", this, ptr
, wine_dbgstr_longlong(count
));
2969 return call_basic_streambuf_wchar_xsputn(this, ptr
, count
);
2972 /* ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z */
2973 /* ?swap@?$basic_streambuf@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z */
2974 /* ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z */
2975 /* ?swap@?$basic_streambuf@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z */
2976 DEFINE_THISCALL_WRAPPER(basic_streambuf_wchar_swap
, 8)
2977 void __thiscall
basic_streambuf_wchar_swap(basic_streambuf_wchar
*this, basic_streambuf_wchar
*r
)
2979 wchar_t *wfirst
, *wnext
, *wlast
, *rfirst
, *rnext
, *rlast
;
2986 TRACE("(%p %p)\n", this, r
);
2991 wfirst
= *this->pwbuf
;
2992 wnext
= *this->pwpos
;
2993 wlast
= *this->pwpos
+ *this->pwsize
;
2994 rfirst
= *this->prbuf
;
2995 rnext
= *this->prpos
;
2996 rlast
= *this->prpos
+ *this->prsize
;
2999 basic_streambuf_wchar_setp_next(this, *r
->pwbuf
, *r
->pwpos
, *r
->pwpos
+ *r
->pwsize
);
3000 basic_streambuf_wchar_setg(this, *r
->prbuf
, *r
->prpos
, *r
->prpos
+ *r
->prsize
);
3003 basic_streambuf_wchar_setp_next(r
, wfirst
, wnext
, wlast
);
3004 basic_streambuf_wchar_setg(r
, rfirst
, rnext
, rlast
);
3008 /* ?_Stinit@?1??_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
3009 /* ?_Stinit@?1??_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
3010 #if _MSVCP_VER >= 140
3011 _Mbstatet basic_filebuf_char__Init__Stinit
= {0};
3013 _Mbstatet basic_filebuf_char__Init__Stinit
= 0;
3016 /* ?_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
3017 /* ?_Init@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
3018 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Init
, 12)
3019 void __thiscall
basic_filebuf_char__Init(basic_filebuf_char
*this, FILE *file
, basic_filebuf__Initfl which
)
3021 TRACE("(%p %p %d)\n", this, file
, which
);
3024 this->wrotesome
= FALSE
;
3025 this->state
= basic_filebuf_char__Init__Stinit
;
3026 this->close
= (which
== INITFL_open
);
3029 basic_streambuf_char__Init_empty(&this->base
);
3031 basic_streambuf_char__Init(&this->base
, &file
->_base
, &file
->_ptr
,
3032 &file
->_cnt
, &file
->_base
, &file
->_ptr
, &file
->_cnt
);
3035 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXPAV?$codecvt@DDH@2@@Z */
3036 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$codecvt@DDH@2@@Z */
3037 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Initcvt_cvt
, 8)
3038 void __thiscall
basic_filebuf_char__Initcvt_cvt(basic_filebuf_char
*this, codecvt_char
*cvt
)
3040 TRACE("(%p %p)\n", this, cvt
);
3042 if(codecvt_base_always_noconv(&cvt
->base
)) {
3045 basic_streambuf_char__Init_empty(&this->base
);
3050 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAEXXZ */
3051 /* ?_Initcvt@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAAXXZ */
3052 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Initcvt
, 4)
3053 void __thiscall
basic_filebuf_char__Initcvt(basic_filebuf_char
*this)
3055 codecvt_char
*cvt
= codecvt_char_use_facet(IOS_LOCALE(&this->base
));
3056 basic_filebuf_char__Initcvt_cvt( this, cvt
);
3059 /* ?_Endwrite@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IAE_NXZ */
3060 /* ?_Endwrite@?$basic_filebuf@DU?$char_traits@D@std@@@std@@IEAA_NXZ */
3061 DEFINE_THISCALL_WRAPPER(basic_filebuf_char__Endwrite
, 4)
3062 bool __thiscall
basic_filebuf_char__Endwrite(basic_filebuf_char
*this)
3064 TRACE("(%p)\n", this);
3066 if(!this->wrotesome
|| !this->cvt
)
3070 if(call_basic_streambuf_char_overflow(&this->base
, EOF
) == EOF
)
3074 /* TODO: check if we need a dynamic buffer here */
3079 ret
= codecvt_char_unshift(this->cvt
, &this->state
, buf
, buf
+sizeof(buf
), &next
);
3082 this->wrotesome
= FALSE
;
3084 case CODECVT_partial
:
3085 if(!fwrite(buf
, next
-buf
, 1, this->file
))
3090 case CODECVT_noconv
:
3091 if(call_basic_streambuf_char_overflow(&this->base
, EOF
) == EOF
)
3100 /* ?close@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@XZ */
3101 /* ?close@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@XZ */
3102 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_close
, 4)
3103 basic_filebuf_char
* __thiscall
basic_filebuf_char_close(basic_filebuf_char
*this)
3105 basic_filebuf_char
*ret
= this;
3107 TRACE("(%p)\n", this);
3112 /* TODO: handle exceptions */
3113 if(!basic_filebuf_char__Endwrite(this))
3115 if(fclose(this->file
))
3118 basic_filebuf_char__Init(this, NULL
, INITFL_close
);
3122 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
3123 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3124 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor_file
, 8)
3125 basic_filebuf_char
* __thiscall
basic_filebuf_char_ctor_file(basic_filebuf_char
*this, FILE *file
)
3127 TRACE("(%p %p)\n", this, file
);
3129 basic_streambuf_char_ctor(&this->base
);
3130 this->base
.vtable
= &MSVCP_basic_filebuf_char_vtable
;
3132 basic_filebuf_char__Init(this, file
, INITFL_new
);
3136 /* ??_F?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEXXZ */
3137 /* ??_F?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAXXZ */
3138 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor
, 4)
3139 basic_filebuf_char
* __thiscall
basic_filebuf_char_ctor(basic_filebuf_char
*this)
3141 return basic_filebuf_char_ctor_file(this, NULL
);
3144 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3145 /* ??0?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3146 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_ctor_uninitialized
, 8)
3147 basic_filebuf_char
* __thiscall
basic_filebuf_char_ctor_uninitialized(basic_filebuf_char
*this, int uninitialized
)
3149 TRACE("(%p %d)\n", this, uninitialized
);
3151 basic_streambuf_char_ctor(&this->base
);
3152 this->base
.vtable
= &MSVCP_basic_filebuf_char_vtable
;
3156 /* ??1?$basic_filebuf@DU?$char_traits@D@std@@@std@@UAE@XZ */
3157 /* ??1?$basic_filebuf@DU?$char_traits@D@std@@@std@@UEAA@XZ */
3158 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_dtor
, 4)
3159 void __thiscall
basic_filebuf_char_dtor(basic_filebuf_char
*this)
3161 TRACE("(%p)\n", this);
3164 basic_filebuf_char_close(this);
3165 basic_streambuf_char_dtor(&this->base
);
3168 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_vector_dtor
, 8)
3169 basic_filebuf_char
* __thiscall
basic_filebuf_char_vector_dtor(basic_filebuf_char
*this, unsigned int flags
)
3171 TRACE("(%p %x)\n", this, flags
);
3173 /* we have an array, with the number of elements stored before the first object */
3174 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
3176 for(i
=*ptr
-1; i
>=0; i
--)
3177 basic_filebuf_char_dtor(this+i
);
3178 MSVCRT_operator_delete(ptr
);
3180 basic_filebuf_char_dtor(this);
3182 MSVCRT_operator_delete(this);
3188 /* ?is_open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QBE_NXZ */
3189 /* ?is_open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
3190 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_is_open
, 4)
3191 bool __thiscall
basic_filebuf_char_is_open(const basic_filebuf_char
*this)
3193 TRACE("(%p)\n", this);
3194 return this->file
!= NULL
;
3197 /* ?_Fiopen@std@@YAPAU_iobuf@@PB_WHH@Z */
3198 /* ?_Fiopen@std@@YAPEAU_iobuf@@PEB_WHH@Z */
3199 FILE* __cdecl
_Fiopen_wchar(const wchar_t *name
, int mode
, int prot
)
3201 static const struct {
3203 const wchar_t str
[4];
3204 const wchar_t str_bin
[4];
3206 {OPENMODE_out
, L
"w", L
"wb"},
3207 {OPENMODE_out
|OPENMODE_app
, L
"a", L
"ab"},
3208 {OPENMODE_app
, L
"a", L
"ab"},
3209 {OPENMODE_out
|OPENMODE_trunc
, L
"w", L
"wb"},
3210 {OPENMODE_in
, L
"r", L
"rb"},
3211 {OPENMODE_in
|OPENMODE_out
, L
"r+", L
"r+b"},
3212 {OPENMODE_in
|OPENMODE_out
|OPENMODE_trunc
, L
"w+", L
"w+b"},
3213 {OPENMODE_in
|OPENMODE_out
|OPENMODE_app
, L
"a+", L
"a+b"},
3214 {OPENMODE_in
|OPENMODE_app
, L
"a+", L
"a+b"}
3217 int real_mode
= mode
& ~(OPENMODE_ate
|OPENMODE__Nocreate
|OPENMODE__Noreplace
|OPENMODE_binary
);
3221 TRACE("(%s %d %d)\n", debugstr_w(name
), mode
, prot
);
3223 for(mode_idx
=0; mode_idx
<ARRAY_SIZE(str_mode
); mode_idx
++)
3224 if(str_mode
[mode_idx
].mode
== real_mode
)
3226 if(mode_idx
== ARRAY_SIZE(str_mode
))
3229 if((mode
& OPENMODE__Nocreate
) && !(f
= _wfopen(name
, L
"r")))
3234 if((mode
& OPENMODE__Noreplace
) && (mode
& (OPENMODE_out
|OPENMODE_app
))
3235 && (f
= _wfopen(name
, L
"r"))) {
3240 #if _MSVCP_VER < 80 /* msvcp60 - msvcp71 are ignoring prot argument */
3244 f
= _wfsopen(name
, (mode
& OPENMODE_binary
) ? str_mode
[mode_idx
].str_bin
3245 : str_mode
[mode_idx
].str
, prot
);
3249 if((mode
& OPENMODE_ate
) && fseek(f
, 0, SEEK_END
)) {
3257 /* ?_Fiopen@std@@YAPAU_iobuf@@PBDHH@Z */
3258 /* ?_Fiopen@std@@YAPEAU_iobuf@@PEBDHH@Z */
3259 FILE* __cdecl
_Fiopen(const char *name
, int mode
, int prot
)
3261 wchar_t nameW
[FILENAME_MAX
];
3263 TRACE("(%s %d %d)\n", name
, mode
, prot
);
3265 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3267 return _Fiopen_wchar(nameW
, mode
, prot
);
3270 /* ?__Fiopen@std@@YAPAU_iobuf@@PBDH@Z */
3271 /* ?__Fiopen@std@@YAPEAU_iobuf@@PEBDH@Z */
3272 FILE* __cdecl
___Fiopen(const char *name
, int mode
)
3274 TRACE("(%p %d)\n", name
, mode
);
3275 return _Fiopen(name
, mode
, _SH_DENYNO
);
3278 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PB_WHH@Z */
3279 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3280 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBGHH@Z */
3281 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3282 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_wchar
, 16)
3283 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_wchar(basic_filebuf_char
*this, const wchar_t *name
, int mode
, int prot
)
3287 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
3289 if(basic_filebuf_char_is_open(this))
3292 if(!(f
= _Fiopen_wchar(name
, mode
, prot
)))
3295 basic_filebuf_char__Init(this, f
, INITFL_open
);
3296 basic_filebuf_char__Initcvt_cvt(this, codecvt_char_use_facet(IOS_LOCALE(&this->base
)));
3300 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PB_WI@Z */
3301 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3302 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBGI@Z */
3303 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBGI@Z */
3304 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_wchar_mode
, 12)
3305 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_wchar_mode(basic_filebuf_char
*this, const wchar_t *name
, unsigned int mode
)
3307 return basic_filebuf_char_open_wchar(this, name
, mode
, SH_DENYNO
);
3310 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDHH@Z */
3311 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3312 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open
, 16)
3313 basic_filebuf_char
* __thiscall
basic_filebuf_char_open(basic_filebuf_char
*this, const char *name
, int mode
, int prot
)
3315 wchar_t nameW
[FILENAME_MAX
];
3317 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
3319 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3321 return basic_filebuf_char_open_wchar(this, nameW
, mode
, prot
);
3324 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDF@Z */
3325 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDF@Z */
3326 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_mode_old
, 12)
3327 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_mode_old(basic_filebuf_char
*this, const char *name
, short mode
)
3329 TRACE("(%p %p %d)\n", this, name
, mode
);
3330 return basic_filebuf_char_open(this, name
, mode
, SH_DENYNO
);
3333 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDH@Z */
3334 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDH@Z */
3335 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QAEPAV12@PBDI@Z */
3336 /* ?open@?$basic_filebuf@DU?$char_traits@D@std@@@std@@QEAAPEAV12@PEBDI@Z */
3337 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_open_mode
, 12)
3338 basic_filebuf_char
* __thiscall
basic_filebuf_char_open_mode(basic_filebuf_char
*this, const char *name
, unsigned int mode
)
3340 return basic_filebuf_char_open(this, name
, mode
, SH_DENYNO
);
3343 /* ?overflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
3344 /* ?overflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
3345 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_overflow
, 8)
3346 int __thiscall
basic_filebuf_char_overflow(basic_filebuf_char
*this, int c
)
3348 char buf
[8], *dyn_buf
;
3349 char ch
= c
, *to_next
;
3350 const char *from_next
;
3354 TRACE("(%p %d)\n", this, c
);
3356 if(!basic_filebuf_char_is_open(this))
3362 return fputc(ch
, this->file
);
3366 ret
= codecvt_char_out(this->cvt
, &this->state
, from_next
, &ch
+1,
3367 &from_next
, buf
, buf
+sizeof(buf
), &to_next
);
3370 case CODECVT_partial
:
3375 if(!fwrite(buf
, to_next
-buf
, 1, this->file
))
3377 if(ret
== CODECVT_partial
)
3380 case CODECVT_noconv
:
3381 return fwrite(&ch
, sizeof(char), 1, this->file
) ? c
: EOF
;
3389 max_size
= codecvt_base_max_length(&this->cvt
->base
);
3390 dyn_buf
= malloc(max_size
);
3394 ret
= codecvt_char_out(this->cvt
, &this->state
, from_next
, &ch
+1,
3395 &from_next
, dyn_buf
, dyn_buf
+max_size
, &to_next
);
3399 ret
= fwrite(dyn_buf
, to_next
-dyn_buf
, 1, this->file
);
3401 return ret
? c
: EOF
;
3402 case CODECVT_partial
:
3403 ERR("buffer should be big enough to store all output\n");
3411 /* ?pbackfail@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHH@Z */
3412 /* ?pbackfail@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHH@Z */
3413 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_pbackfail
, 8)
3414 int __thiscall
basic_filebuf_char_pbackfail(basic_filebuf_char
*this, int c
)
3416 TRACE("(%p %d)\n", this, c
);
3418 if(!basic_filebuf_char_is_open(this))
3421 if(basic_streambuf_char_gptr(&this->base
)>basic_streambuf_char_eback(&this->base
)
3422 && (c
==EOF
|| (int)(unsigned char)basic_streambuf_char_gptr(&this->base
)[-1]==c
)) {
3423 basic_streambuf_char__Gndec(&this->base
);
3424 return c
==EOF
? !c
: c
;
3425 }else if(c
!=EOF
&& !this->cvt
) {
3426 return ungetc(c
, this->file
);
3432 /* ?uflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
3433 /* ?uflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
3434 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_uflow
, 4)
3435 int __thiscall
basic_filebuf_char_uflow(basic_filebuf_char
*this)
3437 char ch
, buf
[128], *to_next
;
3438 const char *buf_next
;
3442 TRACE("(%p)\n", this);
3444 if(!basic_filebuf_char_is_open(this))
3447 if(basic_streambuf_char_gptr(&this->base
) < basic_streambuf_char_egptr(&this->base
))
3448 return (unsigned char)*basic_streambuf_char__Gninc(&this->base
);
3450 c
= fgetc(this->file
);
3451 if(!this->cvt
|| c
==EOF
)
3455 for(i
=0; i
< ARRAY_SIZE(buf
); i
++) {
3458 switch(codecvt_char_in(this->cvt
, &this->state
, buf_next
,
3459 buf
+i
+1, &buf_next
, &ch
, &ch
+1, &to_next
)) {
3460 case CODECVT_partial
:
3462 if(to_next
== &ch
) {
3463 c
= fgetc(this->file
);
3469 for(j
= --i
; j
>= buf_next
-buf
; j
--)
3470 ungetc(buf
[j
], this->file
);
3472 case CODECVT_noconv
:
3473 return (unsigned char)buf
[0];
3479 FIXME("buffer is too small\n");
3483 /* ?underflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
3484 /* ?underflow@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
3485 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_underflow
, 4)
3486 int __thiscall
basic_filebuf_char_underflow(basic_filebuf_char
*this)
3490 TRACE("(%p)\n", this);
3492 if(basic_streambuf_char_gptr(&this->base
) < basic_streambuf_char_egptr(&this->base
))
3493 return (unsigned char)*basic_streambuf_char_gptr(&this->base
);
3495 ret
= call_basic_streambuf_char_uflow(&this->base
);
3497 ret
= call_basic_streambuf_char_pbackfail(&this->base
, ret
);
3501 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
3502 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
3503 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
3504 /* ?seekoff@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
3505 #if STREAMOFF_BITS == 64
3506 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekoff
, 24)
3508 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekoff
, 20)
3510 fpos_mbstatet
* __thiscall
basic_filebuf_char_seekoff(basic_filebuf_char
*this,
3511 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
3515 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
3517 if(!basic_filebuf_char_is_open(this) || !basic_filebuf_char__Endwrite(this)
3518 || fseek(this->file
, off
, way
)) {
3521 memset(&ret
->state
, 0, sizeof(ret
->state
));
3525 fgetpos(this->file
, &pos
);
3528 ret
->state
= this->state
;
3532 /* ?seekpos@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
3533 /* ?seekpos@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
3534 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_seekpos
, 36)
3535 fpos_mbstatet
* __thiscall
basic_filebuf_char_seekpos(basic_filebuf_char
*this,
3536 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
3540 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_mbstatet(&pos
), mode
);
3542 if(!basic_filebuf_char_is_open(this) || !basic_filebuf_char__Endwrite(this)
3543 || fseek(this->file
, (LONG
)pos
.pos
, SEEK_SET
)
3544 || (pos
.off
&& fseek(this->file
, pos
.off
, SEEK_CUR
))) {
3547 memset(&ret
->state
, 0, sizeof(ret
->state
));
3551 fgetpos(this->file
, &fpos
);
3554 ret
->state
= this->state
;
3558 /* ?setbuf@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PADH@Z */
3559 /* ?setbuf@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAD_J@Z */
3560 #if STREAMSIZE_BITS == 64
3561 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_setbuf
, 16)
3563 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_setbuf
, 12)
3565 basic_streambuf_char
* __thiscall
basic_filebuf_char_setbuf(basic_filebuf_char
*this, char *buf
, streamsize count
)
3567 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
3569 if(!basic_filebuf_char_is_open(this))
3572 if(setvbuf(this->file
, buf
, (buf
==NULL
&& count
==0) ? _IONBF
: _IOFBF
, count
))
3575 basic_filebuf_char__Init(this, this->file
, INITFL_open
);
3579 /* ?sync@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEHXZ */
3580 /* ?sync@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAHXZ */
3581 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_sync
, 4)
3582 int __thiscall
basic_filebuf_char_sync(basic_filebuf_char
*this)
3584 TRACE("(%p)\n", this);
3586 if(!basic_filebuf_char_is_open(this))
3589 if(call_basic_streambuf_char_overflow(&this->base
, EOF
) == EOF
)
3591 return fflush(this->file
);
3594 /* ?imbue@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MAEXABVlocale@2@@Z */
3595 /* ?imbue@?$basic_filebuf@DU?$char_traits@D@std@@@std@@MEAAXAEBVlocale@2@@Z */
3596 DEFINE_THISCALL_WRAPPER(basic_filebuf_char_imbue
, 8)
3597 void __thiscall
basic_filebuf_char_imbue(basic_filebuf_char
*this, const locale
*loc
)
3599 TRACE("(%p %p)\n", this, loc
);
3600 basic_filebuf_char__Initcvt_cvt(this, codecvt_char_use_facet(loc
));
3603 /* ?_Stinit@?1??_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
3604 /* ?_Stinit@?1??_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
3605 #if _MSVCP_VER >= 140
3606 _Mbstatet basic_filebuf_wchar__Init__Stinit
= {0};
3608 _Mbstatet basic_filebuf_wchar__Init__Stinit
= 0;
3611 /* ?_Stinit@?1??_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@23@@Z@4HA */
3612 /* ?_Stinit@?1??_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@23@@Z@4HA */
3613 #if _MSVCP_VER >= 140
3614 _Mbstatet basic_filebuf_short__Init__Stinit
= {0};
3616 _Mbstatet basic_filebuf_short__Init__Stinit
= 0;
3619 /* ?_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
3620 /* ?_Init@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
3621 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Init
, 12)
3622 void __thiscall
basic_filebuf_wchar__Init(basic_filebuf_wchar
*this, FILE *file
, basic_filebuf__Initfl which
)
3624 TRACE("(%p %p %d)\n", this, file
, which
);
3627 this->wrotesome
= FALSE
;
3628 this->state
= basic_filebuf_wchar__Init__Stinit
;
3629 this->close
= (which
== INITFL_open
);
3632 basic_streambuf_wchar__Init_empty(&this->base
);
3635 /* ?_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAU_iobuf@@W4_Initfl@12@@Z */
3636 /* ?_Init@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAU_iobuf@@W4_Initfl@12@@Z */
3637 DEFINE_THISCALL_WRAPPER(basic_filebuf_short__Init
, 12)
3638 void __thiscall
basic_filebuf_short__Init(basic_filebuf_wchar
*this, FILE *file
, basic_filebuf__Initfl which
)
3640 TRACE("(%p %p %d)\n", this, file
, which
);
3643 this->wrotesome
= FALSE
;
3644 this->state
= basic_filebuf_short__Init__Stinit
;
3645 this->close
= (which
== INITFL_open
);
3648 basic_streambuf_wchar__Init_empty(&this->base
);
3651 /* ?_Initcvt@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$codecvt@_WDH@2@@Z */
3652 /* ?_Initcvt@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$codecvt@_WDH@2@@Z */
3653 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXPAV?$codecvt@GDH@2@@Z */
3654 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$codecvt@GDH@2@@Z */
3655 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Initcvt_cvt
, 8)
3656 void __thiscall
basic_filebuf_wchar__Initcvt_cvt(basic_filebuf_wchar
*this, codecvt_wchar
*cvt
)
3658 TRACE("(%p %p)\n", this, cvt
);
3660 if(codecvt_base_always_noconv(&cvt
->base
)) {
3663 basic_streambuf_wchar__Init_empty(&this->base
);
3668 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAEXXZ */
3669 /* ?_Initcvt@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAAXXZ */
3670 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Initcvt
, 4)
3671 void __thiscall
basic_filebuf_wchar__Initcvt(basic_filebuf_wchar
*this)
3673 codecvt_wchar
*cvt
= codecvt_wchar_use_facet(IOS_LOCALE(&this->base
));
3674 basic_filebuf_wchar__Initcvt_cvt( this, cvt
);
3677 /* ?_Endwrite@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IAE_NXZ */
3678 /* ?_Endwrite@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@IEAA_NXZ */
3679 /* ?_Endwrite@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IAE_NXZ */
3680 /* ?_Endwrite@?$basic_filebuf@GU?$char_traits@G@std@@@std@@IEAA_NXZ */
3681 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar__Endwrite
, 4)
3682 bool __thiscall
basic_filebuf_wchar__Endwrite(basic_filebuf_wchar
*this)
3684 TRACE("(%p)\n", this);
3686 if(!this->wrotesome
|| !this->cvt
)
3689 if(call_basic_streambuf_wchar_overflow(&this->base
, WEOF
) == WEOF
)
3693 /* TODO: check if we need a dynamic buffer here */
3698 ret
= codecvt_wchar_unshift(this->cvt
, &this->state
, buf
, buf
+sizeof(buf
), &next
);
3701 this->wrotesome
= FALSE
;
3703 case CODECVT_partial
:
3704 if(!fwrite(buf
, next
-buf
, 1, this->file
))
3709 case CODECVT_noconv
:
3710 if(call_basic_streambuf_wchar_overflow(&this->base
, WEOF
) == WEOF
)
3719 /* ?close@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@XZ */
3720 /* ?close@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@XZ */
3721 /* ?close@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@XZ */
3722 /* ?close@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@XZ */
3723 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_close
, 4)
3724 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_close(basic_filebuf_wchar
*this)
3726 basic_filebuf_wchar
*ret
= this;
3728 TRACE("(%p)\n", this);
3733 /* TODO: handle exceptions */
3734 if(!basic_filebuf_wchar__Endwrite(this))
3736 if(fclose(this->file
))
3739 basic_filebuf_wchar__Init(this, NULL
, INITFL_close
);
3743 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
3744 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3745 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor_file
, 8)
3746 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_ctor_file(basic_filebuf_wchar
*this, FILE *file
)
3748 TRACE("(%p %p)\n", this, file
);
3750 basic_streambuf_wchar_ctor(&this->base
);
3751 this->base
.vtable
= &MSVCP_basic_filebuf_wchar_vtable
;
3753 basic_filebuf_wchar__Init(this, file
, INITFL_new
);
3757 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
3758 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
3759 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor_file
, 8)
3760 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_ctor_file(basic_filebuf_wchar
*this, FILE *file
)
3762 TRACE("(%p %p)\n", this, file
);
3764 basic_streambuf_short_ctor(&this->base
);
3765 this->base
.vtable
= &MSVCP_basic_filebuf_short_vtable
;
3767 basic_filebuf_short__Init(this, file
, INITFL_new
);
3771 /* ??_F?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
3772 /* ??_F?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
3773 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor
, 4)
3774 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_ctor(basic_filebuf_wchar
*this)
3776 return basic_filebuf_wchar_ctor_file(this, NULL
);
3779 /* ??_F?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEXXZ */
3780 /* ??_F?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAXXZ */
3781 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor
, 4)
3782 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_ctor(basic_filebuf_wchar
*this)
3784 return basic_filebuf_short_ctor_file(this, NULL
);
3787 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3788 /* ??0?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3789 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_ctor_uninitialized
, 8)
3790 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_ctor_uninitialized(basic_filebuf_wchar
*this, int uninitialized
)
3792 TRACE("(%p %d)\n", this, uninitialized
);
3794 basic_streambuf_wchar_ctor(&this->base
);
3795 this->base
.vtable
= &MSVCP_basic_filebuf_wchar_vtable
;
3799 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z */
3800 /* ??0?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
3801 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_ctor_uninitialized
, 8)
3802 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_ctor_uninitialized(basic_filebuf_wchar
*this, int uninitialized
)
3804 TRACE("(%p %d)\n", this, uninitialized
);
3806 basic_streambuf_short_ctor(&this->base
);
3807 this->base
.vtable
= &MSVCP_basic_filebuf_short_vtable
;
3811 /* ??1?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
3812 /* ??1?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
3813 /* ??1?$basic_filebuf@GU?$char_traits@G@std@@@std@@UAE@XZ */
3814 /* ??1?$basic_filebuf@GU?$char_traits@G@std@@@std@@UEAA@XZ */
3815 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_dtor
, 4)
3816 void __thiscall
basic_filebuf_wchar_dtor(basic_filebuf_wchar
*this)
3818 TRACE("(%p)\n", this);
3821 basic_filebuf_wchar_close(this);
3822 basic_streambuf_wchar_dtor(&this->base
);
3825 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_vector_dtor
, 8)
3826 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_vector_dtor(basic_filebuf_wchar
*this, unsigned int flags
)
3828 TRACE("(%p %x)\n", this, flags
);
3830 /* we have an array, with the number of elements stored before the first object */
3831 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
3833 for(i
=*ptr
-1; i
>=0; i
--)
3834 basic_filebuf_wchar_dtor(this+i
);
3835 MSVCRT_operator_delete(ptr
);
3837 basic_filebuf_wchar_dtor(this);
3839 MSVCRT_operator_delete(this);
3845 /* ?is_open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
3846 /* ?is_open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
3847 /* ?is_open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QBE_NXZ */
3848 /* ?is_open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
3849 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_is_open
, 4)
3850 bool __thiscall
basic_filebuf_wchar_is_open(const basic_filebuf_wchar
*this)
3852 TRACE("(%p)\n", this);
3853 return this->file
!= NULL
;
3856 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PB_WHH@Z */
3857 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3858 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBGHH@Z */
3859 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3860 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_wchar
, 16)
3861 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_wchar(basic_filebuf_wchar
*this, const wchar_t *name
, int mode
, int prot
)
3865 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
3867 if(basic_filebuf_wchar_is_open(this))
3870 if(!(f
= _Fiopen_wchar(name
, mode
, prot
)))
3873 basic_filebuf_wchar__Init(this, f
, INITFL_open
);
3874 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_wchar_use_facet(IOS_LOCALE(&this->base
)));
3878 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PB_WHH@Z */
3879 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEB_WHH@Z */
3880 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBGHH@Z */
3881 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBGHH@Z */
3882 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_wchar
, 16)
3883 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open_wchar(basic_filebuf_wchar
*this, const wchar_t *name
, int mode
, int prot
)
3887 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
3889 if(basic_filebuf_wchar_is_open(this))
3892 if(!(f
= _Fiopen_wchar(name
, mode
, prot
)))
3895 basic_filebuf_short__Init(this, f
, INITFL_open
);
3896 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_short_use_facet(IOS_LOCALE(&this->base
)));
3900 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PB_WI@Z */
3901 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3902 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBGI@Z */
3903 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBGI@Z */
3904 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_wchar_mode
, 12)
3905 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_wchar_mode(basic_filebuf_wchar
*this, const wchar_t *name
, unsigned int mode
)
3907 return basic_filebuf_wchar_open_wchar(this, name
, mode
, SH_DENYNO
);
3910 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PB_WI@Z */
3911 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEB_WI@Z */
3912 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBGI@Z */
3913 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBGI@Z */
3914 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_wchar_mode
, 12)
3915 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open_wchar_mode(basic_filebuf_wchar
*this, const wchar_t *name
, unsigned int mode
)
3917 return basic_filebuf_short_open_wchar(this, name
, mode
, SH_DENYNO
);
3920 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBDHH@Z */
3921 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3922 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open
, 16)
3923 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open(basic_filebuf_wchar
*this, const char *name
, int mode
, int prot
)
3925 wchar_t nameW
[FILENAME_MAX
];
3927 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
3929 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3931 return basic_filebuf_wchar_open_wchar(this, nameW
, mode
, prot
);
3934 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDHH@Z */
3935 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDHH@Z */
3936 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open
, 16)
3937 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open(basic_filebuf_wchar
*this, const char *name
, int mode
, int prot
)
3939 wchar_t nameW
[FILENAME_MAX
];
3941 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
3943 if(mbstowcs_s(NULL
, nameW
, FILENAME_MAX
, name
, FILENAME_MAX
-1) != 0)
3945 return basic_filebuf_short_open_wchar(this, nameW
, mode
, prot
);
3948 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDF@Z */
3949 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDF@Z */
3950 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_mode_old
, 12)
3951 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_mode_old(basic_filebuf_wchar
*this, const char *name
, short mode
)
3953 TRACE("(%p %p %d)\n", this, name
, mode
);
3954 return basic_filebuf_wchar_open(this, name
, mode
, SH_DENYNO
);
3957 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDH@Z */
3958 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDH@Z */
3959 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QAEPAV12@PBDI@Z */
3960 /* ?open@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@QEAAPEAV12@PEBDI@Z */
3961 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_open_mode
, 12)
3962 basic_filebuf_wchar
* __thiscall
basic_filebuf_wchar_open_mode(basic_filebuf_wchar
*this, const char *name
, unsigned int mode
)
3964 return basic_filebuf_wchar_open(this, name
, mode
, SH_DENYNO
);
3967 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QAEPAV12@PBDI@Z */
3968 /* ?open@?$basic_filebuf@GU?$char_traits@G@std@@@std@@QEAAPEAV12@PEBDI@Z */
3969 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_open_mode
, 12)
3970 basic_filebuf_wchar
* __thiscall
basic_filebuf_short_open_mode(basic_filebuf_wchar
*this, const char *name
, unsigned int mode
)
3972 return basic_filebuf_short_open(this, name
, mode
, SH_DENYNO
);
3975 /* ?overflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
3976 /* ?overflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
3977 /* ?overflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
3978 /* ?overflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
3979 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_overflow
, 8)
3980 unsigned short __thiscall
basic_filebuf_wchar_overflow(basic_filebuf_wchar
*this, unsigned short c
)
3982 char buf
[8], *dyn_buf
, *to_next
;
3984 const wchar_t *from_next
;
3989 TRACE("(%p %d)\n", this, c
);
3991 if(!basic_filebuf_wchar_is_open(this))
3997 return fputwc(ch
, this->file
);
4001 ret
= codecvt_wchar_out(this->cvt
, &this->state
, from_next
, &ch
+1,
4002 &from_next
, buf
, buf
+sizeof(buf
), &to_next
);
4005 case CODECVT_partial
:
4010 if(!fwrite(buf
, to_next
-buf
, 1, this->file
))
4012 if(ret
== CODECVT_partial
)
4015 case CODECVT_noconv
:
4016 return fwrite(&ch
, sizeof(wchar_t), 1, this->file
) ? c
: WEOF
;
4024 max_size
= codecvt_base_max_length(&this->cvt
->base
);
4025 dyn_buf
= malloc(max_size
);
4029 ret
= codecvt_wchar_out(this->cvt
, &this->state
, from_next
, &ch
+1,
4030 &from_next
, dyn_buf
, dyn_buf
+max_size
, &to_next
);
4034 ret
= fwrite(dyn_buf
, to_next
-dyn_buf
, 1, this->file
);
4036 return ret
? c
: WEOF
;
4037 case CODECVT_partial
:
4038 ERR("buffer should be big enough to store all output\n");
4046 /* ?pbackfail@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGG@Z */
4047 /* ?pbackfail@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGG@Z */
4048 /* ?pbackfail@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGG@Z */
4049 /* ?pbackfail@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGG@Z */
4050 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_pbackfail
, 8)
4051 unsigned short __thiscall
basic_filebuf_wchar_pbackfail(basic_filebuf_wchar
*this, unsigned short c
)
4053 TRACE("(%p %d)\n", this, c
);
4055 if(!basic_filebuf_wchar_is_open(this))
4058 if(basic_streambuf_wchar_gptr(&this->base
)>basic_streambuf_wchar_eback(&this->base
)
4059 && (c
==WEOF
|| basic_streambuf_wchar_gptr(&this->base
)[-1]==c
)) {
4060 basic_streambuf_wchar__Gndec(&this->base
);
4061 return c
==WEOF
? !c
: c
;
4062 }else if(c
!=WEOF
&& !this->cvt
) {
4063 return ungetwc(c
, this->file
);
4064 }else if(c
!=WEOF
&& basic_streambuf_wchar_gptr(&this->base
)!=&this->putback
) {
4066 basic_streambuf_wchar_setg(&this->base
, &this->putback
, &this->putback
, &this->putback
+1);
4073 /* ?uflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
4074 /* ?uflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
4075 /* ?uflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
4076 /* ?uflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
4077 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_uflow
, 4)
4078 unsigned short __thiscall
basic_filebuf_wchar_uflow(basic_filebuf_wchar
*this)
4080 wchar_t ch
, *to_next
;
4082 const char *buf_next
;
4086 TRACE("(%p)\n", this);
4088 if(!basic_filebuf_wchar_is_open(this))
4091 if(basic_streambuf_wchar_gptr(&this->base
) < basic_streambuf_wchar_egptr(&this->base
))
4092 return *basic_streambuf_wchar__Gninc(&this->base
);
4095 return fgetwc(this->file
);
4098 for(i
=0; i
< ARRAY_SIZE(buf
); i
++) {
4099 if((c
= fgetc(this->file
)) == EOF
)
4103 switch(codecvt_wchar_in(this->cvt
, &this->state
, buf_next
,
4104 buf
+i
+1, &buf_next
, &ch
, &ch
+1, &to_next
)) {
4105 case CODECVT_partial
:
4110 for(j
= --i
; j
>= buf_next
-buf
; j
--)
4111 ungetc(buf
[j
], this->file
);
4113 case CODECVT_noconv
:
4114 if(i
+1 < sizeof(wchar_t))
4117 memcpy(&ch
, buf
, sizeof(wchar_t));
4124 FIXME("buffer is too small\n");
4128 /* ?underflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEGXZ */
4129 /* ?underflow@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAGXZ */
4130 /* ?underflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEGXZ */
4131 /* ?underflow@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAGXZ */
4132 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_underflow
, 4)
4133 unsigned short __thiscall
basic_filebuf_wchar_underflow(basic_filebuf_wchar
*this)
4137 TRACE("(%p)\n", this);
4139 if(basic_streambuf_wchar_gptr(&this->base
) < basic_streambuf_wchar_egptr(&this->base
))
4140 return *basic_streambuf_wchar_gptr(&this->base
);
4142 ret
= call_basic_streambuf_wchar_uflow(&this->base
);
4144 ret
= call_basic_streambuf_wchar_pbackfail(&this->base
, ret
);
4148 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
4149 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
4150 /* ?seekoff@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4151 /* ?seekoff@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4152 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4153 /* ?seekoff@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4154 #if STREAMOFF_BITS == 64
4155 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekoff
, 24)
4157 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekoff
, 20)
4159 fpos_mbstatet
* __thiscall
basic_filebuf_wchar_seekoff(basic_filebuf_wchar
*this,
4160 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
4164 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
4166 if(basic_streambuf_wchar_gptr(&this->base
) == &this->putback
) {
4167 if(way
== SEEKDIR_cur
)
4168 off
-= sizeof(wchar_t);
4170 basic_streambuf_wchar_setg(&this->base
, &this->putback
, &this->putback
+1, &this->putback
+1);
4173 if(!basic_filebuf_wchar_is_open(this) || !basic_filebuf_wchar__Endwrite(this)
4174 || fseek(this->file
, off
, way
)) {
4177 memset(&ret
->state
, 0, sizeof(ret
->state
));
4181 fgetpos(this->file
, &pos
);
4184 ret
->state
= this->state
;
4188 /* ?seekpos@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4189 /* ?seekpos@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4190 /* ?seekpos@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4191 /* ?seekpos@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4192 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_seekpos
, 36)
4193 fpos_mbstatet
* __thiscall
basic_filebuf_wchar_seekpos(basic_filebuf_wchar
*this,
4194 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
4198 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_mbstatet(&pos
), mode
);
4200 if(!basic_filebuf_wchar_is_open(this) || !basic_filebuf_wchar__Endwrite(this)
4201 || fseek(this->file
, (LONG
)pos
.pos
, SEEK_SET
)
4202 || (pos
.off
&& fseek(this->file
, pos
.off
, SEEK_CUR
))) {
4205 memset(&ret
->state
, 0, sizeof(ret
->state
));
4209 if(basic_streambuf_wchar_gptr(&this->base
) == &this->putback
)
4210 basic_streambuf_wchar_setg(&this->base
, &this->putback
, &this->putback
+1, &this->putback
+1);
4212 fgetpos(this->file
, &fpos
);
4215 ret
->state
= this->state
;
4219 /* ?setbuf@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PA_WH@Z */
4220 /* ?setbuf@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEA_W_J@Z */
4221 #if STREAMSIZE_BITS == 64
4222 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_setbuf
, 16)
4224 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_setbuf
, 12)
4226 basic_streambuf_wchar
* __thiscall
basic_filebuf_wchar_setbuf(basic_filebuf_wchar
*this, wchar_t *buf
, streamsize count
)
4228 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
4230 if(!basic_filebuf_wchar_is_open(this))
4233 if(setvbuf(this->file
, (char*)buf
, (buf
==NULL
&& count
==0) ? _IONBF
: _IOFBF
, count
*sizeof(wchar_t)))
4236 basic_filebuf_wchar__Init(this, this->file
, INITFL_open
);
4240 /* ?setbuf@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAGH@Z */
4241 /* ?setbuf@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAG_J@Z */
4242 #if STREAMSIZE_BITS == 64
4243 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_setbuf
, 16)
4245 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_setbuf
, 12)
4247 basic_streambuf_wchar
* __thiscall
basic_filebuf_short_setbuf(basic_filebuf_wchar
*this, wchar_t *buf
, streamsize count
)
4249 TRACE("(%p %p %s)\n", this, buf
, wine_dbgstr_longlong(count
));
4251 if(!basic_filebuf_wchar_is_open(this))
4254 if(setvbuf(this->file
, (char*)buf
, (buf
==NULL
&& count
==0) ? _IONBF
: _IOFBF
, count
*sizeof(wchar_t)))
4257 basic_filebuf_short__Init(this, this->file
, INITFL_open
);
4261 /* ?sync@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEHXZ */
4262 /* ?sync@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAHXZ */
4263 /* ?sync@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEHXZ */
4264 /* ?sync@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAHXZ */
4265 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_sync
, 4)
4266 int __thiscall
basic_filebuf_wchar_sync(basic_filebuf_wchar
*this)
4268 TRACE("(%p)\n", this);
4270 if(!basic_filebuf_wchar_is_open(this))
4273 if(call_basic_streambuf_wchar_overflow(&this->base
, WEOF
) == WEOF
)
4275 return fflush(this->file
);
4278 /* ?imbue@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MAEXABVlocale@2@@Z */
4279 /* ?imbue@?$basic_filebuf@_WU?$char_traits@_W@std@@@std@@MEAAXAEBVlocale@2@@Z */
4280 DEFINE_THISCALL_WRAPPER(basic_filebuf_wchar_imbue
, 8)
4281 void __thiscall
basic_filebuf_wchar_imbue(basic_filebuf_wchar
*this, const locale
*loc
)
4283 TRACE("(%p %p)\n", this, loc
);
4284 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_wchar_use_facet(loc
));
4287 /* ?imbue@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MAEXABVlocale@2@@Z */
4288 /* ?imbue@?$basic_filebuf@GU?$char_traits@G@std@@@std@@MEAAXAEBVlocale@2@@Z */
4289 DEFINE_THISCALL_WRAPPER(basic_filebuf_short_imbue
, 8)
4290 void __thiscall
basic_filebuf_short_imbue(basic_filebuf_wchar
*this, const locale
*loc
)
4292 TRACE("(%p %p)\n", this, loc
);
4293 basic_filebuf_wchar__Initcvt_cvt(this, codecvt_short_use_facet(loc
));
4296 /* ?_Getstate@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AAEHH@Z */
4297 /* ?_Getstate@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEAAHH@Z */
4298 /* ?_Mode@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AAEHH@Z */
4299 /* ?_Mode@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEAAHH@Z */
4300 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Getstate
, 8)
4301 int __thiscall
basic_stringbuf_char__Getstate(basic_stringbuf_char
*this, IOSB_openmode mode
)
4305 if(!(mode
& OPENMODE_in
))
4306 state
|= STRINGBUF_no_read
;
4308 if(!(mode
& OPENMODE_out
))
4309 state
|= STRINGBUF_no_write
;
4311 if(mode
& OPENMODE_ate
)
4312 state
|= STRINGBUF_at_end
;
4314 if(mode
& OPENMODE_app
)
4315 state
|= STRINGBUF_append
;
4320 /* ?_Init@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEXPBDIH@Z */
4321 /* ?_Init@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IEAAXPEBD_KH@Z */
4322 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Init
, 16)
4323 void __thiscall
basic_stringbuf_char__Init(basic_stringbuf_char
*this, const char *str
, size_t count
, int state
)
4325 TRACE("(%p, %p, %Iu, %d)\n", this, str
, count
, state
);
4327 basic_streambuf_char__Init_empty(&this->base
);
4329 this->state
= state
;
4330 this->seekhigh
= NULL
;
4333 char *buf
= MSVCRT_operator_new(count
);
4335 ERR("Out of memory\n");
4336 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4339 memcpy(buf
, str
, count
);
4340 this->seekhigh
= buf
+ count
;
4342 this->state
|= STRINGBUF_allocated
;
4344 if(!(state
& STRINGBUF_no_read
))
4345 basic_streambuf_char_setg(&this->base
, buf
, buf
, buf
+ count
);
4347 if(!(state
& STRINGBUF_no_write
)) {
4348 basic_streambuf_char_setp_next(&this->base
, buf
, (state
& STRINGBUF_at_end
) ? buf
+ count
: buf
, buf
+ count
);
4350 if(!basic_streambuf_char_gptr(&this->base
))
4351 basic_streambuf_char_setg(&this->base
, buf
, 0, buf
);
4356 /* ??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 */
4357 /* ??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 */
4358 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor_str
, 12)
4359 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_ctor_str(basic_stringbuf_char
*this,
4360 const basic_string_char
*str
, IOSB_openmode mode
)
4362 TRACE("(%p %p %d)\n", this, str
, mode
);
4364 basic_streambuf_char_ctor(&this->base
);
4365 this->base
.vtable
= &MSVCP_basic_stringbuf_char_vtable
;
4367 basic_stringbuf_char__Init(this, MSVCP_basic_string_char_c_str(str
),
4368 str
->size
, basic_stringbuf_char__Getstate(this, mode
));
4372 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
4373 /* ??0?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
4374 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor_mode
, 8)
4375 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_ctor_mode(
4376 basic_stringbuf_char
*this, IOSB_openmode mode
)
4378 TRACE("(%p %d)\n", this, mode
);
4380 basic_streambuf_char_ctor(&this->base
);
4381 this->base
.vtable
= &MSVCP_basic_stringbuf_char_vtable
;
4383 basic_stringbuf_char__Init(this, NULL
, 0, basic_stringbuf_char__Getstate(this, mode
));
4387 /* ??_F?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
4388 /* ??_F?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
4389 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_ctor
, 4)
4390 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_ctor(basic_stringbuf_char
*this)
4392 return basic_stringbuf_char_ctor_mode(this, OPENMODE_in
|OPENMODE_out
);
4395 /* ?_Tidy@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IAEXXZ */
4396 /* ?_Tidy@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@IEAAXXZ */
4397 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char__Tidy
, 4)
4398 void __thiscall
basic_stringbuf_char__Tidy(basic_stringbuf_char
*this)
4400 TRACE("(%p)\n", this);
4402 if(this->state
& STRINGBUF_allocated
) {
4403 MSVCRT_operator_delete(basic_streambuf_char_eback(&this->base
));
4404 this->seekhigh
= NULL
;
4405 this->state
&= ~STRINGBUF_allocated
;
4408 basic_streambuf_char__Init_empty(&this->base
);
4411 /* ??1?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
4412 /* ??1?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
4413 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_dtor
, 4)
4414 void __thiscall
basic_stringbuf_char_dtor(basic_stringbuf_char
*this)
4416 TRACE("(%p)\n", this);
4418 basic_stringbuf_char__Tidy(this);
4419 basic_streambuf_char_dtor(&this->base
);
4422 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_vector_dtor
, 8)
4423 basic_stringbuf_char
* __thiscall
basic_stringbuf_char_vector_dtor(basic_stringbuf_char
*this, unsigned int flags
)
4425 TRACE("(%p %x)\n", this, flags
);
4428 /* we have an array, with the number of elements stored before the first object */
4429 INT_PTR i
, *ptr
= (INT_PTR
*) this - 1;
4431 for (i
= *ptr
- 1; i
>= 0; i
--)
4432 basic_stringbuf_char_dtor(this+i
);
4434 MSVCRT_operator_delete(ptr
);
4436 basic_stringbuf_char_dtor(this);
4439 MSVCRT_operator_delete(this);
4445 /* ?overflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHH@Z */
4446 /* ?overflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z */
4447 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_overflow
, 8)
4448 int __thiscall
basic_stringbuf_char_overflow(basic_stringbuf_char
*this, int meta
)
4450 size_t oldsize
, size
;
4453 TRACE("(%p %x)\n", this, meta
);
4457 if(this->state
& STRINGBUF_no_write
)
4460 ptr
= basic_streambuf_char_pptr(&this->base
);
4461 if((this->state
&STRINGBUF_append
) && ptr
<this->seekhigh
)
4462 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
),
4463 this->seekhigh
, basic_streambuf_char_epptr(&this->base
));
4465 if(ptr
&& ptr
<basic_streambuf_char_epptr(&this->base
))
4466 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = meta
);
4468 oldsize
= (ptr
? basic_streambuf_char_epptr(&this->base
)-basic_streambuf_char_eback(&this->base
): 0);
4471 buf
= MSVCRT_operator_new(size
);
4473 ERR("Out of memory\n");
4474 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4478 this->seekhigh
= buf
;
4479 basic_streambuf_char_setp(&this->base
, buf
, buf
+size
);
4480 if(this->state
& STRINGBUF_no_read
)
4481 basic_streambuf_char_setg(&this->base
, buf
, NULL
, buf
);
4483 basic_streambuf_char_setg(&this->base
, buf
, buf
, buf
+1);
4485 this->state
|= STRINGBUF_allocated
;
4487 ptr
= basic_streambuf_char_eback(&this->base
);
4488 memcpy(buf
, ptr
, oldsize
);
4490 this->seekhigh
= buf
+(this->seekhigh
-ptr
);
4491 basic_streambuf_char_setp_next(&this->base
, buf
,
4492 buf
+(basic_streambuf_char_pptr(&this->base
)-ptr
), buf
+size
);
4493 if(this->state
& STRINGBUF_no_read
)
4494 basic_streambuf_char_setg(&this->base
, buf
, NULL
, buf
);
4496 basic_streambuf_char_setg(&this->base
, buf
,
4497 buf
+(basic_streambuf_char_gptr(&this->base
)-ptr
),
4498 basic_streambuf_char_pptr(&this->base
)+1);
4500 MSVCRT_operator_delete(ptr
);
4503 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = meta
);
4506 /* ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHH@Z */
4507 /* ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z */
4508 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_pbackfail
, 8)
4509 int __thiscall
basic_stringbuf_char_pbackfail(basic_stringbuf_char
*this, int c
)
4513 TRACE("(%p %x)\n", this, c
);
4515 cur
= basic_streambuf_char_gptr(&this->base
);
4516 if(!cur
|| cur
==basic_streambuf_char_eback(&this->base
)
4517 || (c
!=EOF
&& c
!=cur
[-1] && this->state
&STRINGBUF_no_write
))
4522 basic_streambuf_char_gbump(&this->base
, -1);
4523 return c
==EOF
? !EOF
: c
;
4526 /* ?underflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAEHXZ */
4527 /* ?underflow@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHXZ */
4528 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_underflow
, 4)
4529 int __thiscall
basic_stringbuf_char_underflow(basic_stringbuf_char
*this)
4533 TRACE("(%p)\n", this);
4535 cur
= basic_streambuf_char_gptr(&this->base
);
4536 if(!cur
|| this->state
&STRINGBUF_no_read
)
4539 ptr
= basic_streambuf_char_pptr(&this->base
);
4540 if(this->seekhigh
< ptr
)
4541 this->seekhigh
= ptr
;
4543 ptr
= basic_streambuf_char_egptr(&this->base
);
4544 if(this->seekhigh
> ptr
)
4545 basic_streambuf_char_setg(&this->base
, basic_streambuf_char_eback(&this->base
), cur
, this->seekhigh
);
4547 if(cur
< this->seekhigh
)
4548 return (unsigned char)*cur
;
4552 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
4553 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
4554 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4555 /* ?seekoff@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4556 #if STREAMOFF_BITS == 64
4557 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekoff
, 24)
4559 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekoff
, 20)
4561 fpos_mbstatet
* __thiscall
basic_stringbuf_char_seekoff(basic_stringbuf_char
*this,
4562 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
4564 char *beg
, *cur_r
, *cur_w
;
4566 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
4568 cur_w
= basic_streambuf_char_pptr(&this->base
);
4569 if(cur_w
> this->seekhigh
)
4570 this->seekhigh
= cur_w
;
4574 memset(&ret
->state
, 0, sizeof(ret
->state
));
4576 beg
= basic_streambuf_char_eback(&this->base
);
4577 cur_r
= basic_streambuf_char_gptr(&this->base
);
4578 if((mode
& OPENMODE_in
) && cur_r
) {
4579 if(way
==SEEKDIR_cur
&& !(mode
& OPENMODE_out
))
4581 else if(way
== SEEKDIR_end
)
4582 off
+= this->seekhigh
-beg
;
4583 else if(way
!= SEEKDIR_beg
)
4586 if(off
<0 || off
>this->seekhigh
-beg
) {
4589 basic_streambuf_char_gbump(&this->base
, beg
-cur_r
+off
);
4590 if((mode
& OPENMODE_out
) && cur_w
) {
4591 basic_streambuf_char_setp_next(&this->base
, beg
,
4592 basic_streambuf_char_gptr(&this->base
),
4593 basic_streambuf_char_epptr(&this->base
));
4596 }else if((mode
& OPENMODE_out
) && cur_w
) {
4597 if(way
== SEEKDIR_cur
)
4599 else if(way
== SEEKDIR_end
)
4600 off
+= this->seekhigh
-beg
;
4601 else if(way
!= SEEKDIR_beg
)
4604 if(off
<0 || off
>this->seekhigh
-beg
)
4607 basic_streambuf_char_pbump(&this->base
, beg
-cur_w
+off
);
4616 /* ?seekpos@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
4617 /* ?seekpos@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
4618 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_seekpos
, 36)
4619 fpos_mbstatet
* __thiscall
basic_stringbuf_char_seekpos(basic_stringbuf_char
*this,
4620 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
4622 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_mbstatet(&pos
), mode
);
4624 if(pos
.off
==-1 && pos
.pos
==0 && MBSTATET_TO_INT(&pos
.state
)==0) {
4629 return basic_stringbuf_char_seekoff(this, ret
, pos
.pos
+pos
.off
, SEEKDIR_beg
, mode
);
4632 /* ?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 */
4633 /* ?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 */
4634 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_str_set
, 8)
4635 void __thiscall
basic_stringbuf_char_str_set(basic_stringbuf_char
*this, const basic_string_char
*str
)
4637 TRACE("(%p %p)\n", this, str
);
4639 basic_stringbuf_char__Tidy(this);
4640 basic_stringbuf_char__Init(this, MSVCP_basic_string_char_c_str(str
), str
->size
, this->state
);
4643 /* ?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 */
4644 /* ?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 */
4645 DEFINE_THISCALL_WRAPPER(basic_stringbuf_char_str_get
, 8)
4646 basic_string_char
* __thiscall
basic_stringbuf_char_str_get(const basic_stringbuf_char
*this, basic_string_char
*ret
)
4650 TRACE("(%p)\n", this);
4652 if(!(this->state
& STRINGBUF_no_write
) && basic_streambuf_char_pptr(&this->base
)) {
4655 ptr
= basic_streambuf_char_pbase(&this->base
);
4656 pptr
= basic_streambuf_char_pptr(&this->base
);
4658 return MSVCP_basic_string_char_ctor_cstr_len(ret
, ptr
, (this->seekhigh
< pptr
? pptr
: this->seekhigh
) - ptr
);
4661 if(!(this->state
& STRINGBUF_no_read
) && basic_streambuf_char_gptr(&this->base
)) {
4662 ptr
= basic_streambuf_char_eback(&this->base
);
4663 return MSVCP_basic_string_char_ctor_cstr_len(ret
, ptr
, basic_streambuf_char_egptr(&this->base
) - ptr
);
4666 return MSVCP_basic_string_char_ctor(ret
);
4669 /* ?_Getstate@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@AAEHH@Z */
4670 /* ?_Getstate@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@AEAAHH@Z */
4671 /* ?_Getstate@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AAEHH@Z */
4672 /* ?_Getstate@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AEAAHH@Z */
4673 /* ?_Mode@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AAEHH@Z */
4674 /* ?_Mode@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@AEAAHH@Z */
4675 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Getstate
, 8)
4676 int __thiscall
basic_stringbuf_wchar__Getstate(basic_stringbuf_wchar
*this, IOSB_openmode mode
)
4680 if(!(mode
& OPENMODE_in
))
4681 state
|= STRINGBUF_no_read
;
4683 if(!(mode
& OPENMODE_out
))
4684 state
|= STRINGBUF_no_write
;
4686 if(mode
& OPENMODE_ate
)
4687 state
|= STRINGBUF_at_end
;
4689 if(mode
& OPENMODE_app
)
4690 state
|= STRINGBUF_append
;
4695 /* ?_Init@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEXPB_WIH@Z */
4696 /* ?_Init@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IEAAXPEB_W_KH@Z */
4697 /* ?_Init@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IAEXPBGIH@Z */
4698 /* ?_Init@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IEAAXPEBG_KH@Z */
4699 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Init
, 16)
4700 void __thiscall
basic_stringbuf_wchar__Init(basic_stringbuf_wchar
*this, const wchar_t *str
, size_t count
, int state
)
4702 TRACE("(%p, %p, %Iu, %d)\n", this, str
, count
, state
);
4704 basic_streambuf_wchar__Init_empty(&this->base
);
4706 this->state
= state
;
4707 this->seekhigh
= NULL
;
4710 wchar_t *buf
= MSVCRT_operator_new(count
*sizeof(wchar_t));
4712 ERR("Out of memory\n");
4713 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4716 memcpy(buf
, str
, count
*sizeof(wchar_t));
4717 this->seekhigh
= buf
+ count
;
4719 this->state
|= STRINGBUF_allocated
;
4721 if(!(state
& STRINGBUF_no_read
))
4722 basic_streambuf_wchar_setg(&this->base
, buf
, buf
, buf
+ count
);
4724 if(!(state
& STRINGBUF_no_write
)) {
4725 basic_streambuf_wchar_setp_next(&this->base
, buf
, (state
& STRINGBUF_at_end
) ? buf
+ count
: buf
, buf
+ count
);
4727 if(!basic_streambuf_wchar_gptr(&this->base
))
4728 basic_streambuf_wchar_setg(&this->base
, buf
, 0, buf
);
4733 /* ??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 */
4734 /* ??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 */
4735 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor_str
, 12)
4736 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_ctor_str(basic_stringbuf_wchar
*this,
4737 const basic_string_wchar
*str
, IOSB_openmode mode
)
4739 TRACE("(%p %p %d)\n", this, str
, mode
);
4741 basic_streambuf_wchar_ctor(&this->base
);
4742 this->base
.vtable
= &MSVCP_basic_stringbuf_wchar_vtable
;
4744 basic_stringbuf_wchar__Init(this, MSVCP_basic_string_wchar_c_str(str
),
4745 str
->size
, basic_stringbuf_wchar__Getstate(this, mode
));
4749 /* ??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 */
4750 /* ??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 */
4751 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor_str
, 12)
4752 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_short_ctor_str(basic_stringbuf_wchar
*this,
4753 const basic_string_wchar
*str
, IOSB_openmode mode
)
4755 basic_stringbuf_wchar_ctor_str(this, str
, mode
);
4756 this->base
.vtable
= &MSVCP_basic_stringbuf_short_vtable
;
4760 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
4761 /* ??0?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
4762 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor_mode
, 8)
4763 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_ctor_mode(
4764 basic_stringbuf_wchar
*this, IOSB_openmode mode
)
4766 TRACE("(%p %d)\n", this, mode
);
4768 basic_streambuf_wchar_ctor(&this->base
);
4769 this->base
.vtable
= &MSVCP_basic_stringbuf_wchar_vtable
;
4771 basic_stringbuf_wchar__Init(this, NULL
, 0, basic_stringbuf_wchar__Getstate(this, mode
));
4775 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
4776 /* ??0?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
4777 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor_mode
, 8)
4778 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_short_ctor_mode(
4779 basic_stringbuf_wchar
*this, IOSB_openmode mode
)
4781 basic_stringbuf_wchar_ctor_mode(this, mode
);
4782 this->base
.vtable
= &MSVCP_basic_stringbuf_short_vtable
;
4786 /* ??_F?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
4787 /* ??_F?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
4788 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_ctor
, 4)
4789 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_ctor(basic_stringbuf_wchar
*this)
4791 return basic_stringbuf_wchar_ctor_mode(this, OPENMODE_in
|OPENMODE_out
);
4794 /* ??_F?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
4795 /* ??_F?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
4796 DEFINE_THISCALL_WRAPPER(basic_stringbuf_short_ctor
, 4)
4797 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_short_ctor(basic_stringbuf_wchar
*this)
4799 return basic_stringbuf_short_ctor_mode(this, OPENMODE_in
|OPENMODE_out
);
4802 /* ?_Tidy@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IAEXXZ */
4803 /* ?_Tidy@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@IEAAXXZ */
4804 /* ?_Tidy@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IAEXXZ */
4805 /* ?_Tidy@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@IEAAXXZ */
4806 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar__Tidy
, 4)
4807 void __thiscall
basic_stringbuf_wchar__Tidy(basic_stringbuf_wchar
*this)
4809 TRACE("(%p)\n", this);
4811 if(this->state
& STRINGBUF_allocated
) {
4812 MSVCRT_operator_delete(basic_streambuf_wchar_eback(&this->base
));
4813 this->seekhigh
= NULL
;
4814 this->state
&= ~STRINGBUF_allocated
;
4817 basic_streambuf_wchar__Init_empty(&this->base
);
4820 /* ??1?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
4821 /* ??1?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
4822 /* ??1?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
4823 /* ??1?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
4824 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_dtor
, 4)
4825 void __thiscall
basic_stringbuf_wchar_dtor(basic_stringbuf_wchar
*this)
4827 TRACE("(%p)\n", this);
4829 basic_stringbuf_wchar__Tidy(this);
4830 basic_streambuf_wchar_dtor(&this->base
);
4833 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_vector_dtor
, 8)
4834 basic_stringbuf_wchar
* __thiscall
basic_stringbuf_wchar_vector_dtor(basic_stringbuf_wchar
*this, unsigned int flags
)
4836 TRACE("(%p %x)\n", this, flags
);
4839 /* we have an array, with the number of elements stored before the first object */
4840 INT_PTR i
, *ptr
= (INT_PTR
*) this - 1;
4842 for (i
= *ptr
- 1; i
>= 0; i
--)
4843 basic_stringbuf_wchar_dtor(this+i
);
4845 MSVCRT_operator_delete(ptr
);
4847 basic_stringbuf_wchar_dtor(this);
4850 MSVCRT_operator_delete(this);
4856 /* ?overflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGG@Z */
4857 /* ?overflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGG@Z */
4858 /* ?overflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGG@Z */
4859 /* ?overflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGG@Z */
4860 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_overflow
, 8)
4861 unsigned short __thiscall
basic_stringbuf_wchar_overflow(basic_stringbuf_wchar
*this, unsigned short meta
)
4863 size_t oldsize
, size
;
4866 TRACE("(%p %x)\n", this, meta
);
4870 if(this->state
& STRINGBUF_no_write
)
4873 ptr
= basic_streambuf_wchar_pptr(&this->base
);
4874 if((this->state
&STRINGBUF_append
) && ptr
<this->seekhigh
)
4875 basic_streambuf_wchar_setp_next(&this->base
, basic_streambuf_wchar_pbase(&this->base
),
4876 this->seekhigh
, basic_streambuf_wchar_epptr(&this->base
));
4878 if(ptr
&& ptr
<basic_streambuf_wchar_epptr(&this->base
))
4879 return (*basic_streambuf_wchar__Pninc(&this->base
) = meta
);
4881 oldsize
= (ptr
? basic_streambuf_wchar_epptr(&this->base
)-basic_streambuf_wchar_eback(&this->base
): 0);
4884 buf
= MSVCRT_operator_new(size
*sizeof(wchar_t));
4886 ERR("Out of memory\n");
4887 throw_exception(EXCEPTION_BAD_ALLOC
, NULL
);
4891 this->seekhigh
= buf
;
4892 basic_streambuf_wchar_setp(&this->base
, buf
, buf
+size
);
4893 if(this->state
& STRINGBUF_no_read
)
4894 basic_streambuf_wchar_setg(&this->base
, buf
, NULL
, buf
);
4896 basic_streambuf_wchar_setg(&this->base
, buf
, buf
, buf
+1);
4898 this->state
|= STRINGBUF_allocated
;
4900 ptr
= basic_streambuf_wchar_eback(&this->base
);
4901 memcpy(buf
, ptr
, oldsize
*sizeof(wchar_t));
4903 this->seekhigh
= buf
+(this->seekhigh
-ptr
);
4904 basic_streambuf_wchar_setp_next(&this->base
, buf
,
4905 buf
+(basic_streambuf_wchar_pptr(&this->base
)-ptr
), buf
+size
);
4906 if(this->state
& STRINGBUF_no_read
)
4907 basic_streambuf_wchar_setg(&this->base
, buf
, NULL
, buf
);
4909 basic_streambuf_wchar_setg(&this->base
, buf
,
4910 buf
+(basic_streambuf_wchar_gptr(&this->base
)-ptr
),
4911 basic_streambuf_wchar_pptr(&this->base
)+1);
4913 MSVCRT_operator_delete(ptr
);
4916 return (*basic_streambuf_wchar__Pninc(&this->base
) = meta
);
4919 /* ?pbackfail@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGG@Z */
4920 /* ?pbackfail@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGG@Z */
4921 /* ?pbackfail@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGG@Z */
4922 /* ?pbackfail@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGG@Z */
4923 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_pbackfail
, 8)
4924 unsigned short __thiscall
basic_stringbuf_wchar_pbackfail(basic_stringbuf_wchar
*this, unsigned short c
)
4928 TRACE("(%p %x)\n", this, c
);
4930 cur
= basic_streambuf_wchar_gptr(&this->base
);
4931 if(!cur
|| cur
==basic_streambuf_wchar_eback(&this->base
)
4932 || (c
!=WEOF
&& c
!=cur
[-1] && this->state
&STRINGBUF_no_write
))
4937 basic_streambuf_wchar_gbump(&this->base
, -1);
4938 return c
==WEOF
? !WEOF
: c
;
4941 /* ?underflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAEGXZ */
4942 /* ?underflow@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAAGXZ */
4943 /* ?underflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAEGXZ */
4944 /* ?underflow@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAAGXZ */
4945 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_underflow
, 4)
4946 unsigned short __thiscall
basic_stringbuf_wchar_underflow(basic_stringbuf_wchar
*this)
4950 TRACE("(%p)\n", this);
4952 cur
= basic_streambuf_wchar_gptr(&this->base
);
4953 if(!cur
|| this->state
&STRINGBUF_no_read
)
4956 ptr
= basic_streambuf_wchar_pptr(&this->base
);
4957 if(this->seekhigh
< ptr
)
4958 this->seekhigh
= ptr
;
4960 ptr
= basic_streambuf_wchar_egptr(&this->base
);
4961 if(this->seekhigh
> ptr
)
4962 basic_streambuf_wchar_setg(&this->base
, basic_streambuf_wchar_eback(&this->base
), cur
, this->seekhigh
);
4964 if(cur
< this->seekhigh
)
4969 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
4970 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
4971 /* ?seekoff@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4972 /* ?seekoff@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4973 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@JHH@Z */
4974 /* ?seekoff@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
4975 #if STREAMOFF_BITS == 64
4976 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekoff
, 24)
4978 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekoff
, 20)
4980 fpos_mbstatet
* __thiscall
basic_stringbuf_wchar_seekoff(basic_stringbuf_wchar
*this,
4981 fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
4983 wchar_t *beg
, *cur_r
, *cur_w
;
4985 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
4987 cur_w
= basic_streambuf_wchar_pptr(&this->base
);
4988 if(cur_w
> this->seekhigh
)
4989 this->seekhigh
= cur_w
;
4993 memset(&ret
->state
, 0, sizeof(ret
->state
));
4995 beg
= basic_streambuf_wchar_eback(&this->base
);
4996 cur_r
= basic_streambuf_wchar_gptr(&this->base
);
4997 if((mode
& OPENMODE_in
) && cur_r
) {
4998 if(way
==SEEKDIR_cur
&& !(mode
& OPENMODE_out
))
5000 else if(way
== SEEKDIR_end
)
5001 off
+= this->seekhigh
-beg
;
5002 else if(way
!= SEEKDIR_beg
)
5005 if(off
<0 || off
>this->seekhigh
-beg
) {
5008 basic_streambuf_wchar_gbump(&this->base
, beg
-cur_r
+off
);
5009 if((mode
& OPENMODE_out
) && cur_w
) {
5010 basic_streambuf_wchar_setp_next(&this->base
, beg
,
5011 basic_streambuf_wchar_gptr(&this->base
),
5012 basic_streambuf_wchar_epptr(&this->base
));
5015 }else if((mode
& OPENMODE_out
) && cur_w
) {
5016 if(way
== SEEKDIR_cur
)
5018 else if(way
== SEEKDIR_end
)
5019 off
+= this->seekhigh
-beg
;
5020 else if(way
!= SEEKDIR_beg
)
5023 if(off
<0 || off
>this->seekhigh
-beg
)
5026 basic_streambuf_wchar_pbump(&this->base
, beg
-cur_w
+off
);
5035 /* ?seekpos@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
5036 /* ?seekpos@?$basic_stringbuf@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
5037 /* ?seekpos@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MAE?AV?$fpos@H@2@V32@H@Z */
5038 /* ?seekpos@?$basic_stringbuf@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
5039 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_seekpos
, 36)
5040 fpos_mbstatet
* __thiscall
basic_stringbuf_wchar_seekpos(basic_stringbuf_wchar
*this,
5041 fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
5043 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_mbstatet(&pos
), mode
);
5045 if(pos
.off
==-1 && pos
.pos
==0 && MBSTATET_TO_INT(&pos
.state
)==0) {
5050 return basic_stringbuf_wchar_seekoff(this, ret
, pos
.pos
+pos
.off
, SEEKDIR_beg
, mode
);
5053 /* ?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 */
5054 /* ?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 */
5055 /* ?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 */
5056 /* ?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 */
5057 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_str_set
, 8)
5058 void __thiscall
basic_stringbuf_wchar_str_set(basic_stringbuf_wchar
*this, const basic_string_wchar
*str
)
5060 TRACE("(%p %p)\n", this, str
);
5062 basic_stringbuf_wchar__Tidy(this);
5063 basic_stringbuf_wchar__Init(this, MSVCP_basic_string_wchar_c_str(str
), str
->size
, this->state
);
5066 /* ?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 */
5067 /* ?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 */
5068 /* ?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 */
5069 /* ?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 */
5070 DEFINE_THISCALL_WRAPPER(basic_stringbuf_wchar_str_get
, 8)
5071 basic_string_wchar
* __thiscall
basic_stringbuf_wchar_str_get(const basic_stringbuf_wchar
*this, basic_string_wchar
*ret
)
5075 TRACE("(%p)\n", this);
5077 if(!(this->state
& STRINGBUF_no_write
) && basic_streambuf_wchar_pptr(&this->base
)) {
5080 ptr
= basic_streambuf_wchar_pbase(&this->base
);
5081 pptr
= basic_streambuf_wchar_pptr(&this->base
);
5083 return MSVCP_basic_string_wchar_ctor_cstr_len(ret
, ptr
, (this->seekhigh
< pptr
? pptr
: this->seekhigh
) - ptr
);
5086 if(!(this->state
& STRINGBUF_no_read
) && basic_streambuf_wchar_gptr(&this->base
)) {
5087 ptr
= basic_streambuf_wchar_eback(&this->base
);
5088 return MSVCP_basic_string_wchar_ctor_cstr_len(ret
, ptr
, basic_streambuf_wchar_egptr(&this->base
) - ptr
);
5091 return MSVCP_basic_string_wchar_ctor(ret
);
5094 /* ??0ios_base@std@@IAE@XZ */
5095 /* ??0ios_base@std@@IEAA@XZ */
5096 DEFINE_THISCALL_WRAPPER(ios_base_ctor
, 4)
5097 ios_base
* __thiscall
ios_base_ctor(ios_base
*this)
5099 TRACE("(%p)\n", this);
5100 this->vtable
= &MSVCP_ios_base_vtable
;
5104 /* ??0ios_base@std@@QAE@ABV01@@Z */
5105 /* ??0ios_base@std@@QEAA@AEBV01@@Z */
5106 DEFINE_THISCALL_WRAPPER(ios_base_copy_ctor
, 8)
5107 ios_base
* __thiscall
ios_base_copy_ctor(ios_base
*this, const ios_base
*copy
)
5109 TRACE("(%p %p)\n", this, copy
);
5111 this->vtable
= &MSVCP_ios_base_vtable
;
5115 /* ?_Callfns@ios_base@std@@AAEXW4event@12@@Z */
5116 /* ?_Callfns@ios_base@std@@AEAAXW4event@12@@Z */
5117 DEFINE_THISCALL_WRAPPER(ios_base_Callfns
, 8)
5118 void __thiscall
ios_base_Callfns(ios_base
*this, IOS_BASE_event event
)
5120 IOS_BASE_fnarray
*cur
;
5122 TRACE("(%p %x)\n", this, event
);
5124 for(cur
=this->calls
; cur
; cur
=cur
->next
)
5125 cur
->event_handler(event
, this, cur
->index
);
5128 /* ?_Tidy@ios_base@std@@AAAXXZ */
5129 /* ?_Tidy@ios_base@std@@AEAAXXZ */
5130 void __cdecl
ios_base_Tidy(ios_base
*this)
5132 IOS_BASE_iosarray
*arr_cur
, *arr_next
;
5133 IOS_BASE_fnarray
*event_cur
, *event_next
;
5135 TRACE("(%p)\n", this);
5137 ios_base_Callfns(this, EVENT_erase_event
);
5139 for(arr_cur
=this->arr
; arr_cur
; arr_cur
=arr_next
) {
5140 arr_next
= arr_cur
->next
;
5141 MSVCRT_operator_delete(arr_cur
);
5145 for(event_cur
=this->calls
; event_cur
; event_cur
=event_next
) {
5146 event_next
= event_cur
->next
;
5147 MSVCRT_operator_delete(event_cur
);
5152 /* ?_Ios_base_dtor@ios_base@std@@CAXPAV12@@Z */
5153 /* ?_Ios_base_dtor@ios_base@std@@CAXPEAV12@@Z */
5154 void __cdecl
ios_base_Ios_base_dtor(ios_base
*obj
)
5156 TRACE("(%p)\n", obj
);
5157 locale_dtor(IOS_LOCALE(obj
));
5158 #if _MSVCP_VER >= 70
5159 MSVCRT_operator_delete(obj
->loc
);
5164 /* ??1ios_base@std@@UAE@XZ */
5165 /* ??1ios_base@std@@UEAA@XZ */
5166 DEFINE_THISCALL_WRAPPER(ios_base_dtor
, 4)
5167 void __thiscall
ios_base_dtor(ios_base
*this)
5169 ios_base_Ios_base_dtor(this);
5172 DEFINE_THISCALL_WRAPPER(ios_base_vector_dtor
, 8)
5173 ios_base
* __thiscall
ios_base_vector_dtor(ios_base
*this, unsigned int flags
)
5175 TRACE("(%p %x)\n", this, flags
);
5177 /* we have an array, with the number of elements stored before the first object */
5178 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
5180 for(i
=*ptr
-1; i
>=0; i
--)
5181 ios_base_dtor(this+i
);
5182 MSVCRT_operator_delete(ptr
);
5184 ios_base_dtor(this);
5186 MSVCRT_operator_delete(this);
5192 DEFINE_THISCALL_WRAPPER(iosb_vector_dtor
, 8)
5193 void* __thiscall
iosb_vector_dtor(void *this, unsigned int flags
)
5195 TRACE("(%p %x)\n", this, flags
);
5197 INT_PTR
*ptr
= (INT_PTR
*)this-1;
5198 MSVCRT_operator_delete(ptr
);
5201 MSVCRT_operator_delete(this);
5207 /* ?_Findarr@ios_base@std@@AAEAAU_Iosarray@12@H@Z */
5208 /* ?_Findarr@ios_base@std@@AEAAAEAU_Iosarray@12@H@Z */
5209 DEFINE_THISCALL_WRAPPER(ios_base_Findarr
, 8)
5210 IOS_BASE_iosarray
* __thiscall
ios_base_Findarr(ios_base
*this, int index
)
5212 IOS_BASE_iosarray
*p
;
5214 TRACE("(%p %d)\n", this, index
);
5216 for(p
=this->arr
; p
; p
=p
->next
) {
5217 if(p
->index
== index
)
5221 for(p
=this->arr
; p
; p
=p
->next
) {
5222 if(!p
->long_val
&& !p
->ptr_val
) {
5228 p
= MSVCRT_operator_new(sizeof(IOS_BASE_iosarray
));
5229 p
->next
= this->arr
;
5237 /* ?iword@ios_base@std@@QAEAAJH@Z */
5238 /* ?iword@ios_base@std@@QEAAAEAJH@Z */
5239 DEFINE_THISCALL_WRAPPER(ios_base_iword
, 8)
5240 LONG
* __thiscall
ios_base_iword(ios_base
*this, int index
)
5242 TRACE("(%p %d)\n", this, index
);
5243 return &ios_base_Findarr(this, index
)->long_val
;
5246 /* ?pword@ios_base@std@@QAEAAPAXH@Z */
5247 /* ?pword@ios_base@std@@QEAAAEAPEAXH@Z */
5248 DEFINE_THISCALL_WRAPPER(ios_base_pword
, 8)
5249 void** __thiscall
ios_base_pword(ios_base
*this, int index
)
5251 TRACE("(%p %d)\n", this, index
);
5252 return &ios_base_Findarr(this, index
)->ptr_val
;
5255 /* ?register_callback@ios_base@std@@QAEXP6AXW4event@12@AAV12@H@ZH@Z */
5256 /* ?register_callback@ios_base@std@@QEAAXP6AXW4event@12@AEAV12@H@ZH@Z */
5257 DEFINE_THISCALL_WRAPPER(ios_base_register_callback
, 12)
5258 void __thiscall
ios_base_register_callback(ios_base
*this, IOS_BASE_event_callback callback
, int index
)
5260 IOS_BASE_fnarray
*event
;
5262 TRACE("(%p %p %d)\n", this, callback
, index
);
5264 event
= MSVCRT_operator_new(sizeof(IOS_BASE_fnarray
));
5265 event
->next
= this->calls
;
5266 event
->index
= index
;
5267 event
->event_handler
= callback
;
5268 this->calls
= event
;
5271 /* ?clear@ios_base@std@@QAEXH_N@Z */
5272 /* ?clear@ios_base@std@@QEAAXH_N@Z */
5273 DEFINE_THISCALL_WRAPPER(ios_base_clear_reraise
, 12)
5274 void __thiscall
ios_base_clear_reraise(ios_base
*this, IOSB_iostate state
, bool reraise
)
5276 TRACE("(%p %x %x)\n", this, state
, reraise
);
5278 this->state
= state
& IOSTATE_mask
;
5279 if(!(this->state
& this->except
))
5283 throw_exception(EXCEPTION_RERAISE
, NULL
);
5284 else if(this->state
& this->except
& IOSTATE_eofbit
)
5285 throw_exception(EXCEPTION_FAILURE
, "eofbit is set");
5286 else if(this->state
& this->except
& IOSTATE_failbit
)
5287 throw_exception(EXCEPTION_FAILURE
, "failbit is set");
5288 else if(this->state
& this->except
& IOSTATE_badbit
)
5289 throw_exception(EXCEPTION_FAILURE
, "badbit is set");
5290 else if(this->state
& this->except
& IOSTATE__Hardfail
)
5291 throw_exception(EXCEPTION_FAILURE
, "_Hardfail is set");
5294 /* ?clear@ios_base@std@@QAEXH@Z */
5295 /* ?clear@ios_base@std@@QEAAXH@Z */
5296 DEFINE_THISCALL_WRAPPER(ios_base_clear
, 8)
5297 void __thiscall
ios_base_clear(ios_base
*this, IOSB_iostate state
)
5299 ios_base_clear_reraise(this, state
, FALSE
);
5302 /* ?clear@ios_base@std@@QAEXI@Z */
5303 /* ?clear@ios_base@std@@QEAAXI@Z */
5304 DEFINE_THISCALL_WRAPPER(ios_base_clear_unsigned
, 8)
5305 void __thiscall
ios_base_clear_unsigned(ios_base
*this, unsigned int state
)
5307 ios_base_clear_reraise(this, (IOSB_iostate
)state
, FALSE
);
5310 /* ?exceptions@ios_base@std@@QAEXH@Z */
5311 /* ?exceptions@ios_base@std@@QEAAXH@Z */
5312 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_set
, 8)
5313 void __thiscall
ios_base_exceptions_set(ios_base
*this, IOSB_iostate state
)
5315 TRACE("(%p %x)\n", this, state
);
5316 this->except
= state
& IOSTATE_mask
;
5317 ios_base_clear(this, this->state
);
5320 /* ?exceptions@ios_base@std@@QAEXI@Z */
5321 /* ?exceptions@ios_base@std@@QEAAXI@Z */
5322 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_set_unsigned
, 8)
5323 void __thiscall
ios_base_exceptions_set_unsigned(ios_base
*this, unsigned int state
)
5325 TRACE("(%p %x)\n", this, state
);
5326 ios_base_exceptions_set(this, state
);
5329 /* ?exceptions@ios_base@std@@QBEHXZ */
5330 /* ?exceptions@ios_base@std@@QEBAHXZ */
5331 DEFINE_THISCALL_WRAPPER(ios_base_exceptions_get
, 4)
5332 IOSB_iostate __thiscall
ios_base_exceptions_get(ios_base
*this)
5334 TRACE("(%p)\n", this);
5335 return this->except
;
5338 /* ?copyfmt@ios_base@std@@QAEAAV12@ABV12@@Z */
5339 /* ?copyfmt@ios_base@std@@QEAAAEAV12@AEBV12@@Z */
5340 DEFINE_THISCALL_WRAPPER(ios_base_copyfmt
, 8)
5341 ios_base
* __thiscall
ios_base_copyfmt(ios_base
*this, const ios_base
*rhs
)
5343 TRACE("(%p %p)\n", this, rhs
);
5346 IOS_BASE_iosarray
*arr_cur
;
5347 IOS_BASE_fnarray
*event_cur
;
5349 ios_base_Tidy(this);
5351 for(arr_cur
=rhs
->arr
; arr_cur
; arr_cur
=arr_cur
->next
) {
5352 if(arr_cur
->long_val
)
5353 *ios_base_iword(this, arr_cur
->index
) = arr_cur
->long_val
;
5354 if(arr_cur
->ptr_val
)
5355 *ios_base_pword(this, arr_cur
->index
) = arr_cur
->ptr_val
;
5357 this->stdstr
= rhs
->stdstr
;
5358 this->fmtfl
= rhs
->fmtfl
;
5359 this->prec
= rhs
->prec
;
5360 this->wide
= rhs
->wide
;
5361 locale_operator_assign(IOS_LOCALE(this), IOS_LOCALE(rhs
));
5363 for(event_cur
=rhs
->calls
; event_cur
; event_cur
=event_cur
->next
)
5364 ios_base_register_callback(this, event_cur
->event_handler
, event_cur
->index
);
5366 ios_base_Callfns(this, EVENT_copyfmt_event
);
5367 ios_base_exceptions_set(this, rhs
->except
);
5373 /* ??4ios_base@std@@QAEAAV01@ABV01@@Z */
5374 /* ??4ios_base@std@@QEAAAEAV01@AEBV01@@Z */
5375 DEFINE_THISCALL_WRAPPER(ios_base_assign
, 8)
5376 ios_base
* __thiscall
ios_base_assign(ios_base
*this, const ios_base
*right
)
5378 TRACE("(%p %p)\n", this, right
);
5381 this->state
= right
->state
;
5382 ios_base_copyfmt(this, right
);
5388 /* ?fail@ios_base@std@@QBE_NXZ */
5389 /* ?fail@ios_base@std@@QEBA_NXZ */
5390 DEFINE_THISCALL_WRAPPER(ios_base_fail
, 4)
5391 bool __thiscall
ios_base_fail(const ios_base
*this)
5393 TRACE("(%p)\n", this);
5394 return (this->state
& (IOSTATE_failbit
|IOSTATE_badbit
)) != 0;
5397 /* ??7ios_base@std@@QBE_NXZ */
5398 /* ??7ios_base@std@@QEBA_NXZ */
5399 DEFINE_THISCALL_WRAPPER(ios_base_op_succ
, 4)
5400 bool __thiscall
ios_base_op_succ(const ios_base
*this)
5402 TRACE("(%p)\n", this);
5403 return ios_base_fail(this);
5406 /* ??Bios_base@std@@QBEPAXXZ */
5407 /* ??Bios_base@std@@QEBAPEAXXZ */
5408 DEFINE_THISCALL_WRAPPER(ios_base_op_fail
, 4)
5409 void* __thiscall
ios_base_op_fail(const ios_base
*this)
5411 TRACE("(%p)\n", this);
5412 return ios_base_fail(this) ? NULL
: (void*)this;
5415 /* ??Bios_base@std@@QBA_NXZ */
5416 /* ??Bios_base@std@@QBE_NXZ */
5417 /* ??Bios_base@std@@QEBA_NXZ */
5418 DEFINE_THISCALL_WRAPPER(ios_base_operator_bool
, 4)
5419 bool __thiscall
ios_base_operator_bool(const ios_base
*this)
5421 TRACE("(%p)\n", this);
5422 return (this->state
& (IOSTATE_failbit
|IOSTATE_badbit
)) == 0;
5425 /* ?_Addstd@ios_base@std@@SAXPAV12@@Z */
5426 /* ?_Addstd@ios_base@std@@SAXPEAV12@@Z */
5427 void __cdecl
ios_base_Addstd(ios_base
*add
)
5429 FIXME("(%p) stub\n", add
);
5432 /* ?_Index_func@ios_base@std@@CAAAHXZ */
5433 /* ?_Index_func@ios_base@std@@CAAEAHXZ */
5434 int* __cdecl
ios_base_Index_func(void)
5437 return &ios_base_Index
;
5440 /* ?_Init@ios_base@std@@IAEXXZ */
5441 /* ?_Init@ios_base@std@@IEAAXXZ */
5442 DEFINE_THISCALL_WRAPPER(ios_base__Init
, 4)
5443 void __thiscall
ios_base__Init(ios_base
*this)
5445 TRACE("(%p)\n", this);
5448 this->state
= this->except
= IOSTATE_goodbit
;
5449 this->fmtfl
= FMTFLAG_skipws
| FMTFLAG_dec
;
5454 #if _MSVCP_VER >= 70
5455 this->loc
= MSVCRT_operator_new(sizeof(locale
));
5457 locale_ctor(IOS_LOCALE(this));
5460 /* ?_Sync_func@ios_base@std@@CAAA_NXZ */
5461 /* ?_Sync_func@ios_base@std@@CAAEA_NXZ */
5462 bool* __cdecl
ios_base_Sync_func(void)
5465 return &ios_base_Sync
;
5468 /* ?bad@ios_base@std@@QBE_NXZ */
5469 /* ?bad@ios_base@std@@QEBA_NXZ */
5470 DEFINE_THISCALL_WRAPPER(ios_base_bad
, 4)
5471 bool __thiscall
ios_base_bad(const ios_base
*this)
5473 TRACE("(%p)\n", this);
5474 return (this->state
& IOSTATE_badbit
) != 0;
5477 /* ?eof@ios_base@std@@QBE_NXZ */
5478 /* ?eof@ios_base@std@@QEBA_NXZ */
5479 DEFINE_THISCALL_WRAPPER(ios_base_eof
, 4)
5480 bool __thiscall
ios_base_eof(const ios_base
*this)
5482 TRACE("(%p)\n", this);
5483 return (this->state
& IOSTATE_eofbit
) != 0;
5486 /* ?flags@ios_base@std@@QAEHH@Z */
5487 /* ?flags@ios_base@std@@QEAAHH@Z */
5488 DEFINE_THISCALL_WRAPPER(ios_base_flags_set
, 8)
5489 IOSB_fmtflags __thiscall
ios_base_flags_set(ios_base
*this, IOSB_fmtflags flags
)
5491 IOSB_fmtflags ret
= this->fmtfl
;
5493 TRACE("(%p %x)\n", this, flags
);
5495 this->fmtfl
= flags
& FMTFLAG_mask
;
5499 /* ?flags@ios_base@std@@QBEHXZ */
5500 /* ?flags@ios_base@std@@QEBAHXZ */
5501 DEFINE_THISCALL_WRAPPER(ios_base_flags_get
, 4)
5502 IOSB_fmtflags __thiscall
ios_base_flags_get(const ios_base
*this)
5504 TRACE("(%p)\n", this);
5508 /* ?getloc@ios_base@std@@QBE?AVlocale@2@XZ */
5509 /* ?getloc@ios_base@std@@QEBA?AVlocale@2@XZ */
5510 DEFINE_THISCALL_WRAPPER(ios_base_getloc
, 8)
5511 locale
* __thiscall
ios_base_getloc(const ios_base
*this, locale
*ret
)
5513 TRACE("(%p)\n", this);
5514 return locale_copy_ctor(ret
, IOS_LOCALE(this));
5517 /* ?good@ios_base@std@@QBE_NXZ */
5518 /* ?good@ios_base@std@@QEBA_NXZ */
5519 DEFINE_THISCALL_WRAPPER(ios_base_good
, 4)
5520 bool __thiscall
ios_base_good(const ios_base
*this)
5522 TRACE("(%p)\n", this);
5523 return this->state
== IOSTATE_goodbit
;
5526 /* ?imbue@ios_base@std@@QAE?AVlocale@2@ABV32@@Z */
5527 /* ?imbue@ios_base@std@@QEAA?AVlocale@2@AEBV32@@Z */
5528 DEFINE_THISCALL_WRAPPER(ios_base_imbue
, 12)
5529 locale
* __thiscall
ios_base_imbue(ios_base
*this, locale
*ret
, const locale
*loc
)
5531 TRACE("(%p %p)\n", this, loc
);
5532 *ret
= *IOS_LOCALE(this);
5533 locale_copy_ctor(IOS_LOCALE(this), loc
);
5537 /* ?precision@ios_base@std@@QAEHH@Z */
5538 /* ?precision@ios_base@std@@QEAA_J_J@Z */
5539 #if STREAMSIZE_BITS == 64
5540 DEFINE_THISCALL_WRAPPER(ios_base_precision_set
, 12)
5542 DEFINE_THISCALL_WRAPPER(ios_base_precision_set
, 8)
5544 streamsize __thiscall
ios_base_precision_set(ios_base
*this, streamsize precision
)
5546 streamsize ret
= this->prec
;
5548 TRACE("(%p %s)\n", this, wine_dbgstr_longlong(precision
));
5550 this->prec
= precision
;
5554 /* ?precision@ios_base@std@@QBEHXZ */
5555 /* ?precision@ios_base@std@@QEBA_JXZ */
5556 DEFINE_THISCALL_WRAPPER(ios_base_precision_get
, 4)
5557 streamsize __thiscall
ios_base_precision_get(const ios_base
*this)
5559 TRACE("(%p)\n", this);
5563 /* ?rdstate@ios_base@std@@QBEHXZ */
5564 /* ?rdstate@ios_base@std@@QEBAHXZ */
5565 DEFINE_THISCALL_WRAPPER(ios_base_rdstate
, 4)
5566 IOSB_iostate __thiscall
ios_base_rdstate(const ios_base
*this)
5568 TRACE("(%p)\n", this);
5572 /* ?setf@ios_base@std@@QAEHHH@Z */
5573 /* ?setf@ios_base@std@@QEAAHHH@Z */
5574 DEFINE_THISCALL_WRAPPER(ios_base_setf_mask
, 12)
5575 IOSB_fmtflags __thiscall
ios_base_setf_mask(ios_base
*this, IOSB_fmtflags flags
, IOSB_fmtflags mask
)
5577 IOSB_fmtflags ret
= this->fmtfl
;
5579 TRACE("(%p %x %x)\n", this, flags
, mask
);
5581 this->fmtfl
= (this->fmtfl
& (~mask
)) | (flags
& mask
& FMTFLAG_mask
);
5585 /* ?setf@ios_base@std@@QAEHH@Z */
5586 /* ?setf@ios_base@std@@QEAAHH@Z */
5587 DEFINE_THISCALL_WRAPPER(ios_base_setf
, 8)
5588 IOSB_fmtflags __thiscall
ios_base_setf(ios_base
*this, IOSB_fmtflags flags
)
5590 IOSB_fmtflags ret
= this->fmtfl
;
5592 TRACE("(%p %x)\n", this, flags
);
5594 this->fmtfl
|= flags
& FMTFLAG_mask
;
5598 /* ?setstate@ios_base@std@@QAEXH_N@Z */
5599 /* ?setstate@ios_base@std@@QEAAXH_N@Z */
5600 DEFINE_THISCALL_WRAPPER(ios_base_setstate_reraise
, 12)
5601 void __thiscall
ios_base_setstate_reraise(ios_base
*this, IOSB_iostate state
, bool reraise
)
5603 TRACE("(%p %x %x)\n", this, state
, reraise
);
5605 if(state
!= IOSTATE_goodbit
)
5606 ios_base_clear_reraise(this, this->state
| state
, reraise
);
5609 /* ?setstate@ios_base@std@@QAEXH@Z */
5610 /* ?setstate@ios_base@std@@QEAAXH@Z */
5611 DEFINE_THISCALL_WRAPPER(ios_base_setstate
, 8)
5612 void __thiscall
ios_base_setstate(ios_base
*this, IOSB_iostate state
)
5614 ios_base_setstate_reraise(this, state
, FALSE
);
5617 /* ?setstate@ios_base@std@@QAEXI@Z */
5618 /* ?setstate@ios_base@std@@QEAAXI@Z */
5619 DEFINE_THISCALL_WRAPPER(ios_base_setstate_unsigned
, 8)
5620 void __thiscall
ios_base_setstate_unsigned(ios_base
*this, unsigned int state
)
5622 ios_base_setstate_reraise(this, (IOSB_iostate
)state
, FALSE
);
5625 /* ?sync_with_stdio@ios_base@std@@SA_N_N@Z */
5626 bool __cdecl
ios_base_sync_with_stdio(bool sync
)
5631 TRACE("(%x)\n", sync
);
5633 _Lockit_ctor_locktype(&lock
, _LOCK_STREAM
);
5634 ret
= ios_base_Sync
;
5635 ios_base_Sync
= sync
;
5636 _Lockit_dtor(&lock
);
5640 /* ?unsetf@ios_base@std@@QAEXH@Z */
5641 /* ?unsetf@ios_base@std@@QEAAXH@Z */
5642 DEFINE_THISCALL_WRAPPER(ios_base_unsetf
, 8)
5643 void __thiscall
ios_base_unsetf(ios_base
*this, IOSB_fmtflags flags
)
5645 TRACE("(%p %x)\n", this, flags
);
5646 this->fmtfl
&= ~flags
;
5649 /* ?width@ios_base@std@@QAEHH@Z */
5650 /* ?width@ios_base@std@@QEAA_J_J@Z */
5651 #if STREAMSIZE_BITS == 64
5652 DEFINE_THISCALL_WRAPPER(ios_base_width_set
, 12)
5654 DEFINE_THISCALL_WRAPPER(ios_base_width_set
, 8)
5656 streamsize __thiscall
ios_base_width_set(ios_base
*this, streamsize width
)
5658 streamsize ret
= this->wide
;
5660 TRACE("(%p %s)\n", this, wine_dbgstr_longlong(width
));
5666 /* ?width@ios_base@std@@QBEHXZ */
5667 /* ?width@ios_base@std@@QEBA_JXZ */
5668 DEFINE_THISCALL_WRAPPER(ios_base_width_get
, 4)
5669 streamsize __thiscall
ios_base_width_get(ios_base
*this)
5671 TRACE("(%p)\n", this);
5675 /* ?xalloc@ios_base@std@@SAHXZ */
5676 int __cdecl
ios_base_xalloc(void)
5683 _Lockit_ctor_locktype(&lock
, _LOCK_STREAM
);
5684 ret
= ios_base_Index
++;
5685 _Lockit_dtor(&lock
);
5689 /* ?swap@ios_base@std@@QAEXAAV12@@Z */
5690 /* ?swap@ios_base@std@@QEAAXAEAV12@@Z */
5691 DEFINE_THISCALL_WRAPPER(ios_base_swap
, 8)
5692 void __thiscall
ios_base_swap(ios_base
*this, ios_base
*r
)
5696 TRACE("(%p %p)\n", this, r
);
5703 this->vtable
= tmp
.vtable
;
5704 tmp
.vtable
= r
->vtable
;
5708 DEFINE_THISCALL_WRAPPER(basic_ios__Add_vtordisp1
, 4)
5709 void __thiscall
basic_ios__Add_vtordisp1(void *this)
5711 WARN("should not be called (%p)\n", this);
5714 DEFINE_THISCALL_WRAPPER(basic_ios__Add_vtordisp2
, 4)
5715 void __thiscall
basic_ios__Add_vtordisp2(void *this)
5717 WARN("should not be called (%p)\n", this);
5720 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IAE@XZ */
5721 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@IEAA@XZ */
5722 DEFINE_THISCALL_WRAPPER(basic_ios_char_ctor
, 4)
5723 basic_ios_char
* __thiscall
basic_ios_char_ctor(basic_ios_char
*this)
5725 TRACE("(%p)\n", this);
5727 ios_base_ctor(&this->base
);
5728 this->base
.vtable
= &MSVCP_basic_ios_char_vtable
;
5732 /* ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IAEXPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z */
5733 /* ?init@?$basic_ios@DU?$char_traits@D@std@@@std@@IEAAXPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@_N@Z */
5734 DEFINE_THISCALL_WRAPPER(basic_ios_char_init
, 12)
5735 void __thiscall
basic_ios_char_init(basic_ios_char
*this, basic_streambuf_char
*streambuf
, bool isstd
)
5737 TRACE("(%p %p %x)\n", this, streambuf
, isstd
);
5738 ios_base__Init(&this->base
);
5739 this->strbuf
= streambuf
;
5740 this->stream
= NULL
;
5744 ios_base_setstate(&this->base
, IOSTATE_badbit
);
5747 FIXME("standard streams not handled yet\n");
5750 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
5751 /* ??0?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
5752 DEFINE_THISCALL_WRAPPER(basic_ios_char_ctor_streambuf
, 8)
5753 basic_ios_char
* __thiscall
basic_ios_char_ctor_streambuf(basic_ios_char
*this, basic_streambuf_char
*strbuf
)
5755 TRACE("(%p %p)\n", this, strbuf
);
5757 basic_ios_char_ctor(this);
5758 basic_ios_char_init(this, strbuf
, FALSE
);
5762 /* ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UAE@XZ */
5763 /* ??1?$basic_ios@DU?$char_traits@D@std@@@std@@UEAA@XZ */
5764 DEFINE_THISCALL_WRAPPER(basic_ios_char_dtor
, 4)
5765 void __thiscall
basic_ios_char_dtor(basic_ios_char
*this)
5767 TRACE("(%p)\n", this);
5768 ios_base_dtor(&this->base
);
5771 DEFINE_THISCALL_WRAPPER(basic_ios_char_vector_dtor
, 8)
5772 basic_ios_char
* __thiscall
basic_ios_char_vector_dtor(basic_ios_char
*this, unsigned int flags
)
5774 TRACE("(%p %x)\n", this, flags
);
5776 /* we have an array, with the number of elements stored before the first object */
5777 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
5779 for(i
=*ptr
-1; i
>=0; i
--)
5780 basic_ios_char_dtor(this+i
);
5781 MSVCRT_operator_delete(ptr
);
5783 basic_ios_char_dtor(this);
5785 MSVCRT_operator_delete(this);
5791 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z */
5792 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z */
5793 DEFINE_THISCALL_WRAPPER(basic_ios_char_clear_reraise
, 12)
5794 void __thiscall
basic_ios_char_clear_reraise(basic_ios_char
*this, IOSB_iostate state
, bool reraise
)
5796 TRACE("(%p %x %x)\n", this, state
, reraise
);
5797 ios_base_clear_reraise(&this->base
, state
| (this->strbuf
? IOSTATE_goodbit
: IOSTATE_badbit
), reraise
);
5800 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z */
5801 /* ?clear@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z */
5802 DEFINE_THISCALL_WRAPPER(basic_ios_char_clear
, 8)
5803 void __thiscall
basic_ios_char_clear(basic_ios_char
*this, unsigned int state
)
5805 basic_ios_char_clear_reraise(this, (IOSB_iostate
)state
, FALSE
);
5808 /* ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEAAV12@ABV12@@Z */
5809 /* ?copyfmt@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEBV12@@Z */
5810 DEFINE_THISCALL_WRAPPER(basic_ios_char_copyfmt
, 8)
5811 basic_ios_char
* __thiscall
basic_ios_char_copyfmt(basic_ios_char
*this, basic_ios_char
*copy
)
5813 TRACE("(%p %p)\n", this, copy
);
5817 this->stream
= copy
->stream
;
5818 this->fillch
= copy
->fillch
;
5819 ios_base_copyfmt(&this->base
, ©
->base
);
5823 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEDD@Z */
5824 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAADD@Z */
5825 DEFINE_THISCALL_WRAPPER(basic_ios_char_fill_set
, 8)
5826 char __thiscall
basic_ios_char_fill_set(basic_ios_char
*this, char fill
)
5828 char ret
= this->fillch
;
5830 TRACE("(%p %c)\n", this, fill
);
5832 this->fillch
= fill
;
5836 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDXZ */
5837 /* ?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADXZ */
5838 DEFINE_THISCALL_WRAPPER(basic_ios_char_fill_get
, 4)
5839 char __thiscall
basic_ios_char_fill_get(basic_ios_char
*this)
5841 TRACE("(%p)\n", this);
5842 return this->fillch
;
5845 /* ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
5846 /* ?imbue@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
5847 DEFINE_THISCALL_WRAPPER(basic_ios_char_imbue
, 12)
5848 locale
*__thiscall
basic_ios_char_imbue(basic_ios_char
*this, locale
*ret
, const locale
*loc
)
5850 TRACE("(%p %p %p)\n", this, ret
, loc
);
5853 basic_streambuf_char_pubimbue(this->strbuf
, ret
, loc
);
5857 return ios_base_imbue(&this->base
, ret
, loc
);
5860 /* ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDDD@Z */
5861 /* ?narrow@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADDD@Z */
5862 DEFINE_THISCALL_WRAPPER(basic_ios_char_narrow
, 12)
5863 char __thiscall
basic_ios_char_narrow(basic_ios_char
*this, char ch
, char def
)
5865 TRACE("(%p %c %c)\n", this, ch
, def
);
5866 return ctype_char_narrow_ch(ctype_char_use_facet(IOS_LOCALE(&this->base
)), ch
, def
);
5869 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PAV32@@Z */
5870 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@PEAV32@@Z */
5871 DEFINE_THISCALL_WRAPPER(basic_ios_char_rdbuf_set
, 8)
5872 basic_streambuf_char
* __thiscall
basic_ios_char_rdbuf_set(basic_ios_char
*this, basic_streambuf_char
*streambuf
)
5874 basic_streambuf_char
*ret
= this->strbuf
;
5876 TRACE("(%p %p)\n", this, streambuf
);
5878 this->strbuf
= streambuf
;
5879 basic_ios_char_clear(this, IOSTATE_goodbit
);
5883 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ */
5884 /* ?rdbuf@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@XZ */
5885 DEFINE_THISCALL_WRAPPER(basic_ios_char_rdbuf_get
, 4)
5886 basic_streambuf_char
* __thiscall
basic_ios_char_rdbuf_get(const basic_ios_char
*this)
5888 TRACE("(%p)\n", this);
5889 return this->strbuf
;
5892 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXH_N@Z */
5893 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXH_N@Z */
5894 DEFINE_THISCALL_WRAPPER(basic_ios_char_setstate_reraise
, 12)
5895 void __thiscall
basic_ios_char_setstate_reraise(basic_ios_char
*this, IOSB_iostate state
, bool reraise
)
5897 TRACE("(%p %x %x)\n", this, state
, reraise
);
5899 if(state
!= IOSTATE_goodbit
)
5900 basic_ios_char_clear_reraise(this, this->base
.state
| state
, reraise
);
5903 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXI@Z */
5904 /* ?setstate@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXI@Z */
5905 DEFINE_THISCALL_WRAPPER(basic_ios_char_setstate
, 8)
5906 void __thiscall
basic_ios_char_setstate(basic_ios_char
*this, unsigned int state
)
5908 basic_ios_char_setstate_reraise(this, (IOSB_iostate
)state
, FALSE
);
5911 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@PAV32@@Z */
5912 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@PEAV32@@Z */
5913 DEFINE_THISCALL_WRAPPER(basic_ios_char_tie_set
, 8)
5914 basic_ostream_char
* __thiscall
basic_ios_char_tie_set(basic_ios_char
*this, basic_ostream_char
*ostream
)
5916 basic_ostream_char
*ret
= this->stream
;
5918 TRACE("(%p %p)\n", this, ostream
);
5920 this->stream
= ostream
;
5924 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ */
5925 /* ?tie@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_ostream@DU?$char_traits@D@std@@@2@XZ */
5926 DEFINE_THISCALL_WRAPPER(basic_ios_char_tie_get
, 4)
5927 basic_ostream_char
* __thiscall
basic_ios_char_tie_get(const basic_ios_char
*this)
5929 TRACE("(%p)\n", this);
5930 return this->stream
;
5933 /* ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QBEDD@Z */
5934 /* ?widen@?$basic_ios@DU?$char_traits@D@std@@@std@@QEBADD@Z */
5935 DEFINE_THISCALL_WRAPPER(basic_ios_char_widen
, 8)
5936 char __thiscall
basic_ios_char_widen(basic_ios_char
*this, char ch
)
5938 TRACE("(%p %c)\n", this, ch
);
5939 return ctype_char_widen_ch(ctype_char_use_facet(IOS_LOCALE(&this->base
)), ch
);
5942 /* ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z */
5943 /* ?swap@?$basic_ios@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z */
5944 DEFINE_THISCALL_WRAPPER(basic_ios_char_swap
, 8)
5945 void __thiscall
basic_ios_char_swap(basic_ios_char
*this, basic_ios_char
*r
)
5949 TRACE("(%p %p)\n", this, r
);
5954 ios_base_swap(&this->base
, &r
->base
);
5955 swap_ptr
= this->stream
;
5956 this->stream
= r
->stream
;
5957 r
->stream
= swap_ptr
;
5958 this->fillch
^= r
->fillch
;
5959 r
->fillch
^= this->fillch
;
5960 this->fillch
^= r
->fillch
;
5963 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAE@XZ */
5964 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAA@XZ */
5965 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_ctor
, 4)
5966 basic_ios_wchar
* __thiscall
basic_ios_wchar_ctor(basic_ios_wchar
*this)
5968 TRACE("(%p)\n", this);
5970 ios_base_ctor(&this->base
);
5971 this->base
.vtable
= &MSVCP_basic_ios_wchar_vtable
;
5975 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IAE@XZ */
5976 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@IEAA@XZ */
5977 DEFINE_THISCALL_WRAPPER(basic_ios_short_ctor
, 4)
5978 basic_ios_wchar
* __thiscall
basic_ios_short_ctor(basic_ios_wchar
*this)
5980 basic_ios_wchar_ctor(this);
5981 this->base
.vtable
= &MSVCP_basic_ios_short_vtable
;
5985 /* ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IAEXPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z */
5986 /* ?init@?$basic_ios@_WU?$char_traits@_W@std@@@std@@IEAAXPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_N@Z */
5987 /* ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IAEXPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z */
5988 /* ?init@?$basic_ios@GU?$char_traits@G@std@@@std@@IEAAXPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@_N@Z */
5989 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_init
, 12)
5990 void __thiscall
basic_ios_wchar_init(basic_ios_wchar
*this, basic_streambuf_wchar
*streambuf
, bool isstd
)
5992 TRACE("(%p %p %x)\n", this, streambuf
, isstd
);
5993 ios_base__Init(&this->base
);
5994 this->strbuf
= streambuf
;
5995 this->stream
= NULL
;
5999 ios_base_setstate(&this->base
, IOSTATE_badbit
);
6002 FIXME("standard streams not handled yet\n");
6005 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
6006 /* ??0?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
6007 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_ctor_streambuf
, 8)
6008 basic_ios_wchar
* __thiscall
basic_ios_wchar_ctor_streambuf(basic_ios_wchar
*this, basic_streambuf_wchar
*strbuf
)
6010 TRACE("(%p %p)\n", this, strbuf
);
6012 basic_ios_wchar_ctor(this);
6013 basic_ios_wchar_init(this, strbuf
, FALSE
);
6017 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
6018 /* ??0?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
6019 DEFINE_THISCALL_WRAPPER(basic_ios_short_ctor_streambuf
, 8)
6020 basic_ios_wchar
* __thiscall
basic_ios_short_ctor_streambuf(basic_ios_wchar
*this, basic_streambuf_wchar
*strbuf
)
6022 basic_ios_wchar_ctor_streambuf(this, strbuf
);
6023 this->base
.vtable
= &MSVCP_basic_ios_short_vtable
;
6027 /* ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
6028 /* ??1?$basic_ios@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
6029 /* ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UAE@XZ */
6030 /* ??1?$basic_ios@GU?$char_traits@G@std@@@std@@UEAA@XZ */
6031 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_dtor
, 4)
6032 void __thiscall
basic_ios_wchar_dtor(basic_ios_wchar
*this)
6034 TRACE("(%p)\n", this);
6035 ios_base_dtor(&this->base
);
6038 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_vector_dtor
, 8)
6039 basic_ios_wchar
* __thiscall
basic_ios_wchar_vector_dtor(basic_ios_wchar
*this, unsigned int flags
)
6041 TRACE("(%p %x)\n", this, flags
);
6043 /* we have an array, with the number of elements stored before the first object */
6044 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
6046 for(i
=*ptr
-1; i
>=0; i
--)
6047 basic_ios_wchar_dtor(this+i
);
6048 MSVCRT_operator_delete(ptr
);
6050 basic_ios_wchar_dtor(this);
6052 MSVCRT_operator_delete(this);
6058 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z */
6059 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z */
6060 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z */
6061 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z */
6062 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_clear_reraise
, 12)
6063 void __thiscall
basic_ios_wchar_clear_reraise(basic_ios_wchar
*this, IOSB_iostate state
, bool reraise
)
6065 TRACE("(%p %x %x)\n", this, state
, reraise
);
6066 ios_base_clear_reraise(&this->base
, state
| (this->strbuf
? IOSTATE_goodbit
: IOSTATE_badbit
), reraise
);
6069 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z */
6070 /* ?clear@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z */
6071 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z */
6072 /* ?clear@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z */
6073 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_clear
, 8)
6074 void __thiscall
basic_ios_wchar_clear(basic_ios_wchar
*this, unsigned int state
)
6076 basic_ios_wchar_clear_reraise(this, (IOSB_iostate
)state
, FALSE
);
6079 /* ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEAAV12@ABV12@@Z */
6080 /* ?copyfmt@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEBV12@@Z */
6081 /* ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEAAV12@ABV12@@Z */
6082 /* ?copyfmt@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEBV12@@Z */
6083 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_copyfmt
, 8)
6084 basic_ios_wchar
* __thiscall
basic_ios_wchar_copyfmt(basic_ios_wchar
*this, basic_ios_wchar
*copy
)
6086 TRACE("(%p %p)\n", this, copy
);
6090 this->stream
= copy
->stream
;
6091 this->fillch
= copy
->fillch
;
6092 ios_base_copyfmt(&this->base
, ©
->base
);
6096 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE_W_W@Z */
6097 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA_W_W@Z */
6098 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEGG@Z */
6099 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAGG@Z */
6100 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_fill_set
, 8)
6101 wchar_t __thiscall
basic_ios_wchar_fill_set(basic_ios_wchar
*this, wchar_t fill
)
6103 wchar_t ret
= this->fillch
;
6105 TRACE("(%p %c)\n", this, fill
);
6107 this->fillch
= fill
;
6111 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WXZ */
6112 /* ?fill@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WXZ */
6113 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGXZ */
6114 /* ?fill@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGXZ */
6115 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_fill_get
, 4)
6116 wchar_t __thiscall
basic_ios_wchar_fill_get(basic_ios_wchar
*this)
6118 TRACE("(%p)\n", this);
6119 return this->fillch
;
6122 /* ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
6123 /* ?imbue@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
6124 /* ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QAE?AVlocale@2@ABV32@@Z */
6125 /* ?imbue@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAA?AVlocale@2@AEBV32@@Z */
6126 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_imbue
, 12)
6127 locale
*__thiscall
basic_ios_wchar_imbue(basic_ios_wchar
*this, locale
*ret
, const locale
*loc
)
6129 TRACE("(%p %p %p)\n", this, ret
, loc
);
6132 basic_streambuf_wchar_pubimbue(this->strbuf
, ret
, loc
);
6136 return ios_base_imbue(&this->base
, ret
, loc
);
6139 /* ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBED_WD@Z */
6140 /* ?narrow@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAD_WD@Z */
6141 /* ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEDGD@Z */
6142 /* ?narrow@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBADGD@Z */
6143 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_narrow
, 12)
6144 char __thiscall
basic_ios_wchar_narrow(basic_ios_wchar
*this, wchar_t ch
, char def
)
6146 TRACE("(%p %c %c)\n", this, ch
, def
);
6147 return ctype_wchar_narrow_ch(ctype_wchar_use_facet(IOS_LOCALE(&this->base
)), ch
, def
);
6150 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PAV32@@Z */
6151 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@PEAV32@@Z */
6152 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PAV32@@Z */
6153 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@PEAV32@@Z */
6154 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_rdbuf_set
, 8)
6155 basic_streambuf_wchar
* __thiscall
basic_ios_wchar_rdbuf_set(basic_ios_wchar
*this, basic_streambuf_wchar
*streambuf
)
6157 basic_streambuf_wchar
*ret
= this->strbuf
;
6159 TRACE("(%p %p)\n", this, streambuf
);
6161 this->strbuf
= streambuf
;
6162 basic_ios_wchar_clear(this, IOSTATE_goodbit
);
6166 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ */
6167 /* ?rdbuf@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@XZ */
6168 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ */
6169 /* ?rdbuf@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@XZ */
6170 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_rdbuf_get
, 4)
6171 basic_streambuf_wchar
* __thiscall
basic_ios_wchar_rdbuf_get(const basic_ios_wchar
*this)
6173 TRACE("(%p)\n", this);
6174 return this->strbuf
;
6177 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXH_N@Z */
6178 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXH_N@Z */
6179 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXH_N@Z */
6180 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXH_N@Z */
6181 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_setstate_reraise
, 12)
6182 void __thiscall
basic_ios_wchar_setstate_reraise(basic_ios_wchar
*this, IOSB_iostate state
, bool reraise
)
6184 TRACE("(%p %x %x)\n", this, state
, reraise
);
6186 if(state
!= IOSTATE_goodbit
)
6187 basic_ios_wchar_clear_reraise(this, this->base
.state
| state
, reraise
);
6190 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXI@Z */
6191 /* ?setstate@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXI@Z */
6192 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXI@Z */
6193 /* ?setstate@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXI@Z */
6194 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_setstate
, 8)
6195 void __thiscall
basic_ios_wchar_setstate(basic_ios_wchar
*this, IOSB_iostate state
)
6197 basic_ios_wchar_setstate_reraise(this, state
, FALSE
);
6200 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PAV32@@Z */
6201 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@PEAV32@@Z */
6202 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@PAV32@@Z */
6203 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@PEAV32@@Z */
6204 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_tie_set
, 8)
6205 basic_ostream_wchar
* __thiscall
basic_ios_wchar_tie_set(basic_ios_wchar
*this, basic_ostream_wchar
*ostream
)
6207 basic_ostream_wchar
*ret
= this->stream
;
6209 TRACE("(%p %p)\n", this, ostream
);
6211 this->stream
= ostream
;
6215 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ */
6216 /* ?tie@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_ostream@_WU?$char_traits@_W@std@@@2@XZ */
6217 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ */
6218 /* ?tie@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_ostream@GU?$char_traits@G@std@@@2@XZ */
6219 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_tie_get
, 4)
6220 basic_ostream_wchar
* __thiscall
basic_ios_wchar_tie_get(const basic_ios_wchar
*this)
6222 TRACE("(%p)\n", this);
6223 return this->stream
;
6226 /* ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QBE_WD@Z */
6227 /* ?widen@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEBA_WD@Z */
6228 /* ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QBEGD@Z */
6229 /* ?widen@?$basic_ios@GU?$char_traits@G@std@@@std@@QEBAGD@Z */
6230 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_widen
, 8)
6231 wchar_t __thiscall
basic_ios_wchar_widen(basic_ios_wchar
*this, char ch
)
6233 TRACE("(%p %c)\n", this, ch
);
6234 return ctype_wchar_widen_ch(ctype_wchar_use_facet(IOS_LOCALE(&this->base
)), ch
);
6237 /* ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z */
6238 /* ?swap@?$basic_ios@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z */
6239 /* ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z */
6240 /* ?swap@?$basic_ios@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z */
6241 DEFINE_THISCALL_WRAPPER(basic_ios_wchar_swap
, 8)
6242 void __thiscall
basic_ios_wchar_swap(basic_ios_wchar
*this, basic_ios_wchar
*r
)
6246 TRACE("(%p %p)\n", this, r
);
6251 ios_base_swap(&this->base
, &r
->base
);
6252 swap_ptr
= this->stream
;
6253 this->stream
= r
->stream
;
6254 r
->stream
= swap_ptr
;
6255 this->fillch
^= r
->fillch
;
6256 r
->fillch
^= this->fillch
;
6257 this->fillch
^= r
->fillch
;
6260 /* Caution: basic_ostream uses virtual inheritance.
6261 * All constructors have additional parameter that says if base class should be initialized.
6262 * Base class needs to be accessed using vbtable.
6264 static inline basic_ios_char
* basic_ostream_char_get_basic_ios(basic_ostream_char
*this)
6266 return (basic_ios_char
*)((char*)this+this->vbtable
[1]);
6269 static inline basic_ios_char
* basic_ostream_char_to_basic_ios(basic_ostream_char
*ptr
)
6271 return (basic_ios_char
*)((char*)ptr
+basic_ostream_char_vbtable
[1]);
6274 static inline basic_ostream_char
* basic_ostream_char_from_basic_ios(basic_ios_char
*ptr
)
6276 return (basic_ostream_char
*)((char*)ptr
-basic_ostream_char_vbtable
[1]);
6279 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
6280 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
6281 DEFINE_THISCALL_WRAPPER(basic_ostream_char_ctor
, 16)
6282 basic_ostream_char
* __thiscall
basic_ostream_char_ctor(basic_ostream_char
*this,
6283 basic_streambuf_char
*strbuf
, bool isstd
, bool virt_init
)
6285 basic_ios_char
*base
;
6287 TRACE("(%p %p %d %d)\n", this, strbuf
, isstd
, virt_init
);
6290 this->vbtable
= basic_ostream_char_vbtable
;
6291 base
= basic_ostream_char_get_basic_ios(this);
6292 INIT_BASIC_IOS_VTORDISP(base
);
6293 basic_ios_char_ctor(base
);
6295 base
= basic_ostream_char_get_basic_ios(this);
6298 base
->base
.vtable
= &MSVCP_basic_ostream_char_vtable
;
6299 basic_ios_char_init(base
, strbuf
, isstd
);
6303 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
6304 /* ??0?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
6305 DEFINE_THISCALL_WRAPPER(basic_ostream_char_ctor_uninitialized
, 16)
6306 basic_ostream_char
* __thiscall
basic_ostream_char_ctor_uninitialized(basic_ostream_char
*this,
6307 int uninitialized
, bool addstd
, bool virt_init
)
6309 basic_ios_char
*base
;
6311 TRACE("(%p %d %x)\n", this, uninitialized
, addstd
);
6314 this->vbtable
= basic_ostream_char_vbtable
;
6315 base
= basic_ostream_char_get_basic_ios(this);
6316 INIT_BASIC_IOS_VTORDISP(base
);
6317 basic_ios_char_ctor(base
);
6319 base
= basic_ostream_char_get_basic_ios(this);
6322 base
->base
.vtable
= &MSVCP_basic_ostream_char_vtable
;
6324 ios_base_Addstd(&base
->base
);
6328 /* ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UAE@XZ */
6329 /* ??1?$basic_ostream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
6330 DEFINE_THISCALL_WRAPPER(basic_ostream_char_dtor
, 4)
6331 void __thiscall
basic_ostream_char_dtor(basic_ios_char
*base
)
6333 basic_ostream_char
*this = basic_ostream_char_from_basic_ios(base
);
6335 /* don't destroy virtual base here */
6336 TRACE("(%p)\n", this);
6339 /* ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
6340 /* ??_D?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
6341 DEFINE_THISCALL_WRAPPER(basic_ostream_char_vbase_dtor
, 4)
6342 void __thiscall
basic_ostream_char_vbase_dtor(basic_ostream_char
*this)
6344 basic_ios_char
*base
= basic_ostream_char_to_basic_ios(this);
6346 TRACE("(%p)\n", this);
6348 basic_ostream_char_dtor(base
);
6349 basic_ios_char_dtor(base
);
6352 DEFINE_THISCALL_WRAPPER(basic_ostream_char_vector_dtor
, 8)
6353 basic_ostream_char
* __thiscall
basic_ostream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
6355 basic_ostream_char
*this = basic_ostream_char_from_basic_ios(base
);
6357 TRACE("(%p %x)\n", this, flags
);
6360 /* we have an array, with the number of elements stored before the first object */
6361 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
6363 for(i
=*ptr
-1; i
>=0; i
--)
6364 basic_ostream_char_vbase_dtor(this+i
);
6365 MSVCRT_operator_delete(ptr
);
6367 basic_ostream_char_vbase_dtor(this);
6369 MSVCRT_operator_delete(this);
6375 /* ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ */
6376 /* ?flush@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ */
6377 DEFINE_THISCALL_WRAPPER(basic_ostream_char_flush
, 4)
6378 basic_ostream_char
* __thiscall
basic_ostream_char_flush(basic_ostream_char
*this)
6380 /* this function is not matching C++ specification */
6381 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6383 TRACE("(%p)\n", this);
6385 if(basic_ios_char_rdbuf_get(base
) && ios_base_good(&base
->base
)
6386 && basic_streambuf_char_pubsync(basic_ios_char_rdbuf_get(base
))==-1)
6387 basic_ios_char_setstate(base
, IOSTATE_badbit
);
6391 /* ?flush@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
6392 /* ?flush@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
6393 basic_ostream_char
* __cdecl
flush_ostream_char(basic_ostream_char
*ostream
)
6395 return basic_ostream_char_flush(ostream
);
6398 /* ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
6399 /* ?_Osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
6400 DEFINE_THISCALL_WRAPPER(basic_ostream_char__Osfx
, 4)
6401 void __thiscall
basic_ostream_char__Osfx(basic_ostream_char
*this)
6403 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6405 TRACE("(%p)\n", this);
6407 if(base
->base
.fmtfl
& FMTFLAG_unitbuf
)
6408 basic_ostream_char_flush(this);
6411 /* ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
6412 /* ?osfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
6413 DEFINE_THISCALL_WRAPPER(basic_ostream_char_osfx
, 4)
6414 void __thiscall
basic_ostream_char_osfx(basic_ostream_char
*this)
6416 TRACE("(%p)\n", this);
6417 basic_ostream_char__Osfx(this);
6420 static BOOL
basic_ostream_char_sentry_create(basic_ostream_char
*ostr
)
6422 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6424 if(basic_ios_char_rdbuf_get(base
))
6425 call_basic_streambuf_char__Lock(base
->strbuf
);
6427 if(ios_base_good(&base
->base
) && base
->stream
)
6428 basic_ostream_char_flush(base
->stream
);
6430 return ios_base_good(&base
->base
);
6433 static void basic_ostream_char_sentry_destroy(basic_ostream_char
*ostr
)
6435 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6437 if(ios_base_good(&base
->base
) && !__uncaught_exception())
6438 basic_ostream_char_osfx(ostr
);
6440 if(basic_ios_char_rdbuf_get(base
))
6441 call_basic_streambuf_char__Unlock(base
->strbuf
);
6444 /* ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE_NXZ */
6445 /* ?opfx@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA_NXZ */
6446 DEFINE_THISCALL_WRAPPER(basic_ostream_char_opfx
, 4)
6447 bool __thiscall
basic_ostream_char_opfx(basic_ostream_char
*this)
6449 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6451 TRACE("(%p)\n", this);
6453 if(ios_base_good(&base
->base
) && base
->stream
)
6454 basic_ostream_char_flush(base
->stream
);
6455 return ios_base_good(&base
->base
);
6458 /* ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z */
6459 /* ?put@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z */
6460 DEFINE_THISCALL_WRAPPER(basic_ostream_char_put
, 8)
6461 basic_ostream_char
* __thiscall
basic_ostream_char_put(basic_ostream_char
*this, char ch
)
6463 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6465 TRACE("(%p %c)\n", this, ch
);
6467 if(!basic_ostream_char_sentry_create(this)
6468 || basic_streambuf_char_sputc(base
->strbuf
, ch
)==EOF
) {
6469 basic_ostream_char_sentry_destroy(this);
6470 basic_ios_char_setstate(base
, IOSTATE_badbit
);
6474 basic_ostream_char_sentry_destroy(this);
6478 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@JH@Z */
6479 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
6480 #if STREAMOFF_BITS == 64
6481 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp
, 16)
6483 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp
, 12)
6485 basic_ostream_char
* __thiscall
basic_ostream_char_seekp(basic_ostream_char
*this, streamoff off
, int way
)
6487 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6489 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), way
);
6491 if(!ios_base_fail(&base
->base
)) {
6494 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
6495 &seek
, off
, way
, OPENMODE_out
);
6496 if(seek
.off
==-1 && seek
.pos
==0 && MBSTATET_TO_INT(&seek
.state
)==0)
6497 basic_ios_char_setstate(base
, IOSTATE_failbit
);
6502 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
6503 /* ?seekp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
6504 DEFINE_THISCALL_WRAPPER(basic_ostream_char_seekp_fpos
, 28)
6505 basic_ostream_char
* __thiscall
basic_ostream_char_seekp_fpos(basic_ostream_char
*this, fpos_mbstatet pos
)
6507 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6509 TRACE("(%p %s)\n", this, debugstr_fpos_mbstatet(&pos
));
6511 if(!ios_base_fail(&base
->base
)) {
6514 basic_streambuf_char_pubseekpos(basic_ios_char_rdbuf_get(base
),
6515 &seek
, pos
, OPENMODE_out
);
6516 if(seek
.off
==-1 && seek
.pos
==0 && MBSTATET_TO_INT(&seek
.state
)==0)
6517 basic_ios_char_setstate(base
, IOSTATE_failbit
);
6522 /* ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ */
6523 /* ?tellp@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
6524 DEFINE_THISCALL_WRAPPER(basic_ostream_char_tellp
, 8)
6525 fpos_mbstatet
* __thiscall
basic_ostream_char_tellp(basic_ostream_char
*this, fpos_mbstatet
*ret
)
6527 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6529 TRACE("(%p)\n", this);
6531 if(!ios_base_fail(&base
->base
)) {
6532 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
6533 ret
, 0, SEEKDIR_cur
, OPENMODE_out
);
6537 memset(&ret
->state
, 0, sizeof(ret
->state
));
6542 /* ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV12@PBDH@Z */
6543 /* ?write@?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEBD_J@Z */
6544 #if STREAMSIZE_BITS == 64
6545 DEFINE_THISCALL_WRAPPER(basic_ostream_char_write
, 16)
6547 DEFINE_THISCALL_WRAPPER(basic_ostream_char_write
, 12)
6549 basic_ostream_char
* __thiscall
basic_ostream_char_write(basic_ostream_char
*this, const char *str
, streamsize count
)
6551 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6553 TRACE("(%p %s %s)\n", this, debugstr_a(str
), wine_dbgstr_longlong(count
));
6555 if(!basic_ostream_char_sentry_create(this)
6556 || basic_streambuf_char_sputn(base
->strbuf
, str
, count
)!=count
) {
6557 basic_ostream_char_sentry_destroy(this);
6558 basic_ios_char_setstate(base
, IOSTATE_badbit
);
6562 basic_ostream_char_sentry_destroy(this);
6566 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@F@Z */
6567 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@F@Z */
6568 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_short
, 8)
6569 basic_ostream_char
* __thiscall
basic_ostream_char_print_short(basic_ostream_char
*this, short val
)
6571 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6572 int state
= IOSTATE_goodbit
;
6574 TRACE("(%p %d)\n", this, val
);
6576 if(basic_ostream_char_sentry_create(this)) {
6577 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6578 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6579 ostreambuf_iterator_char dest
;
6581 memset(&dest
, 0, sizeof(dest
));
6582 dest
.strbuf
= strbuf
;
6583 num_put_char_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
),
6584 (ios_base_flags_get(&base
->base
) & FMTFLAG_basefield
& (FMTFLAG_oct
| FMTFLAG_hex
))
6585 ? (LONG
)((unsigned short)val
) : (LONG
)val
);
6587 basic_ostream_char_sentry_destroy(this);
6589 basic_ios_char_setstate(base
, state
);
6593 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@G@Z */
6594 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@G@Z */
6595 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ushort
, 8)
6596 basic_ostream_char
* __thiscall
basic_ostream_char_print_ushort(basic_ostream_char
*this, unsigned short val
)
6598 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6599 int state
= IOSTATE_goodbit
;
6601 TRACE("(%p %u)\n", this, val
);
6603 if(basic_ostream_char_sentry_create(this)) {
6604 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6605 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6606 ostreambuf_iterator_char dest
;
6608 memset(&dest
, 0, sizeof(dest
));
6609 dest
.strbuf
= strbuf
;
6610 num_put_char_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6612 basic_ostream_char_sentry_destroy(this);
6614 basic_ios_char_setstate(base
, state
);
6618 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@H@Z */
6619 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@H@Z */
6620 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@J@Z */
6621 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@J@Z */
6622 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_int
, 8)
6623 basic_ostream_char
* __thiscall
basic_ostream_char_print_int(basic_ostream_char
*this, int val
)
6625 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6626 int state
= IOSTATE_goodbit
;
6628 TRACE("(%p %d)\n", this, val
);
6630 if(basic_ostream_char_sentry_create(this)) {
6631 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6632 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6633 ostreambuf_iterator_char dest
;
6635 memset(&dest
, 0, sizeof(dest
));
6636 dest
.strbuf
= strbuf
;
6637 num_put_char_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6639 basic_ostream_char_sentry_destroy(this);
6641 basic_ios_char_setstate(base
, state
);
6645 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@I@Z */
6646 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@I@Z */
6647 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@K@Z */
6648 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@K@Z */
6649 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_uint
, 8)
6650 basic_ostream_char
* __thiscall
basic_ostream_char_print_uint(basic_ostream_char
*this, unsigned int val
)
6652 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6653 int state
= IOSTATE_goodbit
;
6655 TRACE("(%p %u)\n", this, val
);
6657 if(basic_ostream_char_sentry_create(this)) {
6658 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6659 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6660 ostreambuf_iterator_char dest
;
6662 memset(&dest
, 0, sizeof(dest
));
6663 dest
.strbuf
= strbuf
;
6664 num_put_char_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6666 basic_ostream_char_sentry_destroy(this);
6668 basic_ios_char_setstate(base
, state
);
6672 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@M@Z */
6673 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@M@Z */
6674 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_float
, 8)
6675 basic_ostream_char
* __thiscall
basic_ostream_char_print_float(basic_ostream_char
*this, float val
)
6677 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6678 int state
= IOSTATE_goodbit
;
6680 TRACE("(%p %f)\n", this, val
);
6682 if(basic_ostream_char_sentry_create(this)) {
6683 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6684 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6685 ostreambuf_iterator_char dest
;
6687 memset(&dest
, 0, sizeof(dest
));
6688 dest
.strbuf
= strbuf
;
6689 num_put_char_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6691 basic_ostream_char_sentry_destroy(this);
6693 basic_ios_char_setstate(base
, state
);
6697 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@N@Z */
6698 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@N@Z */
6699 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_double
, 12)
6700 basic_ostream_char
* __thiscall
basic_ostream_char_print_double(basic_ostream_char
*this, double val
)
6702 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6703 int state
= IOSTATE_goodbit
;
6705 TRACE("(%p %lf)\n", this, val
);
6707 if(basic_ostream_char_sentry_create(this)) {
6708 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6709 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6710 ostreambuf_iterator_char dest
;
6712 memset(&dest
, 0, sizeof(dest
));
6713 dest
.strbuf
= strbuf
;
6714 num_put_char_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6716 basic_ostream_char_sentry_destroy(this);
6718 basic_ios_char_setstate(base
, state
);
6722 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@O@Z */
6723 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@O@Z */
6724 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ldouble
, 12)
6725 basic_ostream_char
* __thiscall
basic_ostream_char_print_ldouble(basic_ostream_char
*this, double val
)
6727 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6728 int state
= IOSTATE_goodbit
;
6730 TRACE("(%p %lf)\n", this, val
);
6732 if(basic_ostream_char_sentry_create(this)) {
6733 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6734 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6735 ostreambuf_iterator_char dest
;
6737 memset(&dest
, 0, sizeof(dest
));
6738 dest
.strbuf
= strbuf
;
6739 num_put_char_put_ldouble(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6741 basic_ostream_char_sentry_destroy(this);
6743 basic_ios_char_setstate(base
, state
);
6747 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
6748 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
6749 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_streambuf
, 8)
6750 basic_ostream_char
* __thiscall
basic_ostream_char_print_streambuf(basic_ostream_char
*this, basic_streambuf_char
*val
)
6752 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6753 IOSB_iostate state
= IOSTATE_badbit
;
6756 TRACE("(%p %p)\n", this, val
);
6758 if(basic_ostream_char_sentry_create(this)) {
6759 for(c
= basic_streambuf_char_sgetc(val
); c
!=EOF
;
6760 c
= basic_streambuf_char_snextc(val
)) {
6761 state
= IOSTATE_goodbit
;
6763 if(basic_streambuf_char_sputc(base
->strbuf
, c
) == EOF
) {
6764 state
= IOSTATE_badbit
;
6769 state
= IOSTATE_badbit
;
6771 basic_ostream_char_sentry_destroy(this);
6773 ios_base_width_set(&base
->base
, 0);
6774 basic_ios_char_setstate(base
, state
);
6778 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@PBX@Z */
6779 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEBX@Z */
6780 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_ptr
, 8)
6781 basic_ostream_char
* __thiscall
basic_ostream_char_print_ptr(basic_ostream_char
*this, const void *val
)
6783 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6784 int state
= IOSTATE_goodbit
;
6786 TRACE("(%p %p)\n", this, val
);
6788 if(basic_ostream_char_sentry_create(this)) {
6789 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6790 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6791 ostreambuf_iterator_char dest
;
6793 memset(&dest
, 0, sizeof(dest
));
6794 dest
.strbuf
= strbuf
;
6795 num_put_char_put_ptr(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6797 basic_ostream_char_sentry_destroy(this);
6799 basic_ios_char_setstate(base
, state
);
6803 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_J@Z */
6804 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_J@Z */
6805 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_int64
, 12)
6806 basic_ostream_char
* __thiscall
basic_ostream_char_print_int64(basic_ostream_char
*this, __int64 val
)
6808 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6809 int state
= IOSTATE_goodbit
;
6811 TRACE("(%p)\n", this);
6813 if(basic_ostream_char_sentry_create(this)) {
6814 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6815 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6816 ostreambuf_iterator_char dest
;
6818 memset(&dest
, 0, sizeof(dest
));
6819 dest
.strbuf
= strbuf
;
6820 num_put_char_put_int64(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6822 basic_ostream_char_sentry_destroy(this);
6824 basic_ios_char_setstate(base
, state
);
6828 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_K@Z */
6829 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_K@Z */
6830 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_uint64
, 12)
6831 basic_ostream_char
* __thiscall
basic_ostream_char_print_uint64(basic_ostream_char
*this, unsigned __int64 val
)
6833 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6834 int state
= IOSTATE_goodbit
;
6836 TRACE("(%p)\n", this);
6838 if(basic_ostream_char_sentry_create(this)) {
6839 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6840 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6841 ostreambuf_iterator_char dest
;
6843 memset(&dest
, 0, sizeof(dest
));
6844 dest
.strbuf
= strbuf
;
6845 num_put_char_put_uint64(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6847 basic_ostream_char_sentry_destroy(this);
6849 basic_ios_char_setstate(base
, state
);
6853 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@_N@Z */
6854 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@_N@Z */
6855 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_bool
, 8)
6856 basic_ostream_char
* __thiscall
basic_ostream_char_print_bool(basic_ostream_char
*this, bool val
)
6858 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(this);
6859 int state
= IOSTATE_goodbit
;
6861 TRACE("(%p %x)\n", this, val
);
6863 if(basic_ostream_char_sentry_create(this)) {
6864 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
6865 const num_put
*numput
= num_put_char_use_facet(IOS_LOCALE(strbuf
));
6866 ostreambuf_iterator_char dest
;
6868 memset(&dest
, 0, sizeof(dest
));
6869 dest
.strbuf
= strbuf
;
6870 num_put_char_put_bool(numput
, &dest
, dest
, &base
->base
, basic_ios_char_fill_get(base
), val
);
6872 basic_ostream_char_sentry_destroy(this);
6874 basic_ios_char_setstate(base
, state
);
6878 /* ?ends@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
6879 /* ?ends@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
6880 basic_ostream_char
* __cdecl
basic_ostream_char_ends(basic_ostream_char
*ostr
)
6882 TRACE("(%p)\n", ostr
);
6884 basic_ostream_char_put(ostr
, 0);
6888 /* ?endl@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@1@AAV21@@Z */
6889 /* ?endl@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
6890 basic_ostream_char
* __cdecl
basic_ostream_char_endl(basic_ostream_char
*ostr
)
6892 TRACE("(%p)\n", ostr
);
6894 basic_ostream_char_put(ostr
, '\n');
6895 basic_ostream_char_flush(ostr
);
6899 /* ??$?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 */
6900 /* ??$?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 */
6901 basic_ostream_char
* __cdecl
basic_ostream_char_print_bstr(basic_ostream_char
*ostr
, const basic_string_char
*str
)
6903 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6904 IOSB_iostate state
= IOSTATE_goodbit
;
6906 TRACE("(%p %p)\n", ostr
, str
);
6908 if(basic_ostream_char_sentry_create(ostr
)) {
6909 size_t len
= MSVCP_basic_string_char_length(str
);
6910 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
6912 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
6913 for(; pad
!=0; pad
--) {
6914 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6915 state
= IOSTATE_badbit
;
6921 if(state
== IOSTATE_goodbit
) {
6922 if(basic_streambuf_char_sputn(base
->strbuf
, MSVCP_basic_string_char_c_str(str
), len
) != len
)
6923 state
= IOSTATE_badbit
;
6926 if(state
== IOSTATE_goodbit
) {
6927 for(; pad
!=0; pad
--) {
6928 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6929 state
= IOSTATE_badbit
;
6935 base
->base
.wide
= 0;
6937 state
= IOSTATE_badbit
;
6939 basic_ostream_char_sentry_destroy(ostr
);
6941 basic_ios_char_setstate(base
, state
);
6945 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@C@Z */
6946 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@C@Z */
6947 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@D@Z */
6948 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@D@Z */
6949 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@E@Z */
6950 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@E@Z */
6951 basic_ostream_char
* __cdecl
basic_ostream_char_print_ch(basic_ostream_char
*ostr
, char ch
)
6953 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
6954 IOSB_iostate state
= IOSTATE_goodbit
;
6956 TRACE("(%p %d)\n", ostr
, ch
);
6958 if(basic_ostream_char_sentry_create(ostr
)) {
6959 streamsize pad
= (base
->base
.wide
>1 ? base
->base
.wide
-1 : 0);
6961 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
6962 for(; pad
!=0; pad
--) {
6963 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6964 state
= IOSTATE_badbit
;
6970 if(state
== IOSTATE_goodbit
) {
6971 if(basic_streambuf_char_sputc(base
->strbuf
, ch
) == EOF
)
6972 state
= IOSTATE_badbit
;
6975 if(state
== IOSTATE_goodbit
) {
6976 for(; pad
!=0; pad
--) {
6977 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
6978 state
= IOSTATE_badbit
;
6984 base
->base
.wide
= 0;
6986 state
= IOSTATE_badbit
;
6988 basic_ostream_char_sentry_destroy(ostr
);
6990 basic_ios_char_setstate(base
, state
);
6994 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBC@Z */
6995 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBC@Z */
6996 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBD@Z */
6997 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBD@Z */
6998 /* ??$?6U?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@PBE@Z */
6999 /* ??$?6U?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@PEBE@Z */
7000 basic_ostream_char
* __cdecl
basic_ostream_char_print_str(basic_ostream_char
*ostr
, const char *str
)
7002 basic_ios_char
*base
= basic_ostream_char_get_basic_ios(ostr
);
7003 IOSB_iostate state
= IOSTATE_goodbit
;
7005 TRACE("(%p %s)\n", ostr
, str
);
7007 if(basic_ostream_char_sentry_create(ostr
)) {
7008 size_t len
= strlen(str
);
7009 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
7011 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
7012 for(; pad
!=0; pad
--) {
7013 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
7014 state
= IOSTATE_badbit
;
7020 if(state
== IOSTATE_goodbit
) {
7021 if(basic_streambuf_char_sputn(base
->strbuf
, str
, len
) != len
)
7022 state
= IOSTATE_badbit
;
7025 if(state
== IOSTATE_goodbit
) {
7026 for(; pad
!=0; pad
--) {
7027 if(basic_streambuf_char_sputc(base
->strbuf
, base
->fillch
) == EOF
) {
7028 state
= IOSTATE_badbit
;
7034 base
->base
.wide
= 0;
7036 state
= IOSTATE_badbit
;
7038 basic_ostream_char_sentry_destroy(ostr
);
7040 basic_ios_char_setstate(base
, state
);
7044 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
7045 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
7046 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func
, 8)
7047 basic_ostream_char
* __thiscall
basic_ostream_char_print_func(basic_ostream_char
*this,
7048 basic_ostream_char
* (__cdecl
*pfunc
)(basic_ostream_char
*))
7050 TRACE("(%p %p)\n", this, pfunc
);
7055 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z */
7056 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z */
7057 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func_basic_ios
, 8)
7058 basic_ostream_char
* __thiscall
basic_ostream_char_print_func_basic_ios(basic_ostream_char
*this,
7059 basic_ios_char
* (__cdecl
*pfunc
)(basic_ios_char
*))
7061 TRACE("(%p %p)\n", this, pfunc
);
7062 pfunc(basic_ostream_char_get_basic_ios(this));
7066 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
7067 /* ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
7068 DEFINE_THISCALL_WRAPPER(basic_ostream_char_print_func_ios_base
, 8)
7069 basic_ostream_char
* __thiscall
basic_ostream_char_print_func_ios_base(
7070 basic_ostream_char
*this, ios_base
* (__cdecl
*pfunc
)(ios_base
*))
7072 TRACE("(%p %p)\n", this, pfunc
);
7073 pfunc(&basic_ostream_char_get_basic_ios(this)->base
);
7077 /* ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IAEXAAV12@@Z */
7078 /* ?swap@?$basic_ostream@DU?$char_traits@D@std@@@std@@IEAAXAEAV12@@Z */
7079 DEFINE_THISCALL_WRAPPER(basic_ostream_char_swap
, 8)
7080 void __thiscall
basic_ostream_char_swap(basic_ostream_char
*this, basic_ostream_char
*r
)
7082 TRACE("(%p %p)\n", this, r
);
7087 basic_ios_char_swap(basic_ostream_char_get_basic_ios(this),
7088 basic_ostream_char_get_basic_ios(r
));
7091 /* Caution: basic_ostream uses virtual inheritance. */
7092 static inline basic_ios_wchar
* basic_ostream_wchar_get_basic_ios(basic_ostream_wchar
*this)
7094 return (basic_ios_wchar
*)((char*)this+this->vbtable
[1]);
7097 static inline basic_ios_wchar
* basic_ostream_wchar_to_basic_ios(basic_ostream_wchar
*ptr
)
7099 return (basic_ios_wchar
*)((char*)ptr
+basic_ostream_wchar_vbtable
[1]);
7102 static inline basic_ostream_wchar
* basic_ostream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
7104 return (basic_ostream_wchar
*)((char*)ptr
-basic_ostream_wchar_vbtable
[1]);
7107 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
7108 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
7109 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_ctor
, 16)
7110 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_ctor(basic_ostream_wchar
*this,
7111 basic_streambuf_wchar
*strbuf
, bool isstd
, bool virt_init
)
7113 basic_ios_wchar
*base
;
7115 TRACE("(%p %p %d %d)\n", this, strbuf
, isstd
, virt_init
);
7118 this->vbtable
= basic_ostream_wchar_vbtable
;
7119 base
= basic_ostream_wchar_get_basic_ios(this);
7120 INIT_BASIC_IOS_VTORDISP(base
);
7121 basic_ios_wchar_ctor(base
);
7123 base
= basic_ostream_wchar_get_basic_ios(this);
7126 base
->base
.vtable
= &MSVCP_basic_ostream_wchar_vtable
;
7127 basic_ios_wchar_init(base
, strbuf
, isstd
);
7131 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
7132 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
7133 DEFINE_THISCALL_WRAPPER(basic_ostream_short_ctor
, 16)
7134 basic_ostream_wchar
* __thiscall
basic_ostream_short_ctor(basic_ostream_wchar
*this,
7135 basic_streambuf_wchar
*strbuf
, bool isstd
, bool virt_init
)
7137 basic_ostream_wchar_ctor(this, strbuf
, isstd
, virt_init
);
7138 basic_ostream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_ostream_short_vtable
;
7142 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
7143 /* ??0?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
7144 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_ctor_uninitialized
, 16)
7145 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_ctor_uninitialized(basic_ostream_wchar
*this,
7146 int uninitialized
, bool addstd
, bool virt_init
)
7148 basic_ios_wchar
*base
;
7150 TRACE("(%p %d %x)\n", this, uninitialized
, addstd
);
7153 this->vbtable
= basic_ostream_wchar_vbtable
;
7154 base
= basic_ostream_wchar_get_basic_ios(this);
7155 INIT_BASIC_IOS_VTORDISP(base
);
7156 basic_ios_wchar_ctor(base
);
7158 base
= basic_ostream_wchar_get_basic_ios(this);
7161 base
->base
.vtable
= &MSVCP_basic_ostream_wchar_vtable
;
7163 ios_base_Addstd(&base
->base
);
7167 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@_N@Z */
7168 /* ??0?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@_N@Z */
7169 DEFINE_THISCALL_WRAPPER(basic_ostream_short_ctor_uninitialized
, 16)
7170 basic_ostream_wchar
* __thiscall
basic_ostream_short_ctor_uninitialized(basic_ostream_wchar
*this,
7171 int uninitialized
, bool addstd
, bool virt_init
)
7173 basic_ostream_wchar_ctor_uninitialized(this, uninitialized
, addstd
, virt_init
);
7174 basic_ostream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_ostream_short_vtable
;
7178 /* ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
7179 /* ??1?$basic_ostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
7180 /* ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UAE@XZ */
7181 /* ??1?$basic_ostream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
7182 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_dtor
, 4)
7183 void __thiscall
basic_ostream_wchar_dtor(basic_ios_wchar
*base
)
7185 basic_ostream_wchar
*this = basic_ostream_wchar_from_basic_ios(base
);
7187 /* don't destroy virtual base here */
7188 TRACE("(%p)\n", this);
7191 /* ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
7192 /* ??_D?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
7193 /* ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
7194 /* ??_D?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
7195 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_vbase_dtor
, 4)
7196 void __thiscall
basic_ostream_wchar_vbase_dtor(basic_ostream_wchar
*this)
7198 basic_ios_wchar
*base
= basic_ostream_wchar_to_basic_ios(this);
7200 TRACE("(%p)\n", this);
7202 basic_ostream_wchar_dtor(base
);
7203 basic_ios_wchar_dtor(base
);
7206 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_vector_dtor
, 8)
7207 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
7209 basic_ostream_wchar
*this = basic_ostream_wchar_from_basic_ios(base
);
7211 TRACE("(%p %x)\n", this, flags
);
7214 /* we have an array, with the number of elements stored before the first object */
7215 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
7217 for(i
=*ptr
-1; i
>=0; i
--)
7218 basic_ostream_wchar_vbase_dtor(this+i
);
7219 MSVCRT_operator_delete(ptr
);
7221 basic_ostream_wchar_vbase_dtor(this);
7223 MSVCRT_operator_delete(this);
7229 /* ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ */
7230 /* ?flush@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ */
7231 /* ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ */
7232 /* ?flush@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ */
7233 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_flush
, 4)
7234 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_flush(basic_ostream_wchar
*this)
7236 /* this function is not matching C++ specification */
7237 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7239 TRACE("(%p)\n", this);
7241 if(basic_ios_wchar_rdbuf_get(base
) && ios_base_good(&base
->base
)
7242 && basic_streambuf_wchar_pubsync(basic_ios_wchar_rdbuf_get(base
))==-1)
7243 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
7247 /* ?flush@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
7248 /* ?flush@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
7249 /* ?flush@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
7250 /* ?flush@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
7251 basic_ostream_wchar
* __cdecl
flush_ostream_wchar(basic_ostream_wchar
*ostream
)
7253 return basic_ostream_wchar_flush(ostream
);
7256 /* ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
7257 /* ?_Osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
7258 /* ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
7259 /* ?_Osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
7260 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar__Osfx
, 4)
7261 void __thiscall
basic_ostream_wchar__Osfx(basic_ostream_wchar
*this)
7263 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7265 TRACE("(%p)\n", this);
7267 if(base
->base
.fmtfl
& FMTFLAG_unitbuf
)
7268 basic_ostream_wchar_flush(this);
7271 /* ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
7272 /* ?osfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
7273 /* ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
7274 /* ?osfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
7275 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_osfx
, 4)
7276 void __thiscall
basic_ostream_wchar_osfx(basic_ostream_wchar
*this)
7278 TRACE("(%p)\n", this);
7279 basic_ostream_wchar__Osfx(this);
7282 static BOOL
basic_ostream_wchar_sentry_create(basic_ostream_wchar
*ostr
)
7284 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7286 if(basic_ios_wchar_rdbuf_get(base
))
7287 basic_streambuf_wchar__Lock(base
->strbuf
);
7289 if(ios_base_good(&base
->base
) && base
->stream
)
7290 basic_ostream_wchar_flush(base
->stream
);
7292 return ios_base_good(&base
->base
);
7295 static void basic_ostream_wchar_sentry_destroy(basic_ostream_wchar
*ostr
)
7297 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7299 if(ios_base_good(&base
->base
) && !__uncaught_exception())
7300 basic_ostream_wchar_osfx(ostr
);
7302 if(basic_ios_wchar_rdbuf_get(base
))
7303 basic_streambuf_wchar__Unlock(base
->strbuf
);
7306 /* ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE_NXZ */
7307 /* ?opfx@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA_NXZ */
7308 /* ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE_NXZ */
7309 /* ?opfx@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA_NXZ */
7310 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_opfx
, 4)
7311 bool __thiscall
basic_ostream_wchar_opfx(basic_ostream_wchar
*this)
7313 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7315 TRACE("(%p)\n", this);
7317 if(ios_base_good(&base
->base
) && base
->stream
)
7318 basic_ostream_wchar_flush(base
->stream
);
7319 return ios_base_good(&base
->base
);
7322 /* ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z */
7323 /* ?put@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z */
7324 /* ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z */
7325 /* ?put@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z */
7326 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_put
, 8)
7327 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_put(basic_ostream_wchar
*this, wchar_t ch
)
7329 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7331 TRACE("(%p %c)\n", this, ch
);
7333 if(!basic_ostream_wchar_sentry_create(this)
7334 || basic_streambuf_wchar_sputc(base
->strbuf
, ch
)==WEOF
) {
7335 basic_ostream_wchar_sentry_destroy(this);
7336 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
7340 basic_ostream_wchar_sentry_destroy(this);
7344 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@JH@Z */
7345 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z */
7346 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@JH@Z */
7347 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z */
7348 #if STREAMOFF_BITS == 64
7349 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp
, 16)
7351 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp
, 12)
7353 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_seekp(basic_ostream_wchar
*this, streamoff off
, int way
)
7355 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7357 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), way
);
7359 if(!ios_base_fail(&base
->base
)) {
7362 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
7363 &seek
, off
, way
, OPENMODE_out
);
7364 if(seek
.off
==-1 && seek
.pos
==0 && MBSTATET_TO_INT(&seek
.state
)==0)
7365 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
7370 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
7371 /* ?seekp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
7372 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
7373 /* ?seekp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
7374 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_seekp_fpos
, 28)
7375 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_seekp_fpos(basic_ostream_wchar
*this, fpos_mbstatet pos
)
7377 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7379 TRACE("(%p %s)\n", this, debugstr_fpos_mbstatet(&pos
));
7381 if(!ios_base_fail(&base
->base
)) {
7384 basic_streambuf_wchar_pubseekpos(basic_ios_wchar_rdbuf_get(base
),
7385 &seek
, pos
, OPENMODE_out
);
7386 if(seek
.off
==-1 && seek
.pos
==0 && MBSTATET_TO_INT(&seek
.state
)==0)
7387 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
7392 /* ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ */
7393 /* ?tellp@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
7394 /* ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ */
7395 /* ?tellp@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
7396 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_tellp
, 8)
7397 fpos_mbstatet
* __thiscall
basic_ostream_wchar_tellp(basic_ostream_wchar
*this, fpos_mbstatet
*ret
)
7399 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7401 TRACE("(%p)\n", this);
7403 if(!ios_base_fail(&base
->base
)) {
7404 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
7405 ret
, 0, SEEKDIR_cur
, OPENMODE_out
);
7409 memset(&ret
->state
, 0, sizeof(ret
->state
));
7414 /* ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PB_WH@Z */
7415 /* ?write@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEB_W_J@Z */
7416 /* ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV12@PBGH@Z */
7417 /* ?write@?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEBG_J@Z */
7418 #if STREAMSIZE_BITS == 64
7419 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_write
, 16)
7421 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_write
, 12)
7423 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_write(basic_ostream_wchar
*this, const wchar_t *str
, streamsize count
)
7425 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7427 TRACE("(%p %s %s)\n", this, debugstr_w(str
), wine_dbgstr_longlong(count
));
7429 if(!basic_ostream_wchar_sentry_create(this)
7430 || basic_streambuf_wchar_sputn(base
->strbuf
, str
, count
)!=count
) {
7431 basic_ostream_wchar_sentry_destroy(this);
7432 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
7436 basic_ostream_wchar_sentry_destroy(this);
7440 static basic_ostream_wchar
* basic_ostream_print_short(basic_ostream_wchar
*this, short val
, const num_put
*numput
)
7442 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7443 int state
= IOSTATE_goodbit
;
7445 TRACE("(%p %d)\n", this, val
);
7447 if(basic_ostream_wchar_sentry_create(this)) {
7448 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7449 ostreambuf_iterator_wchar dest
;
7451 memset(&dest
, 0, sizeof(dest
));
7452 dest
.strbuf
= strbuf
;
7453 num_put_wchar_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
),
7454 (ios_base_flags_get(&base
->base
) & FMTFLAG_basefield
& (FMTFLAG_oct
| FMTFLAG_hex
))
7455 ? (LONG
)((unsigned short)val
) : (LONG
)val
);
7457 basic_ostream_wchar_sentry_destroy(this);
7459 basic_ios_wchar_setstate(base
, state
);
7463 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@F@Z */
7464 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@F@Z */
7465 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_short
, 8)
7466 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_short(basic_ostream_wchar
*this, short val
)
7468 return basic_ostream_print_short(this, val
, num_put_wchar_use_facet(
7469 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7472 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@F@Z */
7473 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@F@Z */
7474 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_short
, 8)
7475 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_short(basic_ostream_wchar
*this, short val
)
7477 return basic_ostream_print_short(this, val
, num_put_short_use_facet(
7478 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7481 static basic_ostream_wchar
* basic_ostream_print_ushort(basic_ostream_wchar
*this, unsigned short val
, const num_put
*numput
)
7483 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7484 int state
= IOSTATE_goodbit
;
7486 TRACE("(%p %d)\n", this, val
);
7488 if(basic_ostream_wchar_sentry_create(this)) {
7489 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7490 ostreambuf_iterator_wchar dest
;
7492 memset(&dest
, 0, sizeof(dest
));
7493 dest
.strbuf
= strbuf
;
7494 num_put_wchar_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7496 basic_ostream_wchar_sentry_destroy(this);
7498 basic_ios_wchar_setstate(base
, state
);
7502 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@G@Z */
7503 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@G@Z */
7504 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ushort
, 8)
7505 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_ushort(basic_ostream_wchar
*this, unsigned short val
)
7507 return basic_ostream_print_ushort(this, val
, num_put_wchar_use_facet(
7508 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7511 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@G@Z */
7512 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@G@Z */
7513 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ushort
, 8)
7514 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_ushort(basic_ostream_wchar
*this, unsigned short val
)
7516 return basic_ostream_print_ushort(this, val
, num_put_short_use_facet(
7517 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7520 /* ??6std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@G@Z */
7521 /* ??6std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@G@Z */
7522 basic_ostream_wchar
* __cdecl
basic_ostream_short_print_ushort_global(basic_ostream_wchar
*ostr
, unsigned short val
)
7524 return basic_ostream_print_ushort(ostr
, val
, num_put_short_use_facet(
7525 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(ostr
)))));
7528 static basic_ostream_wchar
* basic_ostream_print_int(basic_ostream_wchar
*this, int val
, const num_put
*numput
)
7530 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7531 int state
= IOSTATE_goodbit
;
7533 TRACE("(%p %d)\n", this, val
);
7535 if(basic_ostream_wchar_sentry_create(this)) {
7536 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7537 ostreambuf_iterator_wchar dest
;
7539 memset(&dest
, 0, sizeof(dest
));
7540 dest
.strbuf
= strbuf
;
7541 num_put_wchar_put_long(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7543 basic_ostream_wchar_sentry_destroy(this);
7545 basic_ios_wchar_setstate(base
, state
);
7549 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@H@Z */
7550 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@H@Z */
7551 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@J@Z */
7552 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@J@Z */
7553 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_int
, 8)
7554 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_int(basic_ostream_wchar
*this, int val
)
7556 return basic_ostream_print_int(this, val
, num_put_wchar_use_facet(
7557 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7560 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@H@Z */
7561 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@H@Z */
7562 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@J@Z */
7563 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@J@Z */
7564 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_int
, 8)
7565 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_int(basic_ostream_wchar
*this, int val
)
7567 return basic_ostream_print_int(this, val
, num_put_short_use_facet(
7568 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7571 static basic_ostream_wchar
* basic_ostream_print_uint(basic_ostream_wchar
*this, unsigned int val
, const num_put
*numput
)
7573 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7574 int state
= IOSTATE_goodbit
;
7576 TRACE("(%p %u)\n", this, val
);
7578 if(basic_ostream_wchar_sentry_create(this)) {
7579 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7580 ostreambuf_iterator_wchar dest
;
7582 memset(&dest
, 0, sizeof(dest
));
7583 dest
.strbuf
= strbuf
;
7584 num_put_wchar_put_ulong(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7586 basic_ostream_wchar_sentry_destroy(this);
7588 basic_ios_wchar_setstate(base
, state
);
7592 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@I@Z */
7593 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@I@Z */
7594 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@K@Z */
7595 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@K@Z */
7596 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_uint
, 8)
7597 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_uint(basic_ostream_wchar
*this, unsigned int val
)
7599 return basic_ostream_print_uint(this, val
, num_put_wchar_use_facet(
7600 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7603 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@I@Z */
7604 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@I@Z */
7605 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@K@Z */
7606 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@K@Z */
7607 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_uint
, 8)
7608 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_uint(basic_ostream_wchar
*this, unsigned int val
)
7610 return basic_ostream_print_uint(this, val
, num_put_short_use_facet(
7611 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7614 static basic_ostream_wchar
* basic_ostream_print_float(basic_ostream_wchar
*this, float val
, const num_put
*numput
)
7616 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7617 int state
= IOSTATE_goodbit
;
7619 TRACE("(%p %f)\n", this, val
);
7621 if(basic_ostream_wchar_sentry_create(this)) {
7622 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7623 ostreambuf_iterator_wchar dest
;
7625 memset(&dest
, 0, sizeof(dest
));
7626 dest
.strbuf
= strbuf
;
7627 num_put_wchar_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7629 basic_ostream_wchar_sentry_destroy(this);
7631 basic_ios_wchar_setstate(base
, state
);
7635 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@M@Z */
7636 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@M@Z */
7637 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_float
, 8)
7638 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_float(basic_ostream_wchar
*this, float val
)
7640 return basic_ostream_print_float(this, val
, num_put_wchar_use_facet(
7641 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7644 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@M@Z */
7645 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@M@Z */
7646 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_float
, 8)
7647 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_float(basic_ostream_wchar
*this, float val
)
7649 return basic_ostream_print_float(this, val
, num_put_short_use_facet(
7650 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7653 static basic_ostream_wchar
* basic_ostream_print_double(basic_ostream_wchar
*this, double val
, const num_put
*numput
)
7655 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7656 int state
= IOSTATE_goodbit
;
7658 TRACE("(%p %lf)\n", this, val
);
7660 if(basic_ostream_wchar_sentry_create(this)) {
7661 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7662 ostreambuf_iterator_wchar dest
;
7664 memset(&dest
, 0, sizeof(dest
));
7665 dest
.strbuf
= strbuf
;
7666 num_put_wchar_put_double(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7668 basic_ostream_wchar_sentry_destroy(this);
7670 basic_ios_wchar_setstate(base
, state
);
7674 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@N@Z */
7675 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@N@Z */
7676 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_double
, 12)
7677 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_double(basic_ostream_wchar
*this, double val
)
7679 return basic_ostream_print_double(this, val
, num_put_wchar_use_facet(
7680 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7683 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@N@Z */
7684 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@N@Z */
7685 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_double
, 12)
7686 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_double(basic_ostream_wchar
*this, double val
)
7688 return basic_ostream_print_double(this, val
, num_put_short_use_facet(
7689 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7692 static basic_ostream_wchar
* basic_ostream_print_ldouble(basic_ostream_wchar
*this, double val
, const num_put
*numput
)
7694 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7695 int state
= IOSTATE_goodbit
;
7697 TRACE("(%p %lf)\n", this, val
);
7699 if(basic_ostream_wchar_sentry_create(this)) {
7700 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7701 ostreambuf_iterator_wchar dest
;
7703 memset(&dest
, 0, sizeof(dest
));
7704 dest
.strbuf
= strbuf
;
7705 num_put_wchar_put_ldouble(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7707 basic_ostream_wchar_sentry_destroy(this);
7709 basic_ios_wchar_setstate(base
, state
);
7713 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@O@Z */
7714 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@O@Z */
7715 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ldouble
, 12)
7716 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_ldouble(basic_ostream_wchar
*this, double val
)
7718 return basic_ostream_print_ldouble(this, val
, num_put_wchar_use_facet(
7719 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7722 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@O@Z */
7723 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@O@Z */
7724 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ldouble
, 12)
7725 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_ldouble(basic_ostream_wchar
*this, double val
)
7727 return basic_ostream_print_ldouble(this, val
, num_put_short_use_facet(
7728 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7731 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
7732 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
7733 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
7734 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
7735 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_streambuf
, 8)
7736 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_streambuf(basic_ostream_wchar
*this, basic_streambuf_wchar
*val
)
7738 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7739 IOSB_iostate state
= IOSTATE_badbit
;
7740 unsigned short c
= '\n';
7742 TRACE("(%p %p)\n", this, val
);
7744 if(basic_ostream_wchar_sentry_create(this)) {
7745 for(c
= basic_streambuf_wchar_sgetc(val
); c
!=WEOF
;
7746 c
= basic_streambuf_wchar_snextc(val
)) {
7747 state
= IOSTATE_goodbit
;
7749 if(basic_streambuf_wchar_sputc(base
->strbuf
, c
) == WEOF
) {
7750 state
= IOSTATE_badbit
;
7755 state
= IOSTATE_badbit
;
7757 basic_ostream_wchar_sentry_destroy(this);
7759 ios_base_width_set(&base
->base
, 0);
7760 basic_ios_wchar_setstate(base
, state
);
7764 static basic_ostream_wchar
* basic_ostream_print_ptr(basic_ostream_wchar
*this, const void *val
, const num_put
*numput
)
7766 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7767 int state
= IOSTATE_goodbit
;
7769 TRACE("(%p %p)\n", this, val
);
7771 if(basic_ostream_wchar_sentry_create(this)) {
7772 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7773 ostreambuf_iterator_wchar dest
;
7775 memset(&dest
, 0, sizeof(dest
));
7776 dest
.strbuf
= strbuf
;
7777 num_put_wchar_put_ptr(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7779 basic_ostream_wchar_sentry_destroy(this);
7781 basic_ios_wchar_setstate(base
, state
);
7785 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PBX@Z */
7786 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEBX@Z */
7787 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_ptr
, 8)
7788 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_ptr(basic_ostream_wchar
*this, const void *val
)
7790 return basic_ostream_print_ptr(this, val
, num_put_wchar_use_facet(
7791 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7794 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@PBX@Z */
7795 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEBX@Z */
7796 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_ptr
, 8)
7797 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_ptr(basic_ostream_wchar
*this, const void *val
)
7799 return basic_ostream_print_ptr(this, val
, num_put_short_use_facet(
7800 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7803 static basic_ostream_wchar
* basic_ostream_print_int64(basic_ostream_wchar
*this, __int64 val
, const num_put
*numput
)
7805 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7806 int state
= IOSTATE_goodbit
;
7808 TRACE("(%p)\n", this);
7810 if(basic_ostream_wchar_sentry_create(this)) {
7811 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7812 ostreambuf_iterator_wchar dest
;
7814 memset(&dest
, 0, sizeof(dest
));
7815 dest
.strbuf
= strbuf
;
7816 num_put_wchar_put_int64(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7818 basic_ostream_wchar_sentry_destroy(this);
7820 basic_ios_wchar_setstate(base
, state
);
7824 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_J@Z */
7825 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_J@Z */
7826 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_int64
, 12)
7827 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_int64(basic_ostream_wchar
*this, __int64 val
)
7829 return basic_ostream_print_int64(this, val
, num_put_wchar_use_facet(
7830 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7833 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_J@Z */
7834 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_J@Z */
7835 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_int64
, 12)
7836 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_int64(basic_ostream_wchar
*this, __int64 val
)
7838 return basic_ostream_print_int64(this, val
, num_put_short_use_facet(
7839 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7842 static basic_ostream_wchar
* basic_ostream_print_uint64(basic_ostream_wchar
*this, unsigned __int64 val
, const num_put
*numput
)
7844 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7845 int state
= IOSTATE_goodbit
;
7847 TRACE("(%p)\n", this);
7849 if(basic_ostream_wchar_sentry_create(this)) {
7850 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7851 ostreambuf_iterator_wchar dest
;
7853 memset(&dest
, 0, sizeof(dest
));
7854 dest
.strbuf
= strbuf
;
7855 num_put_wchar_put_uint64(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7857 basic_ostream_wchar_sentry_destroy(this);
7859 basic_ios_wchar_setstate(base
, state
);
7863 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_K@Z */
7864 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_K@Z */
7865 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_uint64
, 12)
7866 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_uint64(basic_ostream_wchar
*this, unsigned __int64 val
)
7868 return basic_ostream_print_uint64(this, val
, num_put_wchar_use_facet(
7869 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7872 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_K@Z */
7873 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_K@Z */
7874 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_uint64
, 12)
7875 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_uint64(basic_ostream_wchar
*this, unsigned __int64 val
)
7877 return basic_ostream_print_uint64(this, val
, num_put_short_use_facet(
7878 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7881 static basic_ostream_wchar
* basic_ostream_print_bool(basic_ostream_wchar
*this, bool val
, const num_put
*numput
)
7883 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(this);
7884 int state
= IOSTATE_goodbit
;
7886 TRACE("(%p %x)\n", this, val
);
7888 if(basic_ostream_wchar_sentry_create(this)) {
7889 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
7890 ostreambuf_iterator_wchar dest
;
7892 memset(&dest
, 0, sizeof(dest
));
7893 dest
.strbuf
= strbuf
;
7894 num_put_wchar_put_bool(numput
, &dest
, dest
, &base
->base
, basic_ios_wchar_fill_get(base
), val
);
7896 basic_ostream_wchar_sentry_destroy(this);
7898 basic_ios_wchar_setstate(base
, state
);
7902 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@_N@Z */
7903 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@_N@Z */
7904 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_bool
, 8)
7905 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_bool(basic_ostream_wchar
*this, bool val
)
7907 return basic_ostream_print_bool(this, val
, num_put_wchar_use_facet(
7908 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7911 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@_N@Z */
7912 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@_N@Z */
7913 DEFINE_THISCALL_WRAPPER(basic_ostream_short_print_bool
, 8)
7914 basic_ostream_wchar
* __thiscall
basic_ostream_short_print_bool(basic_ostream_wchar
*this, bool val
)
7916 return basic_ostream_print_bool(this, val
, num_put_short_use_facet(
7917 IOS_LOCALE(basic_ios_wchar_rdbuf_get(basic_ostream_wchar_get_basic_ios(this)))));
7920 /* ?ends@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
7921 /* ?ends@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
7922 /* ?ends@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
7923 /* ?ends@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
7924 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_ends(basic_ostream_wchar
*ostr
)
7926 TRACE("(%p)\n", ostr
);
7928 basic_ostream_wchar_put(ostr
, 0);
7932 /* ?endl@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
7933 /* ?endl@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
7934 /* ?endl@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@1@AAV21@@Z */
7935 /* ?endl@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
7936 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_endl(basic_ostream_wchar
*ostr
)
7938 TRACE("(%p)\n", ostr
);
7940 basic_ostream_wchar_put(ostr
, '\n');
7941 basic_ostream_wchar_flush(ostr
);
7945 /* ??$?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 */
7946 /* ??$?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 */
7947 /* ??$?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 */
7948 /* ??$?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 */
7949 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_print_bstr(basic_ostream_wchar
*ostr
, const basic_string_wchar
*str
)
7951 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
7952 IOSB_iostate state
= IOSTATE_goodbit
;
7954 TRACE("(%p %p)\n", ostr
, str
);
7956 if(basic_ostream_wchar_sentry_create(ostr
)) {
7957 size_t len
= MSVCP_basic_string_wchar_length(str
);
7958 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
7960 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
7961 for(; pad
!=0; pad
--) {
7962 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7963 state
= IOSTATE_badbit
;
7969 if(state
== IOSTATE_goodbit
) {
7970 if(basic_streambuf_wchar_sputn(base
->strbuf
, MSVCP_basic_string_wchar_c_str(str
), len
) != len
)
7971 state
= IOSTATE_badbit
;
7974 if(state
== IOSTATE_goodbit
) {
7975 for(; pad
!=0; pad
--) {
7976 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
7977 state
= IOSTATE_badbit
;
7983 base
->base
.wide
= 0;
7985 state
= IOSTATE_badbit
;
7987 basic_ostream_wchar_sentry_destroy(ostr
);
7989 basic_ios_wchar_setstate(base
, state
);
7993 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@_W@Z */
7994 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@_W@Z */
7995 /* ??$?6GU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@G@Z */
7996 /* ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@G@Z */
7997 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_print_ch(basic_ostream_wchar
*ostr
, wchar_t ch
)
7999 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
8000 IOSB_iostate state
= IOSTATE_goodbit
;
8002 TRACE("(%p %d)\n", ostr
, ch
);
8004 if(basic_ostream_wchar_sentry_create(ostr
)) {
8005 streamsize pad
= (base
->base
.wide
>1 ? base
->base
.wide
-1 : 0);
8007 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
8008 for(; pad
!=0; pad
--) {
8009 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
8010 state
= IOSTATE_badbit
;
8016 if(state
== IOSTATE_goodbit
) {
8017 if(basic_streambuf_wchar_sputc(base
->strbuf
, ch
) == WEOF
)
8018 state
= IOSTATE_badbit
;
8021 if(state
== IOSTATE_goodbit
) {
8022 for(; pad
!=0; pad
--) {
8023 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
8024 state
= IOSTATE_badbit
;
8030 base
->base
.wide
= 0;
8032 state
= IOSTATE_badbit
;
8034 basic_ostream_wchar_sentry_destroy(ostr
);
8036 basic_ios_wchar_setstate(base
, state
);
8040 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AAV10@PB_W@Z */
8041 /* ??$?6_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_ostream@_WU?$char_traits@_W@std@@@0@AEAV10@PEB_W@Z */
8042 /* ??$?6GU?$char_traits@G@std@@@std@@YAAAV?$basic_ostream@GU?$char_traits@G@std@@@0@AAV10@PBG@Z */
8043 /* ??$?6GU?$char_traits@G@std@@@std@@YAAEAV?$basic_ostream@GU?$char_traits@G@std@@@0@AEAV10@PEBG@Z */
8044 basic_ostream_wchar
* __cdecl
basic_ostream_wchar_print_str(basic_ostream_wchar
*ostr
, const wchar_t *str
)
8046 basic_ios_wchar
*base
= basic_ostream_wchar_get_basic_ios(ostr
);
8047 IOSB_iostate state
= IOSTATE_goodbit
;
8049 TRACE("(%p %s)\n", ostr
, debugstr_w(str
));
8051 if(basic_ostream_wchar_sentry_create(ostr
)) {
8052 size_t len
= wcslen(str
);
8053 streamsize pad
= (base
->base
.wide
>len
? base
->base
.wide
-len
: 0);
8055 if((base
->base
.fmtfl
& FMTFLAG_adjustfield
) != FMTFLAG_left
) {
8056 for(; pad
!=0; pad
--) {
8057 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
8058 state
= IOSTATE_badbit
;
8064 if(state
== IOSTATE_goodbit
) {
8065 if(basic_streambuf_wchar_sputn(base
->strbuf
, str
, len
) != len
)
8066 state
= IOSTATE_badbit
;
8069 if(state
== IOSTATE_goodbit
) {
8070 for(; pad
!=0; pad
--) {
8071 if(basic_streambuf_wchar_sputc(base
->strbuf
, base
->fillch
) == WEOF
) {
8072 state
= IOSTATE_badbit
;
8078 base
->base
.wide
= 0;
8080 state
= IOSTATE_badbit
;
8082 basic_ostream_wchar_sentry_destroy(ostr
);
8084 basic_ios_wchar_setstate(base
, state
);
8088 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
8089 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
8090 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
8091 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
8092 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func
, 8)
8093 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_func(basic_ostream_wchar
*this,
8094 basic_ostream_wchar
* (__cdecl
*pfunc
)(basic_ostream_wchar
*))
8096 TRACE("(%p %p)\n", this, pfunc
);
8101 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z */
8102 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z */
8103 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z */
8104 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z */
8105 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func_basic_ios
, 8)
8106 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_func_basic_ios(basic_ostream_wchar
*this,
8107 basic_ios_wchar
* (__cdecl
*pfunc
)(basic_ios_wchar
*))
8109 TRACE("(%p %p)\n", this, pfunc
);
8110 pfunc(basic_ostream_wchar_get_basic_ios(this));
8114 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
8115 /* ??6?$basic_ostream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
8116 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
8117 /* ??6?$basic_ostream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
8118 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_print_func_ios_base
, 8)
8119 basic_ostream_wchar
* __thiscall
basic_ostream_wchar_print_func_ios_base(
8120 basic_ostream_wchar
*this, ios_base
* (__cdecl
*pfunc
)(ios_base
*))
8122 TRACE("(%p %p)\n", this, pfunc
);
8123 pfunc(&basic_ostream_wchar_get_basic_ios(this)->base
);
8127 /* ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IAEXAAV12@@Z */
8128 /* ?swap@?$basic_ostream@GU?$char_traits@G@std@@@std@@IEAAXAEAV12@@Z */
8129 /* ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IAEXAAV12@@Z */
8130 /* ?swap@?$basic_ostream@_WU?$char_traits@_W@std@@@std@@IEAAXAEAV12@@Z */
8131 DEFINE_THISCALL_WRAPPER(basic_ostream_wchar_swap
, 8)
8132 void __thiscall
basic_ostream_wchar_swap(basic_ostream_wchar
*this, basic_ostream_wchar
*r
)
8134 TRACE("(%p %p)\n", this, r
);
8139 basic_ios_wchar_swap(basic_ostream_wchar_get_basic_ios(this),
8140 basic_ostream_wchar_get_basic_ios(r
));
8143 /* Caution: basic_istream uses virtual inheritance. */
8144 static inline basic_ios_char
* basic_istream_char_get_basic_ios(basic_istream_char
*this)
8146 return (basic_ios_char
*)((char*)this+this->vbtable
[1]);
8149 static inline basic_ios_char
* basic_istream_char_to_basic_ios(basic_istream_char
*ptr
)
8151 return (basic_ios_char
*)((char*)ptr
+basic_istream_char_vbtable
[1]);
8154 static inline basic_istream_char
* basic_istream_char_from_basic_ios(basic_ios_char
*ptr
)
8156 return (basic_istream_char
*)((char*)ptr
-basic_istream_char_vbtable
[1]);
8159 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z */
8160 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N1@Z */
8161 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor_init
, 20)
8162 basic_istream_char
* __thiscall
basic_istream_char_ctor_init(basic_istream_char
*this,
8163 basic_streambuf_char
*strbuf
, bool isstd
, bool noinit
, bool virt_init
)
8165 basic_ios_char
*base
;
8167 TRACE("(%p %p %d %d %d)\n", this, strbuf
, isstd
, noinit
, virt_init
);
8170 this->vbtable
= basic_istream_char_vbtable
;
8171 base
= basic_istream_char_get_basic_ios(this);
8172 INIT_BASIC_IOS_VTORDISP(base
);
8173 basic_ios_char_ctor(base
);
8175 base
= basic_istream_char_get_basic_ios(this);
8178 base
->base
.vtable
= &MSVCP_basic_istream_char_vtable
;
8181 basic_ios_char_init(base
, strbuf
, isstd
);
8185 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
8186 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@_N@Z */
8187 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor
, 16)
8188 basic_istream_char
* __thiscall
basic_istream_char_ctor(basic_istream_char
*this,
8189 basic_streambuf_char
*strbuf
, bool isstd
, bool virt_init
)
8191 return basic_istream_char_ctor_init(this, strbuf
, isstd
, FALSE
, virt_init
);
8194 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QAE@W4_Uninitialized@1@@Z */
8195 /* ??0?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
8196 DEFINE_THISCALL_WRAPPER(basic_istream_char_ctor_uninitialized
, 12)
8197 basic_istream_char
* __thiscall
basic_istream_char_ctor_uninitialized(basic_istream_char
*this,
8198 int uninitialized
, bool virt_init
)
8200 basic_ios_char
*base
;
8202 TRACE("(%p %d %d)\n", this, uninitialized
, virt_init
);
8205 this->vbtable
= basic_istream_char_vbtable
;
8206 base
= basic_istream_char_get_basic_ios(this);
8207 INIT_BASIC_IOS_VTORDISP(base
);
8208 basic_ios_char_ctor(base
);
8210 base
= basic_istream_char_get_basic_ios(this);
8213 base
->base
.vtable
= &MSVCP_basic_istream_char_vtable
;
8214 ios_base_Addstd(&base
->base
);
8218 /* ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UAE@XZ */
8219 /* ??1?$basic_istream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
8220 DEFINE_THISCALL_WRAPPER(basic_istream_char_dtor
, 4)
8221 void __thiscall
basic_istream_char_dtor(basic_ios_char
*base
)
8223 basic_istream_char
*this = basic_istream_char_from_basic_ios(base
);
8225 /* don't destroy virtual base here */
8226 TRACE("(%p)\n", this);
8229 /* ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ */
8230 /* ??_D?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
8231 DEFINE_THISCALL_WRAPPER(basic_istream_char_vbase_dtor
, 4)
8232 void __thiscall
basic_istream_char_vbase_dtor(basic_istream_char
*this)
8234 basic_ios_char
*base
= basic_istream_char_to_basic_ios(this);
8236 TRACE("(%p)\n", this);
8238 basic_istream_char_dtor(base
);
8239 basic_ios_char_dtor(base
);
8242 DEFINE_THISCALL_WRAPPER(basic_istream_char_vector_dtor
, 8)
8243 basic_istream_char
* __thiscall
basic_istream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
8245 basic_istream_char
*this = basic_istream_char_from_basic_ios(base
);
8247 TRACE("(%p %x)\n", this, flags
);
8250 /* we have an array, with the number of elements stored before the first object */
8251 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
8253 for(i
=*ptr
-1; i
>=0; i
--)
8254 basic_istream_char_vbase_dtor(this+i
);
8255 MSVCRT_operator_delete(ptr
);
8257 basic_istream_char_vbase_dtor(this);
8259 MSVCRT_operator_delete(this);
8265 /* ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z */
8266 /* ?_Ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z */
8267 DEFINE_THISCALL_WRAPPER(basic_istream_char__Ipfx
, 8)
8268 bool __thiscall
basic_istream_char__Ipfx(basic_istream_char
*this, bool noskip
)
8270 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8272 TRACE("(%p %d)\n", this, noskip
);
8274 if(ios_base_good(&base
->base
)) {
8275 if(basic_ios_char_tie_get(base
))
8276 basic_ostream_char_flush(basic_ios_char_tie_get(base
));
8278 if(!noskip
&& (ios_base_flags_get(&base
->base
) & FMTFLAG_skipws
)) {
8279 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8280 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(base
->strbuf
));
8283 for(ch
= basic_streambuf_char_sgetc(strbuf
); ;
8284 ch
= basic_streambuf_char_snextc(strbuf
)) {
8286 basic_ios_char_setstate(base
, IOSTATE_eofbit
);
8290 if(!ctype_char_is_ch(ctype
, _SPACE
|_BLANK
, ch
))
8296 if(!ios_base_good(&base
->base
)) {
8297 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8304 /* ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE_N_N@Z */
8305 /* ?ipfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_N_N@Z */
8306 DEFINE_THISCALL_WRAPPER(basic_istream_char_ipfx
, 8)
8307 bool __thiscall
basic_istream_char_ipfx(basic_istream_char
*this, bool noskip
)
8309 return basic_istream_char__Ipfx(this, noskip
);
8312 /* ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXXZ */
8313 /* ?isfx@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
8314 DEFINE_THISCALL_WRAPPER(basic_istream_char_isfx
, 4)
8315 void __thiscall
basic_istream_char_isfx(basic_istream_char
*this)
8317 TRACE("(%p)\n", this);
8320 static BOOL
basic_istream_char_sentry_create(basic_istream_char
*istr
, bool noskip
)
8322 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istr
);
8324 if(basic_ios_char_rdbuf_get(base
))
8325 call_basic_streambuf_char__Lock(base
->strbuf
);
8327 return basic_istream_char_ipfx(istr
, noskip
);
8330 static void basic_istream_char_sentry_destroy(basic_istream_char
*istr
)
8332 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istr
);
8334 if(basic_ios_char_rdbuf_get(base
))
8335 call_basic_streambuf_char__Unlock(base
->strbuf
);
8338 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBEHXZ */
8339 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QEBA_JXZ */
8340 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBA_JXZ */
8341 /* ?gcount@?$basic_istream@DU?$char_traits@D@std@@@std@@QBE_JXZ */
8342 DEFINE_THISCALL_WRAPPER(basic_istream_char_gcount
, 4)
8343 streamsize __thiscall
basic_istream_char_gcount(const basic_istream_char
*this)
8345 TRACE("(%p)\n", this);
8349 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
8350 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
8351 DEFINE_THISCALL_WRAPPER(basic_istream_char_get
, 4)
8352 int __thiscall
basic_istream_char_get(basic_istream_char
*this)
8354 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8357 TRACE("(%p)\n", this);
8361 if(!basic_istream_char_sentry_create(this, TRUE
)) {
8362 basic_istream_char_sentry_destroy(this);
8366 ret
= basic_streambuf_char_sbumpc(basic_ios_char_rdbuf_get(base
));
8367 basic_istream_char_sentry_destroy(this);
8369 basic_ios_char_setstate(base
, IOSTATE_eofbit
|IOSTATE_failbit
);
8376 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAD@Z */
8377 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAD@Z */
8378 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_ch
, 8)
8379 basic_istream_char
* __thiscall
basic_istream_char_get_ch(basic_istream_char
*this, char *ch
)
8383 TRACE("(%p %p)\n", this, ch
);
8385 ret
= basic_istream_char_get(this);
8391 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADHD@Z */
8392 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z */
8393 #if STREAMSIZE_BITS == 64
8394 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str_delim
, 20)
8396 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str_delim
, 16)
8398 basic_istream_char
* __thiscall
basic_istream_char_get_str_delim(basic_istream_char
*this, char *str
, streamsize count
, char delim
)
8400 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8403 TRACE("(%p %p %s %s)\n", this, str
, wine_dbgstr_longlong(count
), debugstr_an(&delim
, 1));
8407 if(basic_istream_char_sentry_create(this, TRUE
)) {
8408 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8410 for(ch
= basic_streambuf_char_sgetc(strbuf
); count
>1;
8411 ch
= basic_streambuf_char_snextc(strbuf
)) {
8412 if(ch
==EOF
|| ch
==delim
)
8420 basic_istream_char_sentry_destroy(this);
8422 basic_ios_char_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
8423 (ch
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
8429 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
8430 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
8431 #if STREAMSIZE_BITS == 64
8432 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str
, 16)
8434 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_str
, 12)
8436 basic_istream_char
* __thiscall
basic_istream_char_get_str(basic_istream_char
*this, char *str
, streamsize count
)
8438 return basic_istream_char_get_str_delim(this, str
, count
, '\n');
8441 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z */
8442 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@D@Z */
8443 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_streambuf_delim
, 12)
8444 basic_istream_char
* __thiscall
basic_istream_char_get_streambuf_delim(basic_istream_char
*this, basic_streambuf_char
*strbuf
, char delim
)
8446 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8449 TRACE("(%p %p %s)\n", this, strbuf
, debugstr_an(&delim
, 1));
8453 if(basic_istream_char_sentry_create(this, TRUE
)) {
8454 basic_streambuf_char
*strbuf_read
= basic_ios_char_rdbuf_get(base
);
8456 for(ch
= basic_streambuf_char_sgetc(strbuf_read
); ;
8457 ch
= basic_streambuf_char_snextc(strbuf_read
)) {
8458 if(ch
==EOF
|| ch
==delim
)
8461 if(basic_streambuf_char_sputc(strbuf
, ch
) == EOF
)
8466 basic_istream_char_sentry_destroy(this);
8468 basic_ios_char_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
8469 (ch
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
8473 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@AAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z */
8474 /* ?get@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@DU?$char_traits@D@std@@@2@@Z */
8475 DEFINE_THISCALL_WRAPPER(basic_istream_char_get_streambuf
, 8)
8476 basic_istream_char
* __thiscall
basic_istream_char_get_streambuf(basic_istream_char
*this, basic_streambuf_char
*strbuf
)
8478 return basic_istream_char_get_streambuf_delim(this, strbuf
, '\n');
8481 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADHD@Z */
8482 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_JD@Z */
8483 #if STREAMSIZE_BITS == 64
8484 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline_delim
, 20)
8486 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline_delim
, 16)
8488 basic_istream_char
* __thiscall
basic_istream_char_getline_delim(basic_istream_char
*this, char *str
, streamsize count
, char delim
)
8490 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8491 int ch
= (unsigned char)delim
;
8493 TRACE("(%p %p %s %s)\n", this, str
, wine_dbgstr_longlong(count
), debugstr_an(&delim
, 1));
8497 if(basic_istream_char_sentry_create(this, TRUE
) && count
>0) {
8498 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8501 ch
= basic_streambuf_char_sbumpc(strbuf
);
8503 if(ch
==EOF
|| ch
==(unsigned char)delim
)
8511 if(ch
== (unsigned char)delim
)
8513 else if(ch
!= EOF
) {
8514 ch
= basic_streambuf_char_sgetc(strbuf
);
8516 if(ch
== (unsigned char)delim
) {
8517 basic_streambuf_char__Gninc(strbuf
);
8522 basic_istream_char_sentry_destroy(this);
8524 basic_ios_char_setstate(base
, (ch
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
) |
8525 (!this->count
|| (ch
!=(unsigned char)delim
&& ch
!=EOF
) ? IOSTATE_failbit
: IOSTATE_goodbit
));
8531 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
8532 /* ?getline@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
8533 #if STREAMSIZE_BITS == 64
8534 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline
, 16)
8536 DEFINE_THISCALL_WRAPPER(basic_istream_char_getline
, 12)
8538 basic_istream_char
* __thiscall
basic_istream_char_getline(basic_istream_char
*this, char *str
, streamsize count
)
8540 return basic_istream_char_getline_delim(this, str
, count
, '\n');
8543 /* ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@HH@Z */
8544 /* ?ignore@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
8545 #if STREAMSIZE_BITS == 64
8546 DEFINE_THISCALL_WRAPPER(basic_istream_char_ignore
, 16)
8548 DEFINE_THISCALL_WRAPPER(basic_istream_char_ignore
, 12)
8550 basic_istream_char
* __thiscall
basic_istream_char_ignore(basic_istream_char
*this, streamsize count
, int delim
)
8552 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8553 int ch
= (unsigned char)delim
;
8556 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(count
), delim
);
8560 if(basic_istream_char_sentry_create(this, TRUE
)) {
8561 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8562 state
= IOSTATE_goodbit
;
8565 ch
= basic_streambuf_char_sbumpc(strbuf
);
8568 state
= IOSTATE_eofbit
;
8576 if(count
!= INT_MAX
)
8580 state
= IOSTATE_failbit
;
8581 basic_istream_char_sentry_destroy(this);
8583 basic_ios_char_setstate(base
, state
);
8587 /* ?ws@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@1@AAV21@@Z */
8588 /* ?ws@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@1@AEAV21@@Z */
8589 basic_istream_char
* __cdecl
ws_basic_istream_char(basic_istream_char
*istream
)
8591 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
8594 TRACE("(%p)\n", istream
);
8596 if(basic_istream_char_sentry_create(istream
, TRUE
)) {
8597 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8598 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(strbuf
));
8600 for(ch
= basic_streambuf_char_sgetc(strbuf
); ctype_char_is_ch(ctype
, _SPACE
, ch
);
8601 ch
= basic_streambuf_char_snextc(strbuf
)) {
8606 basic_istream_char_sentry_destroy(istream
);
8609 basic_ios_char_setstate(base
, IOSTATE_eofbit
);
8613 /* ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
8614 /* ?peek@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
8615 DEFINE_THISCALL_WRAPPER(basic_istream_char_peek
, 4)
8616 int __thiscall
basic_istream_char_peek(basic_istream_char
*this)
8618 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8621 TRACE("(%p)\n", this);
8625 if(basic_istream_char_sentry_create(this, TRUE
))
8626 ret
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
));
8627 basic_istream_char_sentry_destroy(this);
8630 basic_ios_char_setstate(base
, IOSTATE_eofbit
);
8635 /* ?_Read_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADIH@Z */
8636 /* ?_Read_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_K_J@Z */
8637 #if STREAMSIZE_BITS == 64
8638 DEFINE_THISCALL_WRAPPER(basic_istream_char__Read_s
, 20)
8640 DEFINE_THISCALL_WRAPPER(basic_istream_char__Read_s
, 16)
8642 basic_istream_char
* __thiscall
basic_istream_char__Read_s(basic_istream_char
*this, char *str
, size_t size
, streamsize count
)
8644 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8645 IOSB_iostate state
= IOSTATE_goodbit
;
8647 TRACE("(%p %p %Iu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
8649 if(basic_istream_char_sentry_create(this, TRUE
)) {
8650 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8652 this->count
= basic_streambuf_char__Sgetn_s(strbuf
, str
, size
, count
);
8653 if(this->count
!= count
)
8654 state
|= IOSTATE_failbit
| IOSTATE_eofbit
;
8658 basic_istream_char_sentry_destroy(this);
8660 basic_ios_char_setstate(base
, state
);
8664 /* ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@PADH@Z */
8665 /* ?read@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@PEAD_J@Z */
8666 #if STREAMSIZE_BITS == 64
8667 DEFINE_THISCALL_WRAPPER(basic_istream_char_read
, 16)
8669 DEFINE_THISCALL_WRAPPER(basic_istream_char_read
, 12)
8671 basic_istream_char
* __thiscall
basic_istream_char_read(basic_istream_char
*this, char *str
, streamsize count
)
8673 return basic_istream_char__Read_s(this, str
, -1, count
);
8676 /* ?_Readsome_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHPADIH@Z */
8677 /* ?_Readsome_s@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_K_J@Z */
8678 #if STREAMSIZE_BITS == 64
8679 DEFINE_THISCALL_WRAPPER(basic_istream_char__Readsome_s
, 20)
8681 DEFINE_THISCALL_WRAPPER(basic_istream_char__Readsome_s
, 16)
8683 streamsize __thiscall
basic_istream_char__Readsome_s(basic_istream_char
*this, char *str
, size_t size
, streamsize count
)
8685 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8686 IOSB_iostate state
= IOSTATE_goodbit
;
8688 TRACE("(%p %p %Iu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
8692 if(basic_istream_char_sentry_create(this, TRUE
)) {
8693 streamsize avail
= basic_streambuf_char_in_avail(basic_ios_char_rdbuf_get(base
));
8698 state
|= IOSTATE_eofbit
;
8700 basic_istream_char__Read_s(this, str
, size
, avail
);
8702 state
|= IOSTATE_failbit
;
8704 basic_istream_char_sentry_destroy(this);
8706 basic_ios_char_setstate(base
, state
);
8710 /* ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHPADH@Z */
8711 /* ?readsome@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA_JPEAD_J@Z */
8712 #if STREAMSIZE_BITS == 64
8713 DEFINE_THISCALL_WRAPPER(basic_istream_char_readsome
, 16)
8715 DEFINE_THISCALL_WRAPPER(basic_istream_char_readsome
, 12)
8717 streamsize __thiscall
basic_istream_char_readsome(basic_istream_char
*this, char *str
, streamsize count
)
8719 return basic_istream_char__Readsome_s(this, str
, count
, count
);
8722 /* ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@D@Z */
8723 /* ?putback@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@D@Z */
8724 DEFINE_THISCALL_WRAPPER(basic_istream_char_putback
, 8)
8725 basic_istream_char
* __thiscall
basic_istream_char_putback(basic_istream_char
*this, char ch
)
8727 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8728 IOSB_iostate state
= IOSTATE_goodbit
;
8730 TRACE("(%p %c)\n", this, ch
);
8734 if(basic_istream_char_sentry_create(this, TRUE
)) {
8735 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8737 if(!ios_base_good(&base
->base
))
8738 state
|= IOSTATE_failbit
;
8739 else if(!strbuf
|| basic_streambuf_char_sputbackc(strbuf
, ch
)==EOF
)
8740 state
|= IOSTATE_badbit
;
8742 basic_istream_char_sentry_destroy(this);
8744 basic_ios_char_setstate(base
, state
);
8748 /* ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@XZ */
8749 /* ?unget@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@XZ */
8750 DEFINE_THISCALL_WRAPPER(basic_istream_char_unget
, 4)
8751 basic_istream_char
* __thiscall
basic_istream_char_unget(basic_istream_char
*this)
8753 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8754 IOSB_iostate state
= IOSTATE_goodbit
;
8756 TRACE("(%p)\n", this);
8760 if(basic_istream_char_sentry_create(this, TRUE
)) {
8761 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8763 if(!ios_base_good(&base
->base
))
8764 state
|= IOSTATE_failbit
;
8765 else if(!strbuf
|| basic_streambuf_char_sungetc(strbuf
)==EOF
)
8766 state
|= IOSTATE_badbit
;
8768 basic_istream_char_sentry_destroy(this);
8770 basic_ios_char_setstate(base
, state
);
8774 /* ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEHXZ */
8775 /* ?sync@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAHXZ */
8776 DEFINE_THISCALL_WRAPPER(basic_istream_char_sync
, 4)
8777 int __thiscall
basic_istream_char_sync(basic_istream_char
*this)
8779 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8780 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8782 TRACE("(%p)\n", this);
8787 if(basic_istream_char_sentry_create(this, TRUE
)) {
8788 if(basic_streambuf_char_pubsync(strbuf
) != -1) {
8789 basic_istream_char_sentry_destroy(this);
8793 basic_istream_char_sentry_destroy(this);
8795 basic_ios_char_setstate(base
, IOSTATE_badbit
);
8799 /* ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAE?AV?$fpos@H@2@XZ */
8800 /* ?tellg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
8801 DEFINE_THISCALL_WRAPPER(basic_istream_char_tellg
, 8)
8802 fpos_mbstatet
* __thiscall
basic_istream_char_tellg(basic_istream_char
*this, fpos_mbstatet
*ret
)
8804 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8806 TRACE("(%p %p)\n", this, ret
);
8808 #if _MSVCP_VER >= 110
8809 if(basic_istream_char_sentry_create(this, TRUE
)) {
8810 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
8811 ret
, 0, SEEKDIR_cur
, OPENMODE_in
);
8815 memset(&ret
->state
, 0, sizeof(ret
->state
));
8817 basic_istream_char_sentry_destroy(this);
8819 if(ios_base_fail(&base
->base
)) {
8822 memset(&ret
->state
, 0, sizeof(ret
->state
));
8826 basic_streambuf_char_pubseekoff(basic_ios_char_rdbuf_get(base
),
8827 ret
, 0, SEEKDIR_cur
, OPENMODE_in
);
8833 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@JW4seekdir@ios_base@2@@Z */
8834 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JW4seekdir@ios_base@2@@Z */
8835 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@JH@Z */
8836 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@_JH@Z */
8837 #if STREAMOFF_BITS == 64
8838 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg
, 16)
8840 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg
, 12)
8842 basic_istream_char
* __thiscall
basic_istream_char_seekg(basic_istream_char
*this, streamoff off
, int dir
)
8844 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8845 #if _MSVCP_VER >= 110
8848 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), dir
);
8850 state
= ios_base_rdstate(&base
->base
);
8851 ios_base_clear(&base
->base
, state
& ~IOSTATE_eofbit
);
8853 if(basic_istream_char_sentry_create(this, TRUE
)) {
8854 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8857 basic_streambuf_char_pubseekoff(strbuf
, &ret
, off
, dir
, OPENMODE_in
);
8859 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
8860 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8862 basic_istream_char_sentry_destroy(this);
8864 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), dir
);
8866 if(!ios_base_fail(&base
->base
)) {
8867 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8870 basic_streambuf_char_pubseekoff(strbuf
, &ret
, off
, dir
, OPENMODE_in
);
8872 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
8873 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8875 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8878 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8883 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
8884 /* ?seekg@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
8885 DEFINE_THISCALL_WRAPPER(basic_istream_char_seekg_fpos
, 28)
8886 basic_istream_char
* __thiscall
basic_istream_char_seekg_fpos(basic_istream_char
*this, fpos_mbstatet pos
)
8888 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8889 #if _MSVCP_VER >= 110
8892 TRACE("(%p %s)\n", this, debugstr_fpos_mbstatet(&pos
));
8894 state
= ios_base_rdstate(&base
->base
);
8895 ios_base_clear(&base
->base
, state
& ~IOSTATE_eofbit
);
8897 if(basic_istream_char_sentry_create(this, TRUE
)) {
8898 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8901 basic_streambuf_char_pubseekpos(strbuf
, &ret
, pos
, OPENMODE_in
);
8903 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
8904 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8906 basic_istream_char_sentry_destroy(this);
8908 TRACE("(%p %s)\n", this, debugstr_fpos_mbstatet(&pos
));
8910 if(!ios_base_fail(&base
->base
)) {
8911 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8914 basic_streambuf_char_pubseekpos(strbuf
, &ret
, pos
, OPENMODE_in
);
8916 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
8917 basic_ios_char_setstate(base
, IOSTATE_failbit
);
8919 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8922 basic_ios_char_clear(base
, IOSTATE_goodbit
);
8927 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAF@Z */
8928 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAF@Z */
8929 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_short
, 8)
8930 basic_istream_char
* __thiscall
basic_istream_char_read_short(basic_istream_char
*this, short *v
)
8932 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8933 int state
= IOSTATE_goodbit
;
8935 TRACE("(%p %p)\n", this, v
);
8937 if(basic_istream_char_sentry_create(this, FALSE
)) {
8938 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8939 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8940 istreambuf_iterator_char first
={0}, last
={0};
8943 first
.strbuf
= strbuf
;
8944 num_get_char_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, &tmp
);
8946 if(!(state
&IOSTATE_failbit
) && tmp
==(LONG
)((short)tmp
))
8949 state
|= IOSTATE_failbit
;
8951 basic_istream_char_sentry_destroy(this);
8953 basic_ios_char_setstate(base
, state
);
8957 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAG@Z */
8958 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAG@Z */
8959 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ushort
, 8)
8960 basic_istream_char
* __thiscall
basic_istream_char_read_ushort(basic_istream_char
*this, unsigned short *v
)
8962 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8963 int state
= IOSTATE_goodbit
;
8965 TRACE("(%p %p)\n", this, v
);
8967 if(basic_istream_char_sentry_create(this, FALSE
)) {
8968 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8969 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8970 istreambuf_iterator_char first
={0}, last
={0};
8972 first
.strbuf
= strbuf
;
8973 num_get_char_get_ushort(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8975 basic_istream_char_sentry_destroy(this);
8977 basic_ios_char_setstate(base
, state
);
8981 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAH@Z */
8982 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAH@Z */
8983 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_int
, 8)
8984 basic_istream_char
* __thiscall
basic_istream_char_read_int(basic_istream_char
*this, int *v
)
8986 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
8987 int state
= IOSTATE_goodbit
;
8989 TRACE("(%p %p)\n", this, v
);
8991 if(basic_istream_char_sentry_create(this, FALSE
)) {
8992 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
8993 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
8994 istreambuf_iterator_char first
={0}, last
={0};
8996 first
.strbuf
= strbuf
;
8997 num_get_char_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
8999 basic_istream_char_sentry_destroy(this);
9001 basic_ios_char_setstate(base
, state
);
9005 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAI@Z */
9006 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAI@Z */
9007 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_uint
, 8)
9008 basic_istream_char
* __thiscall
basic_istream_char_read_uint(basic_istream_char
*this, unsigned int *v
)
9010 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9011 int state
= IOSTATE_goodbit
;
9013 TRACE("(%p %p)\n", this, v
);
9015 if(basic_istream_char_sentry_create(this, FALSE
)) {
9016 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9017 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9018 istreambuf_iterator_char first
={0}, last
={0};
9020 first
.strbuf
= strbuf
;
9021 num_get_char_get_uint(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9023 basic_istream_char_sentry_destroy(this);
9025 basic_ios_char_setstate(base
, state
);
9029 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAJ@Z */
9030 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAJ@Z */
9031 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_long
, 8)
9032 basic_istream_char
* __thiscall
basic_istream_char_read_long(basic_istream_char
*this, LONG
*v
)
9034 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9035 int state
= IOSTATE_goodbit
;
9037 TRACE("(%p %p)\n", this, v
);
9039 if(basic_istream_char_sentry_create(this, FALSE
)) {
9040 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9041 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9042 istreambuf_iterator_char first
={0}, last
={0};
9044 first
.strbuf
= strbuf
;
9045 num_get_char_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9047 basic_istream_char_sentry_destroy(this);
9049 basic_ios_char_setstate(base
, state
);
9053 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAK@Z */
9054 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAK@Z */
9055 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ulong
, 8)
9056 basic_istream_char
* __thiscall
basic_istream_char_read_ulong(basic_istream_char
*this, ULONG
*v
)
9058 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9059 int state
= IOSTATE_goodbit
;
9061 TRACE("(%p %p)\n", this, v
);
9063 if(basic_istream_char_sentry_create(this, FALSE
)) {
9064 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9065 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9066 istreambuf_iterator_char first
={0}, last
={0};
9068 first
.strbuf
= strbuf
;
9069 num_get_char_get_ulong(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9071 basic_istream_char_sentry_destroy(this);
9073 basic_ios_char_setstate(base
, state
);
9077 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAM@Z */
9078 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAM@Z */
9079 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_float
, 8)
9080 basic_istream_char
* __thiscall
basic_istream_char_read_float(basic_istream_char
*this, float *v
)
9082 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9083 int state
= IOSTATE_goodbit
;
9085 TRACE("(%p %p)\n", this, v
);
9087 if(basic_istream_char_sentry_create(this, FALSE
)) {
9088 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9089 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9090 istreambuf_iterator_char first
={0}, last
={0};
9092 first
.strbuf
= strbuf
;
9093 num_get_char_get_float(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9095 basic_istream_char_sentry_destroy(this);
9097 basic_ios_char_setstate(base
, state
);
9101 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAN@Z */
9102 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAN@Z */
9103 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_double
, 8)
9104 basic_istream_char
* __thiscall
basic_istream_char_read_double(basic_istream_char
*this, double *v
)
9106 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9107 int state
= IOSTATE_goodbit
;
9109 TRACE("(%p %p)\n", this, v
);
9111 if(basic_istream_char_sentry_create(this, FALSE
)) {
9112 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9113 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9114 istreambuf_iterator_char first
={0}, last
={0};
9116 first
.strbuf
= strbuf
;
9117 num_get_char_get_double(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9119 basic_istream_char_sentry_destroy(this);
9121 basic_ios_char_setstate(base
, state
);
9125 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAO@Z */
9126 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAO@Z */
9127 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ldouble
, 8)
9128 basic_istream_char
* __thiscall
basic_istream_char_read_ldouble(basic_istream_char
*this, double *v
)
9130 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9131 int state
= IOSTATE_goodbit
;
9133 TRACE("(%p %p)\n", this, v
);
9135 if(basic_istream_char_sentry_create(this, FALSE
)) {
9136 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9137 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9138 istreambuf_iterator_char first
={0}, last
={0};
9140 first
.strbuf
= strbuf
;
9141 num_get_char_get_ldouble(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9143 basic_istream_char_sentry_destroy(this);
9145 basic_ios_char_setstate(base
, state
);
9149 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AAPAX@Z */
9150 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
9151 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_ptr
, 8)
9152 basic_istream_char
* __thiscall
basic_istream_char_read_ptr(basic_istream_char
*this, void **v
)
9154 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9155 int state
= IOSTATE_goodbit
;
9157 TRACE("(%p %p)\n", this, v
);
9159 if(basic_istream_char_sentry_create(this, FALSE
)) {
9160 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9161 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9162 istreambuf_iterator_char first
={0}, last
={0};
9164 first
.strbuf
= strbuf
;
9165 num_get_char_get_void(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9167 basic_istream_char_sentry_destroy(this);
9169 basic_ios_char_setstate(base
, state
);
9173 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_J@Z */
9174 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_J@Z */
9175 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_int64
, 8)
9176 basic_istream_char
* __thiscall
basic_istream_char_read_int64(basic_istream_char
*this, __int64
*v
)
9178 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9179 int state
= IOSTATE_goodbit
;
9181 TRACE("(%p %p)\n", this, v
);
9183 if(basic_istream_char_sentry_create(this, FALSE
)) {
9184 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9185 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9186 istreambuf_iterator_char first
={0}, last
={0};
9188 first
.strbuf
= strbuf
;
9189 num_get_char_get_int64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9191 basic_istream_char_sentry_destroy(this);
9193 basic_ios_char_setstate(base
, state
);
9197 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_K@Z */
9198 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_K@Z */
9199 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_uint64
, 8)
9200 basic_istream_char
* __thiscall
basic_istream_char_read_uint64(basic_istream_char
*this, unsigned __int64
*v
)
9202 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9203 int state
= IOSTATE_goodbit
;
9205 TRACE("(%p %p)\n", this, v
);
9207 if(basic_istream_char_sentry_create(this, FALSE
)) {
9208 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9209 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9210 istreambuf_iterator_char first
={0}, last
={0};
9212 first
.strbuf
= strbuf
;
9213 num_get_char_get_uint64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9215 basic_istream_char_sentry_destroy(this);
9217 basic_ios_char_setstate(base
, state
);
9221 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@AA_N@Z */
9222 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@AEA_N@Z */
9223 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_bool
, 8)
9224 basic_istream_char
* __thiscall
basic_istream_char_read_bool(basic_istream_char
*this, bool *v
)
9226 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9227 int state
= IOSTATE_goodbit
;
9229 TRACE("(%p %p)\n", this, v
);
9231 if(basic_istream_char_sentry_create(this, FALSE
)) {
9232 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9233 const num_get
*numget
= num_get_char_use_facet(IOS_LOCALE(strbuf
));
9234 istreambuf_iterator_char first
={0}, last
={0};
9236 first
.strbuf
= strbuf
;
9237 num_get_char_get_bool(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
9239 basic_istream_char_sentry_destroy(this);
9241 basic_ios_char_setstate(base
, state
);
9245 /* ??$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 */
9246 /* ??$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 */
9247 basic_istream_char
* __cdecl
basic_istream_char_getline_bstr_delim(
9248 basic_istream_char
*istream
, basic_string_char
*str
, char delim
)
9250 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
9251 IOSB_iostate state
= IOSTATE_goodbit
;
9252 int c
= (unsigned char)delim
;
9254 TRACE("(%p %p %s)\n", istream
, str
, debugstr_an(&delim
, 1));
9256 if(basic_istream_char_sentry_create(istream
, TRUE
)) {
9257 basic_streambuf_char
*strbuf
= basic_ios_char_rdbuf_get(base
);
9258 MSVCP_basic_string_char_clear(str
);
9260 c
= basic_streambuf_char_sgetc(strbuf
);
9261 for(; c
!=(unsigned char)delim
&& c
!=EOF
; c
= basic_streambuf_char_snextc(strbuf
))
9262 MSVCP_basic_string_char_append_ch(str
, c
);
9263 if(c
==EOF
) state
|= IOSTATE_eofbit
;
9264 else if(c
==(unsigned char)delim
) basic_streambuf_char_sbumpc(strbuf
);
9266 if(!MSVCP_basic_string_char_length(str
) && c
!=(unsigned char)delim
) state
|= IOSTATE_failbit
;
9268 basic_istream_char_sentry_destroy(istream
);
9270 basic_ios_char_setstate(basic_istream_char_get_basic_ios(istream
), state
);
9274 /* ??$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 */
9275 /* ??$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 */
9276 basic_istream_char
* __cdecl
basic_istream_char_getline_bstr(
9277 basic_istream_char
*istream
, basic_string_char
*str
)
9279 return basic_istream_char_getline_bstr_delim(istream
, str
, '\n');
9282 /* ??$?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 */
9283 /* ??$?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 */
9284 basic_istream_char
* __cdecl
basic_istream_char_read_bstr(
9285 basic_istream_char
*istream
, basic_string_char
*str
)
9287 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
9288 IOSB_iostate state
= IOSTATE_failbit
;
9291 TRACE("(%p %p)\n", istream
, str
);
9293 if(basic_istream_char_sentry_create(istream
, FALSE
)) {
9294 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(base
->strbuf
));
9295 size_t count
= ios_base_width_get(&base
->base
);
9300 MSVCP_basic_string_char_clear(str
);
9302 for(c
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
));
9303 c
!=EOF
&& !ctype_char_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
9304 c
= basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base
)), count
--) {
9305 state
= IOSTATE_goodbit
;
9306 MSVCP_basic_string_char_append_ch(str
, c
);
9309 basic_istream_char_sentry_destroy(istream
);
9311 ios_base_width_set(&base
->base
, 0);
9312 basic_ios_char_setstate(base
, state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9316 /* ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAD@Z */
9317 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAD@Z */
9318 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAC@Z */
9319 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAC@Z */
9320 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@PAE@Z */
9321 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@PEAE@Z */
9322 basic_istream_char
* __cdecl
basic_istream_char_read_str(basic_istream_char
*istream
, char *str
)
9324 basic_ios_char
*base
= basic_istream_char_get_basic_ios(istream
);
9325 IOSB_iostate state
= IOSTATE_failbit
;
9328 TRACE("(%p %p)\n", istream
, str
);
9330 if(basic_istream_char_sentry_create(istream
, FALSE
)) {
9331 const ctype_char
*ctype
= ctype_char_use_facet(IOS_LOCALE(base
->strbuf
));
9332 size_t count
= ios_base_width_get(&base
->base
)-1;
9334 for(c
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
));
9335 c
!=EOF
&& !ctype_char_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
9336 c
= basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base
)), count
--) {
9337 state
= IOSTATE_goodbit
;
9341 basic_istream_char_sentry_destroy(istream
);
9344 ios_base_width_set(&base
->base
, 0);
9345 basic_ios_char_setstate(base
, state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9349 /* ??$?5DU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAD@Z */
9350 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAD@Z */
9351 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAC@Z */
9352 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAC@Z */
9353 /* ??$?5U?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAE@Z */
9354 /* ??$?5U?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAE@Z */
9355 basic_istream_char
* __cdecl
basic_istream_char_read_ch(basic_istream_char
*istream
, char *ch
)
9357 IOSB_iostate state
= IOSTATE_failbit
;
9360 TRACE("(%p %p)\n", istream
, ch
);
9362 if(basic_istream_char_sentry_create(istream
, FALSE
)) {
9363 c
= basic_streambuf_char_sbumpc(basic_ios_char_rdbuf_get(
9364 basic_istream_char_get_basic_ios(istream
)));
9366 state
= IOSTATE_goodbit
;
9370 basic_istream_char_sentry_destroy(istream
);
9372 basic_ios_char_setstate(basic_istream_char_get_basic_ios(istream
),
9373 state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9377 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
9378 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
9379 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_streambuf
, 8)
9380 basic_istream_char
* __thiscall
basic_istream_char_read_streambuf(
9381 basic_istream_char
*this, basic_streambuf_char
*streambuf
)
9383 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9384 IOSB_iostate state
= IOSTATE_failbit
;
9387 TRACE("(%p %p)\n", this, streambuf
);
9389 if(basic_istream_char_sentry_create(this, FALSE
)) {
9390 for(c
= basic_streambuf_char_sgetc(basic_ios_char_rdbuf_get(base
)); c
!=EOF
;
9391 c
= basic_streambuf_char_snextc(basic_ios_char_rdbuf_get(base
))) {
9392 state
= IOSTATE_goodbit
;
9393 if(basic_streambuf_char_sputc(streambuf
, c
) == EOF
)
9397 basic_istream_char_sentry_destroy(this);
9399 basic_ios_char_setstate(base
, state
| (c
==EOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9403 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
9404 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
9405 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func
, 8)
9406 basic_istream_char
* __thiscall
basic_istream_char_read_func(basic_istream_char
*this,
9407 basic_istream_char
* (__cdecl
*pfunc
)(basic_istream_char
*))
9409 TRACE("(%p %p)\n", this, pfunc
);
9414 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@DU?$char_traits@D@std@@@1@AAV21@@Z@Z */
9415 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@DU?$char_traits@D@std@@@1@AEAV21@@Z@Z */
9416 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func_basic_ios
, 8)
9417 basic_istream_char
* __thiscall
basic_istream_char_read_func_basic_ios(basic_istream_char
*this,
9418 basic_ios_char
* (__cdecl
*pfunc
)(basic_ios_char
*))
9420 TRACE("(%p %p)\n", this, pfunc
);
9421 pfunc(basic_istream_char_get_basic_ios(this));
9425 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
9426 /* ??5?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
9427 DEFINE_THISCALL_WRAPPER(basic_istream_char_read_func_ios_base
, 8)
9428 basic_istream_char
* __thiscall
basic_istream_char_read_func_ios_base(basic_istream_char
*this,
9429 ios_base
* (__cdecl
*pfunc
)(ios_base
*))
9431 TRACE("(%p %p)\n", this, pfunc
);
9432 pfunc(&basic_istream_char_get_basic_ios(this)->base
);
9436 /* ??$?5MDU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$complex@M@0@@Z */
9437 /* ??$?5MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$complex@M@0@@Z */
9438 basic_istream_char
* __cdecl
basic_istream_char_read_complex_float(basic_istream_char
*this, complex_float
*v
)
9441 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9443 TRACE("(%p %p)\n", this, v
);
9445 ws_basic_istream_char(this);
9446 if(basic_istream_char_peek(this) == '(') {
9448 basic_istream_char_get(this);
9449 basic_istream_char_read_float(this, &r
);
9451 if(ios_base_fail(&base
->base
))
9454 ws_basic_istream_char(this);
9455 c
= basic_istream_char_peek(this);
9458 basic_istream_char_get(this);
9459 basic_istream_char_read_float(this, &i
);
9461 if(ios_base_fail(&base
->base
))
9464 ws_basic_istream_char(this);
9465 c
= basic_istream_char_peek(this);
9466 if(c
== ')') { /* supported format: (real, imag) */
9467 basic_istream_char_get(this);
9471 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9474 }else if(c
== ')') { /* supported format: (real) */
9475 basic_istream_char_get(this);
9479 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9482 }else { /* supported format: real */
9483 basic_istream_char_read_float(this, &r
);
9485 if(ios_base_fail(&base
->base
))
9495 /* ??$?5NDU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$complex@N@0@@Z */
9496 /* ??$?5DU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$complex@N@0@@Z */
9497 basic_istream_char
* __cdecl
basic_istream_char_read_complex_double(basic_istream_char
*this, complex_double
*v
)
9500 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9502 TRACE("(%p %p)\n", this, v
);
9504 ws_basic_istream_char(this);
9505 if(basic_istream_char_peek(this) == '(') {
9507 basic_istream_char_get(this);
9508 basic_istream_char_read_double(this, &r
);
9510 if(ios_base_fail(&base
->base
))
9513 ws_basic_istream_char(this);
9514 c
= basic_istream_char_peek(this);
9517 basic_istream_char_get(this);
9518 basic_istream_char_read_double(this, &i
);
9520 if(ios_base_fail(&base
->base
))
9523 ws_basic_istream_char(this);
9524 c
= basic_istream_char_peek(this);
9525 if(c
== ')') { /* supported format: (real, imag) */
9526 basic_istream_char_get(this);
9530 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9533 }else if(c
== ')') { /* supported format: (real) */
9534 basic_istream_char_get(this);
9538 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9541 }else { /* supported format: real */
9542 basic_istream_char_read_double(this, &r
);
9544 if(ios_base_fail(&base
->base
))
9554 /* ??$?5ODU?$char_traits@D@std@@@std@@YAAAV?$basic_istream@DU?$char_traits@D@std@@@0@AAV10@AAV?$complex@O@0@@Z */
9555 /* ??$?5ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_istream@DU?$char_traits@D@std@@@0@AEAV10@AEAV?$complex@O@0@@Z */
9556 basic_istream_char
* __cdecl
basic_istream_char_read_complex_ldouble(basic_istream_char
*this, complex_double
*v
)
9559 basic_ios_char
*base
= basic_istream_char_get_basic_ios(this);
9561 TRACE("(%p %p)\n", this, v
);
9563 ws_basic_istream_char(this);
9564 if(basic_istream_char_peek(this) == '(') {
9566 basic_istream_char_get(this);
9567 basic_istream_char_read_ldouble(this, &r
);
9569 if(ios_base_fail(&base
->base
))
9572 ws_basic_istream_char(this);
9573 c
= basic_istream_char_peek(this);
9576 basic_istream_char_get(this);
9577 basic_istream_char_read_ldouble(this, &i
);
9579 if(ios_base_fail(&base
->base
))
9582 ws_basic_istream_char(this);
9583 c
= basic_istream_char_peek(this);
9584 if(c
== ')') { /* supported format: (real, imag) */
9585 basic_istream_char_get(this);
9589 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9592 }else if(c
== ')') { /* supported format: (real) */
9593 basic_istream_char_get(this);
9597 basic_ios_char_setstate(base
, IOSTATE_failbit
);
9600 }else { /* supported format: real */
9601 basic_istream_char_read_ldouble(this, &r
);
9603 if(ios_base_fail(&base
->base
))
9613 /* ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z */
9614 /* ?swap@?$basic_istream@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z */
9615 DEFINE_THISCALL_WRAPPER(basic_istream_char_swap
, 8)
9616 void __thiscall
basic_istream_char_swap(basic_istream_char
*this, basic_istream_char
*r
)
9618 TRACE("(%p %p)\n", this, r
);
9623 basic_ios_char_swap(basic_istream_char_get_basic_ios(this),
9624 basic_istream_char_get_basic_ios(r
));
9625 this->count
^= r
->count
;
9626 r
->count
^= this->count
;
9627 this->count
^= r
->count
;
9630 /* Caution: basic_istream uses virtual inheritance. */
9631 static inline basic_ios_wchar
* basic_istream_wchar_get_basic_ios(basic_istream_wchar
*this)
9633 return (basic_ios_wchar
*)((char*)this+this->vbtable
[1]);
9636 static inline basic_ios_wchar
* basic_istream_wchar_to_basic_ios(basic_istream_wchar
*ptr
)
9638 return (basic_ios_wchar
*)((char*)ptr
+basic_istream_wchar_vbtable
[1]);
9641 static inline basic_istream_wchar
* basic_istream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
9643 return (basic_istream_wchar
*)((char*)ptr
-basic_istream_wchar_vbtable
[1]);
9646 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z */
9647 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N1@Z */
9648 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor_init
, 20)
9649 basic_istream_wchar
* __thiscall
basic_istream_wchar_ctor_init(basic_istream_wchar
*this,
9650 basic_streambuf_wchar
*strbuf
, bool isstd
, bool noinit
, bool virt_init
)
9652 basic_ios_wchar
*base
;
9654 TRACE("(%p %p %d %d %d)\n", this, strbuf
, isstd
, noinit
, virt_init
);
9657 this->vbtable
= basic_istream_wchar_vbtable
;
9658 base
= basic_istream_wchar_get_basic_ios(this);
9659 INIT_BASIC_IOS_VTORDISP(base
);
9660 basic_ios_wchar_ctor(base
);
9662 base
= basic_istream_wchar_get_basic_ios(this);
9665 base
->base
.vtable
= &MSVCP_basic_istream_wchar_vtable
;
9668 basic_ios_wchar_init(base
, strbuf
, isstd
);
9672 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z */
9673 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N1@Z */
9674 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor_init
, 20)
9675 basic_istream_wchar
* __thiscall
basic_istream_short_ctor_init(basic_istream_wchar
*this,
9676 basic_streambuf_wchar
*strbuf
, bool isstd
, bool noinit
, bool virt_init
)
9678 basic_istream_wchar_ctor_init(this, strbuf
, isstd
, noinit
, virt_init
);
9679 basic_istream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_istream_short_vtable
;
9683 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
9684 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@_N@Z */
9685 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor
, 16)
9686 basic_istream_wchar
* __thiscall
basic_istream_wchar_ctor(basic_istream_wchar
*this,
9687 basic_streambuf_wchar
*strbuf
, bool isstd
, bool virt_init
)
9689 return basic_istream_wchar_ctor_init(this, strbuf
, isstd
, FALSE
, virt_init
);
9692 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
9693 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@_N@Z */
9694 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor
, 16)
9695 basic_istream_wchar
* __thiscall
basic_istream_short_ctor(basic_istream_wchar
*this,
9696 basic_streambuf_wchar
*strbuf
, bool isstd
, bool virt_init
)
9698 return basic_istream_short_ctor_init(this, strbuf
, isstd
, FALSE
, virt_init
);
9701 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE@W4_Uninitialized@1@@Z */
9702 /* ??0?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
9703 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ctor_uninitialized
, 12)
9704 basic_istream_wchar
* __thiscall
basic_istream_wchar_ctor_uninitialized(
9705 basic_istream_wchar
*this, int uninitialized
, bool virt_init
)
9707 basic_ios_wchar
*base
;
9709 TRACE("(%p %d %d)\n", this, uninitialized
, virt_init
);
9712 this->vbtable
= basic_istream_wchar_vbtable
;
9713 base
= basic_istream_wchar_get_basic_ios(this);
9714 INIT_BASIC_IOS_VTORDISP(base
);
9715 basic_ios_wchar_ctor(base
);
9717 base
= basic_istream_wchar_get_basic_ios(this);
9720 base
->base
.vtable
= &MSVCP_basic_istream_wchar_vtable
;
9721 ios_base_Addstd(&base
->base
);
9725 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QAE@W4_Uninitialized@1@@Z */
9726 /* ??0?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA@W4_Uninitialized@1@@Z */
9727 DEFINE_THISCALL_WRAPPER(basic_istream_short_ctor_uninitialized
, 12)
9728 basic_istream_wchar
* __thiscall
basic_istream_short_ctor_uninitialized(
9729 basic_istream_wchar
*this, int uninitialized
, bool virt_init
)
9731 basic_istream_wchar_ctor_uninitialized(this, uninitialized
, virt_init
);
9732 basic_istream_wchar_get_basic_ios(this)->base
.vtable
= &MSVCP_basic_istream_short_vtable
;
9736 /* ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
9737 /* ??1?$basic_istream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
9738 /* ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UAE@XZ */
9739 /* ??1?$basic_istream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
9740 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_dtor
, 4)
9741 void __thiscall
basic_istream_wchar_dtor(basic_ios_wchar
*base
)
9743 basic_istream_wchar
*this = basic_istream_wchar_from_basic_ios(base
);
9745 /* don't destroy virtual base here */
9746 TRACE("(%p)\n", this);
9749 /* ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
9750 /* ??_D?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
9751 /* ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ */
9752 /* ??_D?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
9753 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_vbase_dtor
, 4)
9754 void __thiscall
basic_istream_wchar_vbase_dtor(basic_istream_wchar
*this)
9756 basic_ios_wchar
*base
= basic_istream_wchar_to_basic_ios(this);
9758 TRACE("(%p)\n", this);
9760 basic_istream_wchar_dtor(base
);
9761 basic_ios_wchar_dtor(base
);
9764 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_vector_dtor
, 8)
9765 basic_istream_wchar
* __thiscall
basic_istream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
9767 basic_istream_wchar
*this = basic_istream_wchar_from_basic_ios(base
);
9769 TRACE("(%p %x)\n", this, flags
);
9772 /* we have an array, with the number of elements stored before the first object */
9773 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
9775 for(i
=*ptr
-1; i
>=0; i
--)
9776 basic_istream_wchar_vbase_dtor(this+i
);
9777 MSVCRT_operator_delete(ptr
);
9779 basic_istream_wchar_vbase_dtor(this);
9781 MSVCRT_operator_delete(this);
9787 /* ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z */
9788 /* ?_Ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z */
9789 /* ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z */
9790 /* ?_Ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z */
9791 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Ipfx
, 8)
9792 bool __thiscall
basic_istream_wchar__Ipfx(basic_istream_wchar
*this, bool noskip
)
9794 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9796 TRACE("(%p %d)\n", this, noskip
);
9798 if(ios_base_good(&base
->base
)) {
9799 if(basic_ios_wchar_tie_get(base
))
9800 basic_ostream_wchar_flush(basic_ios_wchar_tie_get(base
));
9802 if(!noskip
&& (ios_base_flags_get(&base
->base
) & FMTFLAG_skipws
)) {
9803 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9804 const ctype_wchar
*ctype
= ctype_wchar_use_facet(IOS_LOCALE(base
->strbuf
));
9807 for(ch
= basic_streambuf_wchar_sgetc(strbuf
); ;
9808 ch
= basic_streambuf_wchar_snextc(strbuf
)) {
9810 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
);
9814 if(!ctype_wchar_is_ch(ctype
, _SPACE
|_BLANK
, ch
))
9820 if(!ios_base_good(&base
->base
)) {
9821 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
9827 /* ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE_N_N@Z */
9828 /* ?ipfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_N_N@Z */
9829 /* ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE_N_N@Z */
9830 /* ?ipfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_N_N@Z */
9831 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ipfx
, 8)
9832 bool __thiscall
basic_istream_wchar_ipfx(basic_istream_wchar
*this, bool noskip
)
9834 return basic_istream_wchar__Ipfx(this, noskip
);
9837 /* ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
9838 /* ?isfx@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
9839 /* ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXXZ */
9840 /* ?isfx@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
9841 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_isfx
, 4)
9842 void __thiscall
basic_istream_wchar_isfx(basic_istream_wchar
*this)
9844 TRACE("(%p)\n", this);
9847 static BOOL
basic_istream_wchar_sentry_create(basic_istream_wchar
*istr
, bool noskip
)
9849 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istr
);
9851 if(basic_ios_wchar_rdbuf_get(base
))
9852 basic_streambuf_wchar__Lock(base
->strbuf
);
9854 return basic_istream_wchar_ipfx(istr
, noskip
);
9857 static void basic_istream_wchar_sentry_destroy(basic_istream_wchar
*istr
)
9859 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istr
);
9861 if(basic_ios_wchar_rdbuf_get(base
))
9862 basic_streambuf_wchar__Unlock(base
->strbuf
);
9865 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBEHXZ */
9866 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEBA_JXZ */
9867 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBEHXZ */
9868 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QEBA_JXZ */
9869 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBA_JXZ */
9870 /* ?gcount@?$basic_istream@GU?$char_traits@G@std@@@std@@QBE_JXZ */
9871 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBA_JXZ */
9872 /* ?gcount@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QBE_JXZ */
9873 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_gcount
, 4)
9874 streamsize __thiscall
basic_istream_wchar_gcount(const basic_istream_wchar
*this)
9876 TRACE("(%p)\n", this);
9880 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
9881 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
9882 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ */
9883 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ */
9884 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get
, 4)
9885 unsigned short __thiscall
basic_istream_wchar_get(basic_istream_wchar
*this)
9887 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9890 TRACE("(%p)\n", this);
9894 if(!basic_istream_wchar_sentry_create(this, TRUE
)) {
9895 basic_istream_wchar_sentry_destroy(this);
9899 ret
= basic_streambuf_wchar_sbumpc(basic_ios_wchar_rdbuf_get(base
));
9900 basic_istream_wchar_sentry_destroy(this);
9902 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
|IOSTATE_failbit
);
9909 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AA_W@Z */
9910 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEA_W@Z */
9911 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAG@Z */
9912 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAG@Z */
9913 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_ch
, 8)
9914 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_ch(basic_istream_wchar
*this, wchar_t *ch
)
9918 TRACE("(%p %p)\n", this, ch
);
9920 ret
= basic_istream_wchar_get(this);
9926 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH_W@Z */
9927 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z */
9928 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGHG@Z */
9929 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z */
9930 #if STREAMSIZE_BITS == 64
9931 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str_delim
, 20)
9933 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str_delim
, 16)
9935 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_str_delim(basic_istream_wchar
*this, wchar_t *str
, streamsize count
, wchar_t delim
)
9937 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9938 unsigned short ch
= delim
;
9940 TRACE("(%p %p %s %s)\n", this, str
, wine_dbgstr_longlong(count
), debugstr_wn(&delim
, 1));
9944 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9945 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
9947 for(ch
= basic_streambuf_wchar_sgetc(strbuf
); count
>1;
9948 ch
= basic_streambuf_wchar_snextc(strbuf
)) {
9949 if(ch
==WEOF
|| ch
==delim
)
9957 basic_istream_wchar_sentry_destroy(this);
9959 basic_ios_wchar_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
9960 (ch
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
9966 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
9967 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
9968 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
9969 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
9970 #if STREAMSIZE_BITS == 64
9971 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str
, 16)
9973 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_str
, 12)
9975 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_str(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
9977 return basic_istream_wchar_get_str_delim(this, str
, count
, '\n');
9980 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z */
9981 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@_W@Z */
9982 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z */
9983 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@G@Z */
9984 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_streambuf_delim
, 12)
9985 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_streambuf_delim(basic_istream_wchar
*this, basic_streambuf_wchar
*strbuf
, wchar_t delim
)
9987 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
9988 unsigned short ch
= delim
;
9990 TRACE("(%p %p %s)\n", this, strbuf
, debugstr_wn(&delim
, 1));
9994 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
9995 basic_streambuf_wchar
*strbuf_read
= basic_ios_wchar_rdbuf_get(base
);
9997 for(ch
= basic_streambuf_wchar_sgetc(strbuf_read
); ;
9998 ch
= basic_streambuf_wchar_snextc(strbuf_read
)) {
9999 if(ch
==WEOF
|| ch
==delim
)
10002 if(basic_streambuf_wchar_sputc(strbuf
, ch
) == WEOF
)
10007 basic_istream_wchar_sentry_destroy(this);
10009 basic_ios_wchar_setstate(base
, (!this->count
? IOSTATE_failbit
: IOSTATE_goodbit
) |
10010 (ch
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
10014 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@AAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z */
10015 /* ?get@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@2@@Z */
10016 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@AAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z */
10017 /* ?get@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@AEAV?$basic_streambuf@GU?$char_traits@G@std@@@2@@Z */
10018 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_get_streambuf
, 8)
10019 basic_istream_wchar
* __thiscall
basic_istream_wchar_get_streambuf(basic_istream_wchar
*this, basic_streambuf_wchar
*strbuf
)
10021 return basic_istream_wchar_get_streambuf_delim(this, strbuf
, '\n');
10024 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH_W@Z */
10025 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J_W@Z */
10026 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGHG@Z */
10027 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_JG@Z */
10028 #if STREAMSIZE_BITS == 64
10029 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline_delim
, 20)
10031 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline_delim
, 16)
10033 basic_istream_wchar
* __thiscall
basic_istream_wchar_getline_delim(basic_istream_wchar
*this, wchar_t *str
, streamsize count
, wchar_t delim
)
10035 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10036 unsigned short ch
= delim
;
10038 TRACE("(%p %p %s %s)\n", this, str
, wine_dbgstr_longlong(count
), debugstr_wn(&delim
, 1));
10042 if(basic_istream_wchar_sentry_create(this, TRUE
) && count
>0) {
10043 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10046 ch
= basic_streambuf_wchar_sbumpc(strbuf
);
10048 if(ch
==WEOF
|| ch
==delim
)
10058 else if(ch
!= WEOF
) {
10059 ch
= basic_streambuf_wchar_sgetc(strbuf
);
10062 basic_streambuf_wchar__Gninc(strbuf
);
10067 basic_istream_wchar_sentry_destroy(this);
10069 basic_ios_wchar_setstate(base
, (ch
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
) |
10070 (!this->count
|| (ch
!=delim
&& ch
!=WEOF
) ? IOSTATE_failbit
: IOSTATE_goodbit
));
10076 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
10077 /* ?getline@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
10078 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
10079 /* ?getline@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
10080 #if STREAMSIZE_BITS == 64
10081 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline
, 16)
10083 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_getline
, 12)
10085 basic_istream_wchar
* __thiscall
basic_istream_wchar_getline(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
10087 return basic_istream_wchar_getline_delim(this, str
, count
, '\n');
10090 /* ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@HG@Z */
10091 /* ?ignore@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JG@Z */
10092 /* ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@HG@Z */
10093 /* ?ignore@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JG@Z */
10094 #if STREAMSIZE_BITS == 64
10095 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ignore
, 16)
10097 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_ignore
, 12)
10099 basic_istream_wchar
* __thiscall
basic_istream_wchar_ignore(basic_istream_wchar
*this, streamsize count
, unsigned short delim
)
10101 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10102 unsigned short ch
= delim
;
10103 unsigned int state
;
10105 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(count
), delim
);
10109 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10110 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10111 state
= IOSTATE_goodbit
;
10114 ch
= basic_streambuf_wchar_sbumpc(strbuf
);
10117 state
= IOSTATE_eofbit
;
10125 if(count
!= INT_MAX
)
10129 state
= IOSTATE_failbit
;
10130 basic_istream_wchar_sentry_destroy(this);
10132 basic_ios_wchar_setstate(base
, state
);
10136 /* ?ws@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AAV21@@Z */
10137 /* ?ws@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@AEAV21@@Z */
10138 /* ?ws@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@1@AAV21@@Z */
10139 /* ?ws@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@1@AEAV21@@Z */
10140 basic_istream_wchar
* __cdecl
ws_basic_istream_wchar(basic_istream_wchar
*istream
)
10142 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
10143 unsigned short ch
= '\n';
10145 TRACE("(%p)\n", istream
);
10147 if(basic_istream_wchar_sentry_create(istream
, TRUE
)) {
10148 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10149 const ctype_wchar
*ctype
= ctype_wchar_use_facet(IOS_LOCALE(strbuf
));
10151 for(ch
= basic_streambuf_wchar_sgetc(strbuf
); ctype_wchar_is_ch(ctype
, _SPACE
, ch
);
10152 ch
= basic_streambuf_wchar_snextc(strbuf
)) {
10157 basic_istream_wchar_sentry_destroy(istream
);
10160 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
);
10164 /* ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEGXZ */
10165 /* ?peek@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAGXZ */
10166 /* ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEGXZ */
10167 /* ?peek@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAGXZ */
10168 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_peek
, 4)
10169 unsigned short __thiscall
basic_istream_wchar_peek(basic_istream_wchar
*this)
10171 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10172 unsigned short ret
= WEOF
;
10174 TRACE("(%p)\n", this);
10178 if(basic_istream_wchar_sentry_create(this, TRUE
))
10179 ret
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
));
10180 basic_istream_wchar_sentry_destroy(this);
10183 basic_ios_wchar_setstate(base
, IOSTATE_eofbit
);
10188 /* ?_Read_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WIH@Z */
10189 /* ?_Read_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_K_J@Z */
10190 /* ?_Read_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGIH@Z */
10191 /* ?_Read_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_K_J@Z */
10192 #if STREAMSIZE_BITS == 64
10193 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Read_s
, 20)
10195 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Read_s
, 16)
10197 basic_istream_wchar
* __thiscall
basic_istream_wchar__Read_s(basic_istream_wchar
*this, wchar_t *str
, size_t size
, streamsize count
)
10199 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10200 IOSB_iostate state
= IOSTATE_goodbit
;
10202 TRACE("(%p %p %Iu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
10204 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10205 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10207 this->count
= basic_streambuf_wchar__Sgetn_s(strbuf
, str
, size
, count
);
10208 if(this->count
!= count
)
10209 state
|= IOSTATE_failbit
| IOSTATE_eofbit
;
10213 basic_istream_wchar_sentry_destroy(this);
10215 basic_ios_wchar_setstate(base
, state
);
10219 /* ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@PA_WH@Z */
10220 /* ?read@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@PEA_W_J@Z */
10221 /* ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@PAGH@Z */
10222 /* ?read@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@PEAG_J@Z */
10223 #if STREAMSIZE_BITS == 64
10224 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read
, 16)
10226 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read
, 12)
10228 basic_istream_wchar
* __thiscall
basic_istream_wchar_read(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
10230 return basic_istream_wchar__Read_s(this, str
, -1, count
);
10233 /* ?_Readsome_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHPA_WIH@Z */
10234 /* ?_Readsome_s@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_K_J@Z */
10235 /* ?_Readsome_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHPAGIH@Z */
10236 /* ?_Readsome_s@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_K_J@Z */
10237 #if STREAMSIZE_BITS == 64
10238 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Readsome_s
, 20)
10240 DEFINE_THISCALL_WRAPPER(basic_istream_wchar__Readsome_s
, 16)
10242 streamsize __thiscall
basic_istream_wchar__Readsome_s(basic_istream_wchar
*this, wchar_t *str
, size_t size
, streamsize count
)
10244 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10245 IOSB_iostate state
= IOSTATE_goodbit
;
10247 TRACE("(%p %p %Iu %s)\n", this, str
, size
, wine_dbgstr_longlong(count
));
10251 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10252 streamsize avail
= basic_streambuf_wchar_in_avail(basic_ios_wchar_rdbuf_get(base
));
10257 state
|= IOSTATE_eofbit
;
10259 basic_istream_wchar__Read_s(this, str
, size
, avail
);
10261 state
|= IOSTATE_failbit
;
10263 basic_istream_wchar_sentry_destroy(this);
10265 basic_ios_wchar_setstate(base
, state
);
10266 return this->count
;
10269 /* ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHPA_WH@Z */
10270 /* ?readsome@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA_JPEA_W_J@Z */
10271 /* ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHPAGH@Z */
10272 /* ?readsome@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA_JPEAG_J@Z */
10273 #if STREAMSIZE_BITS == 64
10274 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_readsome
, 16)
10276 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_readsome
, 12)
10278 streamsize __thiscall
basic_istream_wchar_readsome(basic_istream_wchar
*this, wchar_t *str
, streamsize count
)
10280 return basic_istream_wchar__Readsome_s(this, str
, count
, count
);
10283 /* ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@_W@Z */
10284 /* ?putback@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_W@Z */
10285 /* ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@G@Z */
10286 /* ?putback@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@G@Z */
10287 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_putback
, 8)
10288 basic_istream_wchar
* __thiscall
basic_istream_wchar_putback(basic_istream_wchar
*this, wchar_t ch
)
10290 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10291 IOSB_iostate state
= IOSTATE_goodbit
;
10293 TRACE("(%p %c)\n", this, ch
);
10297 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10298 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10300 if(!ios_base_good(&base
->base
))
10301 state
|= IOSTATE_failbit
;
10302 else if(!strbuf
|| basic_streambuf_wchar_sputbackc(strbuf
, ch
)==WEOF
)
10303 state
|= IOSTATE_badbit
;
10305 basic_istream_wchar_sentry_destroy(this);
10307 basic_ios_wchar_setstate(base
, state
);
10311 /* ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@XZ */
10312 /* ?unget@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@XZ */
10313 /* ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@XZ */
10314 /* ?unget@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@XZ */
10315 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_unget
, 4)
10316 basic_istream_wchar
* __thiscall
basic_istream_wchar_unget(basic_istream_wchar
*this)
10318 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10319 IOSB_iostate state
= IOSTATE_goodbit
;
10321 TRACE("(%p)\n", this);
10325 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10326 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10328 if(!ios_base_good(&base
->base
))
10329 state
|= IOSTATE_failbit
;
10330 else if(!strbuf
|| basic_streambuf_wchar_sungetc(strbuf
)==WEOF
)
10331 state
|= IOSTATE_badbit
;
10333 basic_istream_wchar_sentry_destroy(this);
10335 basic_ios_wchar_setstate(base
, state
);
10339 /* ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEHXZ */
10340 /* ?sync@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAHXZ */
10341 /* ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEHXZ */
10342 /* ?sync@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAHXZ */
10343 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_sync
, 4)
10344 int __thiscall
basic_istream_wchar_sync(basic_istream_wchar
*this)
10346 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10347 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10349 TRACE("(%p)\n", this);
10354 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10355 if(basic_streambuf_wchar_pubsync(strbuf
) != -1) {
10356 basic_istream_wchar_sentry_destroy(this);
10360 basic_istream_wchar_sentry_destroy(this);
10362 basic_ios_wchar_setstate(base
, IOSTATE_badbit
);
10366 /* ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAE?AV?$fpos@H@2@XZ */
10367 /* ?tellg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
10368 /* ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAE?AV?$fpos@H@2@XZ */
10369 /* ?tellg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAA?AV?$fpos@H@2@XZ */
10370 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_tellg
, 8)
10371 fpos_mbstatet
* __thiscall
basic_istream_wchar_tellg(basic_istream_wchar
*this, fpos_mbstatet
*ret
)
10373 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10375 TRACE("(%p %p)\n", this, ret
);
10377 #if _MSVCP_VER >= 110
10378 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10379 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
10380 ret
, 0, SEEKDIR_cur
, OPENMODE_in
);
10384 memset(&ret
->state
, 0, sizeof(ret
->state
));
10386 basic_istream_wchar_sentry_destroy(this);
10388 if(ios_base_fail(&base
->base
)) {
10391 memset(&ret
->state
, 0, sizeof(ret
->state
));
10395 basic_streambuf_wchar_pubseekoff(basic_ios_wchar_rdbuf_get(base
),
10396 ret
, 0, SEEKDIR_cur
, OPENMODE_in
);
10401 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@JW4seekdir@ios_base@2@@Z */
10402 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JW4seekdir@ios_base@2@@Z */
10403 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@JH@Z */
10404 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@_JH@Z */
10405 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@JH@Z */
10406 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@_JH@Z */
10407 #if STREAMOFF_BITS == 64
10408 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg
, 16)
10410 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg
, 12)
10412 basic_istream_wchar
* __thiscall
basic_istream_wchar_seekg(basic_istream_wchar
*this, streamoff off
, int dir
)
10414 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10415 #if _MSVCP_VER >= 110
10416 IOSB_iostate state
;
10418 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), dir
);
10420 state
= ios_base_rdstate(&base
->base
);
10421 ios_base_clear(&base
->base
, state
& ~IOSTATE_eofbit
);
10423 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10424 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10427 basic_streambuf_wchar_pubseekoff(strbuf
, &ret
, off
, dir
, OPENMODE_in
);
10429 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
10430 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10432 basic_istream_wchar_sentry_destroy(this);
10434 TRACE("(%p %s %d)\n", this, wine_dbgstr_longlong(off
), dir
);
10436 if(!ios_base_fail(&base
->base
)) {
10437 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10440 basic_streambuf_wchar_pubseekoff(strbuf
, &ret
, off
, dir
, OPENMODE_in
);
10442 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
10443 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10445 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10448 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10453 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
10454 /* ?seekg@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
10455 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV12@V?$fpos@H@2@@Z */
10456 /* ?seekg@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV12@V?$fpos@H@2@@Z */
10457 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_seekg_fpos
, 28)
10458 basic_istream_wchar
* __thiscall
basic_istream_wchar_seekg_fpos(basic_istream_wchar
*this, fpos_mbstatet pos
)
10460 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10461 #if _MSVCP_VER >= 110
10462 IOSB_iostate state
;
10464 TRACE("(%p %s)\n", this, debugstr_fpos_mbstatet(&pos
));
10466 state
= ios_base_rdstate(&base
->base
);
10467 ios_base_clear(&base
->base
, state
& ~IOSTATE_eofbit
);
10469 if(basic_istream_wchar_sentry_create(this, TRUE
)) {
10470 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10473 basic_streambuf_wchar_pubseekpos(strbuf
, &ret
, pos
, OPENMODE_in
);
10475 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
10476 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10478 basic_istream_wchar_sentry_destroy(this);
10480 TRACE("(%p %s)\n", this, debugstr_fpos_mbstatet(&pos
));
10482 if(!ios_base_fail(&base
->base
)) {
10483 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10486 basic_streambuf_wchar_pubseekpos(strbuf
, &ret
, pos
, OPENMODE_in
);
10488 if(ret
.off
==-1 && ret
.pos
==0 && MBSTATET_TO_INT(&ret
.state
)==0)
10489 basic_ios_wchar_setstate(base
, IOSTATE_failbit
);
10491 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10494 basic_ios_wchar_clear(base
, IOSTATE_goodbit
);
10499 static basic_istream_wchar
* basic_istream_read_short(basic_istream_wchar
*this, short *v
, const num_get
*numget
)
10501 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10502 int state
= IOSTATE_goodbit
;
10504 TRACE("(%p %p)\n", this, v
);
10506 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10507 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10508 istreambuf_iterator_wchar first
={0}, last
={0};
10511 first
.strbuf
= strbuf
;
10512 num_get_wchar_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, &tmp
);
10514 if(!(state
&IOSTATE_failbit
) && tmp
==(LONG
)((short)tmp
))
10517 state
|= IOSTATE_failbit
;
10519 basic_istream_wchar_sentry_destroy(this);
10521 basic_ios_wchar_setstate(base
, state
);
10525 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAF@Z */
10526 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAF@Z */
10527 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_short
, 8)
10528 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_short(basic_istream_wchar
*this, short *v
)
10530 return basic_istream_read_short(this, v
, num_get_wchar_use_facet(
10531 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10534 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAF@Z */
10535 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAF@Z */
10536 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_short
, 8)
10537 basic_istream_wchar
* __thiscall
basic_istream_short_read_short(basic_istream_wchar
*this, short *v
)
10539 return basic_istream_read_short(this, v
, num_get_short_use_facet(
10540 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10543 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAG@Z */
10544 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAG@Z */
10545 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ushort
, 8)
10546 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ushort(basic_istream_wchar
*this, unsigned short *v
)
10548 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10549 int state
= IOSTATE_goodbit
;
10551 TRACE("(%p %p)\n", this, v
);
10553 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10554 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10555 const num_get
*numget
= num_get_wchar_use_facet(IOS_LOCALE(strbuf
));
10556 istreambuf_iterator_wchar first
={0}, last
={0};
10558 first
.strbuf
= strbuf
;
10559 num_get_wchar_get_ushort(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10561 basic_istream_wchar_sentry_destroy(this);
10563 basic_ios_wchar_setstate(base
, state
);
10567 static basic_istream_wchar
* basic_istream_read_int(basic_istream_wchar
*this, int *v
, const num_get
*numget
)
10569 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10570 int state
= IOSTATE_goodbit
;
10572 TRACE("(%p %p)\n", this, v
);
10574 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10575 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10576 istreambuf_iterator_wchar first
={0}, last
={0};
10578 first
.strbuf
= strbuf
;
10579 num_get_wchar_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10581 basic_istream_wchar_sentry_destroy(this);
10583 basic_ios_wchar_setstate(base
, state
);
10587 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAH@Z */
10588 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAH@Z */
10589 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_int
, 8)
10590 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_int(basic_istream_wchar
*this, int *v
)
10592 return basic_istream_read_int(this, v
, num_get_wchar_use_facet(
10593 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10596 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAH@Z */
10597 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAH@Z */
10598 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_int
, 8)
10599 basic_istream_wchar
* __thiscall
basic_istream_short_read_int(basic_istream_wchar
*this, int *v
)
10601 return basic_istream_read_int(this, v
, num_get_short_use_facet(
10602 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10605 static basic_istream_wchar
* basic_istream_read_uint(basic_istream_wchar
*this, unsigned int *v
, const num_get
*numget
)
10607 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10608 int state
= IOSTATE_goodbit
;
10610 TRACE("(%p %p)\n", this, v
);
10612 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10613 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10614 istreambuf_iterator_wchar first
={0}, last
={0};
10616 first
.strbuf
= strbuf
;
10617 num_get_wchar_get_uint(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10619 basic_istream_wchar_sentry_destroy(this);
10621 basic_ios_wchar_setstate(base
, state
);
10625 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAI@Z */
10626 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAI@Z */
10627 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_uint
, 8)
10628 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_uint(basic_istream_wchar
*this, unsigned int *v
)
10630 return basic_istream_read_uint(this, v
, num_get_wchar_use_facet(
10631 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10634 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAI@Z */
10635 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAI@Z */
10636 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_uint
, 8)
10637 basic_istream_wchar
* __thiscall
basic_istream_short_read_uint(basic_istream_wchar
*this, unsigned int *v
)
10639 return basic_istream_read_uint(this, v
, num_get_short_use_facet(
10640 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10643 static basic_istream_wchar
* basic_istream_read_long(basic_istream_wchar
*this, LONG
*v
, const num_get
*numget
)
10645 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10646 int state
= IOSTATE_goodbit
;
10648 TRACE("(%p %p)\n", this, v
);
10650 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10651 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10652 istreambuf_iterator_wchar first
={0}, last
={0};
10654 first
.strbuf
= strbuf
;
10655 num_get_wchar_get_long(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10657 basic_istream_wchar_sentry_destroy(this);
10659 basic_ios_wchar_setstate(base
, state
);
10663 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z */
10664 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z */
10665 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_long
, 8)
10666 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_long(basic_istream_wchar
*this, LONG
*v
)
10668 return basic_istream_read_long(this, v
, num_get_wchar_use_facet(
10669 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10672 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAJ@Z */
10673 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAJ@Z */
10674 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_long
, 8)
10675 basic_istream_wchar
* __thiscall
basic_istream_short_read_long(basic_istream_wchar
*this, LONG
*v
)
10677 return basic_istream_read_long(this, v
, num_get_short_use_facet(
10678 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10681 static basic_istream_wchar
* basic_istream_read_ulong(basic_istream_wchar
*this, ULONG
*v
, const num_get
*numget
)
10683 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10684 int state
= IOSTATE_goodbit
;
10686 TRACE("(%p %p)\n", this, v
);
10688 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10689 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10690 istreambuf_iterator_wchar first
={0}, last
={0};
10692 first
.strbuf
= strbuf
;
10693 num_get_wchar_get_ulong(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10695 basic_istream_wchar_sentry_destroy(this);
10697 basic_ios_wchar_setstate(base
, state
);
10701 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAK@Z */
10702 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAK@Z */
10703 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ulong
, 8)
10704 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ulong(basic_istream_wchar
*this, ULONG
*v
)
10706 return basic_istream_read_ulong(this, v
, num_get_wchar_use_facet(
10707 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10710 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAK@Z */
10711 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAK@Z */
10712 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ulong
, 8)
10713 basic_istream_wchar
* __thiscall
basic_istream_short_read_ulong(basic_istream_wchar
*this, ULONG
*v
)
10715 return basic_istream_read_ulong(this, v
, num_get_short_use_facet(
10716 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10719 static basic_istream_wchar
* basic_istream_read_float(basic_istream_wchar
*this, float *v
, const num_get
*numget
)
10721 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10722 int state
= IOSTATE_goodbit
;
10724 TRACE("(%p %p)\n", this, v
);
10726 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10727 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10728 istreambuf_iterator_wchar first
={0}, last
={0};
10730 first
.strbuf
= strbuf
;
10731 num_get_wchar_get_float(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10733 basic_istream_wchar_sentry_destroy(this);
10735 basic_ios_wchar_setstate(base
, state
);
10739 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAM@Z */
10740 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAM@Z */
10741 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_float
, 8)
10742 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_float(basic_istream_wchar
*this, float *v
)
10744 return basic_istream_read_float(this, v
, num_get_wchar_use_facet(
10745 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10748 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAM@Z */
10749 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAM@Z */
10750 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_float
, 8)
10751 basic_istream_wchar
* __thiscall
basic_istream_short_read_float(basic_istream_wchar
*this, float *v
)
10753 return basic_istream_read_float(this, v
, num_get_short_use_facet(
10754 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10757 static basic_istream_wchar
* basic_istream_read_double(basic_istream_wchar
*this, double *v
, const num_get
*numget
)
10759 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10760 int state
= IOSTATE_goodbit
;
10762 TRACE("(%p %p)\n", this, v
);
10764 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10765 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10766 istreambuf_iterator_wchar first
={0}, last
={0};
10768 first
.strbuf
= strbuf
;
10769 num_get_wchar_get_double(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10771 basic_istream_wchar_sentry_destroy(this);
10773 basic_ios_wchar_setstate(base
, state
);
10777 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAN@Z */
10778 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAN@Z */
10779 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_double
, 8)
10780 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_double(basic_istream_wchar
*this, double *v
)
10782 return basic_istream_read_double(this, v
, num_get_wchar_use_facet(
10783 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10786 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAN@Z */
10787 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAN@Z */
10788 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_double
, 8)
10789 basic_istream_wchar
* __thiscall
basic_istream_short_read_double(basic_istream_wchar
*this, double *v
)
10791 return basic_istream_read_double(this, v
, num_get_short_use_facet(
10792 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10795 static basic_istream_wchar
* basic_istream_read_ldouble(basic_istream_wchar
*this, double *v
, const num_get
*numget
)
10797 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10798 int state
= IOSTATE_goodbit
;
10800 TRACE("(%p %p)\n", this, v
);
10802 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10803 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10804 istreambuf_iterator_wchar first
={0}, last
={0};
10806 first
.strbuf
= strbuf
;
10807 num_get_wchar_get_ldouble(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10809 basic_istream_wchar_sentry_destroy(this);
10811 basic_ios_wchar_setstate(base
, state
);
10815 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAO@Z */
10816 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAO@Z */
10817 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ldouble
, 8)
10818 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ldouble(basic_istream_wchar
*this, double *v
)
10820 return basic_istream_read_ldouble(this, v
, num_get_wchar_use_facet(
10821 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10824 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAO@Z */
10825 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAO@Z */
10826 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ldouble
, 8)
10827 basic_istream_wchar
* __thiscall
basic_istream_short_read_ldouble(basic_istream_wchar
*this, double *v
)
10829 return basic_istream_read_ldouble(this, v
, num_get_short_use_facet(
10830 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10833 static basic_istream_wchar
* basic_istream_read_ptr(basic_istream_wchar
*this, void **v
, const num_get
*numget
)
10835 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10836 int state
= IOSTATE_goodbit
;
10838 TRACE("(%p %p)\n", this, v
);
10840 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10841 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10842 istreambuf_iterator_wchar first
={0}, last
={0};
10844 first
.strbuf
= strbuf
;
10845 num_get_wchar_get_void(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10847 basic_istream_wchar_sentry_destroy(this);
10849 basic_ios_wchar_setstate(base
, state
);
10853 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AAPAX@Z */
10854 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
10855 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_ptr
, 8)
10856 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_ptr(basic_istream_wchar
*this, void **v
)
10858 return basic_istream_read_ptr(this, v
, num_get_wchar_use_facet(
10859 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10862 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AAPAX@Z */
10863 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEAPEAX@Z */
10864 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_ptr
, 8)
10865 basic_istream_wchar
* __thiscall
basic_istream_short_read_ptr(basic_istream_wchar
*this, void **v
)
10867 return basic_istream_read_ptr(this, v
, num_get_short_use_facet(
10868 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10871 static basic_istream_wchar
* basic_istream_read_int64(basic_istream_wchar
*this, __int64
*v
, const num_get
*numget
)
10873 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10874 int state
= IOSTATE_goodbit
;
10876 TRACE("(%p %p)\n", this, v
);
10878 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10879 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10880 istreambuf_iterator_wchar first
={0}, last
={0};
10882 first
.strbuf
= strbuf
;
10883 num_get_wchar_get_int64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10885 basic_istream_wchar_sentry_destroy(this);
10887 basic_ios_wchar_setstate(base
, state
);
10891 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_J@Z */
10892 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_J@Z */
10893 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_int64
, 8)
10894 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_int64(basic_istream_wchar
*this, __int64
*v
)
10896 return basic_istream_read_int64(this, v
, num_get_wchar_use_facet(
10897 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10900 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_J@Z */
10901 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_J@Z */
10902 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_int64
, 8)
10903 basic_istream_wchar
* __thiscall
basic_istream_short_read_int64(basic_istream_wchar
*this, __int64
*v
)
10905 return basic_istream_read_int64(this, v
, num_get_short_use_facet(
10906 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10909 static basic_istream_wchar
* basic_istream_read_uint64(basic_istream_wchar
*this, unsigned __int64
*v
, const num_get
*numget
)
10911 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10912 int state
= IOSTATE_goodbit
;
10914 TRACE("(%p %p)\n", this, v
);
10916 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10917 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10918 istreambuf_iterator_wchar first
={0}, last
={0};
10920 first
.strbuf
= strbuf
;
10921 num_get_wchar_get_uint64(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10923 basic_istream_wchar_sentry_destroy(this);
10925 basic_ios_wchar_setstate(base
, state
);
10929 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_K@Z */
10930 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_K@Z */
10931 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_uint64
, 8)
10932 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_uint64(basic_istream_wchar
*this, unsigned __int64
*v
)
10934 return basic_istream_read_uint64(this, v
, num_get_wchar_use_facet(
10935 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10938 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_K@Z */
10939 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_K@Z */
10940 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_uint64
, 8)
10941 basic_istream_wchar
* __thiscall
basic_istream_short_read_uint64(basic_istream_wchar
*this, unsigned __int64
*v
)
10943 return basic_istream_read_uint64(this, v
, num_get_short_use_facet(
10944 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10947 static basic_istream_wchar
* basic_istream_read_bool(basic_istream_wchar
*this, bool *v
, const num_get
*numget
)
10949 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
10950 int state
= IOSTATE_goodbit
;
10952 TRACE("(%p %p)\n", this, v
);
10954 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
10955 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
10956 istreambuf_iterator_wchar first
={0}, last
={0};
10958 first
.strbuf
= strbuf
;
10959 num_get_wchar_get_bool(numget
, &last
, first
, last
, &base
->base
, &state
, v
);
10961 basic_istream_wchar_sentry_destroy(this);
10963 basic_ios_wchar_setstate(base
, state
);
10967 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@AA_N@Z */
10968 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@AEA_N@Z */
10969 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_bool
, 8)
10970 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_bool(basic_istream_wchar
*this, bool *v
)
10972 return basic_istream_read_bool(this, v
, num_get_wchar_use_facet(
10973 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10976 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@AA_N@Z */
10977 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@AEA_N@Z */
10978 DEFINE_THISCALL_WRAPPER(basic_istream_short_read_bool
, 8)
10979 basic_istream_wchar
* __thiscall
basic_istream_short_read_bool(basic_istream_wchar
*this, bool *v
)
10981 return basic_istream_read_bool(this, v
, num_get_short_use_facet(
10982 IOS_LOCALE(basic_istream_wchar_get_basic_ios(this)->strbuf
)));
10985 /* ??$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 */
10986 /* ??$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 */
10987 /* ??$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 */
10988 /* ??$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 */
10989 basic_istream_wchar
* __cdecl
basic_istream_wchar_getline_bstr_delim(
10990 basic_istream_wchar
*istream
, basic_string_wchar
*str
, wchar_t delim
)
10992 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
10993 IOSB_iostate state
= IOSTATE_goodbit
;
10996 TRACE("(%p %p %s)\n", istream
, str
, debugstr_wn(&delim
, 1));
10998 if(basic_istream_wchar_sentry_create(istream
, TRUE
)) {
10999 basic_streambuf_wchar
*strbuf
= basic_ios_wchar_rdbuf_get(base
);
11000 MSVCP_basic_string_wchar_clear(str
);
11002 c
= basic_streambuf_wchar_sgetc(strbuf
);
11003 for(; c
!=delim
&& c
!=WEOF
; c
= basic_streambuf_wchar_snextc(strbuf
))
11004 MSVCP_basic_string_wchar_append_ch(str
, c
);
11005 if(c
==delim
) basic_streambuf_wchar_sbumpc(strbuf
);
11006 else if(c
==WEOF
) state
|= IOSTATE_eofbit
;
11008 if(!MSVCP_basic_string_wchar_length(str
) && c
!=delim
) state
|= IOSTATE_failbit
;
11010 basic_istream_wchar_sentry_destroy(istream
);
11012 basic_ios_wchar_setstate(basic_istream_wchar_get_basic_ios(istream
), state
);
11016 /* ??$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 */
11017 /* ??$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 */
11018 /* ??$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 */
11019 /* ??$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 */
11020 basic_istream_wchar
* __cdecl
basic_istream_wchar_getline_bstr(
11021 basic_istream_wchar
*istream
, basic_string_wchar
*str
)
11023 return basic_istream_wchar_getline_bstr_delim(istream
, str
, '\n');
11026 static basic_istream_wchar
* basic_istream_read_bstr(basic_istream_wchar
*istream
,
11027 basic_string_wchar
*str
, const ctype_wchar
*ctype
)
11029 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
11030 IOSB_iostate state
= IOSTATE_failbit
;
11033 TRACE("(%p %p)\n", istream
, str
);
11035 if(basic_istream_wchar_sentry_create(istream
, FALSE
)) {
11036 size_t count
= ios_base_width_get(&base
->base
);
11041 MSVCP_basic_string_wchar_clear(str
);
11043 for(c
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
));
11044 c
!=WEOF
&& !ctype_wchar_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
11045 c
= basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base
)), count
--) {
11046 state
= IOSTATE_goodbit
;
11047 MSVCP_basic_string_wchar_append_ch(str
, c
);
11050 basic_istream_wchar_sentry_destroy(istream
);
11052 ios_base_width_set(&base
->base
, 0);
11053 basic_ios_wchar_setstate(base
, state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
11057 /* ??$?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 */
11058 /* ??$?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 */
11059 basic_istream_wchar
* __cdecl
basic_istream_wchar_read_bstr(
11060 basic_istream_wchar
*istream
, basic_string_wchar
*str
)
11062 return basic_istream_read_bstr(istream
, str
, ctype_wchar_use_facet(
11063 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
11066 /* ??$?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 */
11067 /* ??$?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 */
11068 basic_istream_wchar
* __cdecl
basic_istream_short_read_bstr(
11069 basic_istream_wchar
*istream
, basic_string_wchar
*str
)
11071 return basic_istream_read_bstr(istream
, str
, ctype_short_use_facet(
11072 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
11075 static basic_istream_wchar
* basic_istream_read_str(basic_istream_wchar
*istream
, wchar_t *str
, const ctype_wchar
*ctype
)
11077 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(istream
);
11078 IOSB_iostate state
= IOSTATE_failbit
;
11079 unsigned short c
= '\n';
11081 TRACE("(%p %p)\n", istream
, str
);
11083 if(basic_istream_wchar_sentry_create(istream
, FALSE
)) {
11084 size_t count
= ios_base_width_get(&base
->base
)-1;
11086 for(c
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
));
11087 c
!=WEOF
&& !ctype_wchar_is_ch(ctype
, _SPACE
|_BLANK
, c
) && count
>0;
11088 c
= basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base
)), count
--) {
11089 state
= IOSTATE_goodbit
;
11093 basic_istream_wchar_sentry_destroy(istream
);
11096 ios_base_width_set(&base
->base
, 0);
11097 basic_ios_wchar_setstate(base
, state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
11101 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@PA_W@Z */
11102 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@PEA_W@Z */
11103 basic_istream_wchar
* __cdecl
basic_istream_wchar_read_str(basic_istream_wchar
*istream
, wchar_t *str
)
11105 return basic_istream_read_str(istream
, str
, ctype_wchar_use_facet(
11106 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
11109 /* ??$?5GU?$char_traits@G@std@@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@PAG@Z */
11110 /* ??$?5GU?$char_traits@G@std@@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@PEAG@Z */
11111 basic_istream_wchar
* __cdecl
basic_istream_short_read_str(basic_istream_wchar
*istream
, wchar_t *str
)
11113 return basic_istream_read_str(istream
, str
, ctype_short_use_facet(
11114 IOS_LOCALE(basic_istream_wchar_get_basic_ios(istream
)->strbuf
)));
11117 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AAV10@AA_W@Z */
11118 /* ??$?5_WU?$char_traits@_W@std@@@std@@YAAEAV?$basic_istream@_WU?$char_traits@_W@std@@@0@AEAV10@AEA_W@Z */
11119 /* ??$?5GU?$char_traits@G@std@@@std@@YAAAV?$basic_istream@GU?$char_traits@G@std@@@0@AAV10@AAG@Z */
11120 /* ??$?5GU?$char_traits@G@std@@@std@@YAAEAV?$basic_istream@GU?$char_traits@G@std@@@0@AEAV10@AEAG@Z */
11121 basic_istream_wchar
* __cdecl
basic_istream_wchar_read_ch(basic_istream_wchar
*istream
, wchar_t *ch
)
11123 IOSB_iostate state
= IOSTATE_failbit
;
11124 unsigned short c
= 0;
11126 TRACE("(%p %p)\n", istream
, ch
);
11128 if(basic_istream_wchar_sentry_create(istream
, FALSE
)) {
11129 c
= basic_streambuf_wchar_sbumpc(basic_ios_wchar_rdbuf_get(
11130 basic_istream_wchar_get_basic_ios(istream
)));
11132 state
= IOSTATE_goodbit
;
11136 basic_istream_wchar_sentry_destroy(istream
);
11138 basic_ios_wchar_setstate(basic_istream_wchar_get_basic_ios(istream
),
11139 state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
11143 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
11144 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
11145 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
11146 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
11147 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_streambuf
, 8)
11148 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_streambuf(
11149 basic_istream_wchar
*this, basic_streambuf_wchar
*streambuf
)
11151 basic_ios_wchar
*base
= basic_istream_wchar_get_basic_ios(this);
11152 IOSB_iostate state
= IOSTATE_failbit
;
11153 unsigned short c
= '\n';
11155 TRACE("(%p %p)\n", this, streambuf
);
11157 if(basic_istream_wchar_sentry_create(this, FALSE
)) {
11158 for(c
= basic_streambuf_wchar_sgetc(basic_ios_wchar_rdbuf_get(base
)); c
!=WEOF
;
11159 c
= basic_streambuf_wchar_snextc(basic_ios_wchar_rdbuf_get(base
))) {
11160 state
= IOSTATE_goodbit
;
11161 if(basic_streambuf_wchar_sputc(streambuf
, c
) == WEOF
)
11165 basic_istream_wchar_sentry_destroy(this);
11167 basic_ios_wchar_setstate(base
, state
| (c
==WEOF
? IOSTATE_eofbit
: IOSTATE_goodbit
));
11171 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
11172 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
11173 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV01@AAV01@@Z@Z */
11174 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z */
11175 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func
, 8)
11176 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_func(basic_istream_wchar
*this,
11177 basic_istream_wchar
* (__cdecl
*pfunc
)(basic_istream_wchar
*))
11179 TRACE("(%p %p)\n", this, pfunc
);
11184 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AAV21@@Z@Z */
11185 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@_WU?$char_traits@_W@std@@@1@AEAV21@@Z@Z */
11186 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAV?$basic_ios@GU?$char_traits@G@std@@@1@AAV21@@Z@Z */
11187 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAV?$basic_ios@GU?$char_traits@G@std@@@1@AEAV21@@Z@Z */
11188 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func_basic_ios
, 8)
11189 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_func_basic_ios(basic_istream_wchar
*this,
11190 basic_ios_wchar
* (__cdecl
*pfunc
)(basic_ios_wchar
*))
11192 TRACE("(%p %p)\n", this, pfunc
);
11193 pfunc(basic_istream_wchar_get_basic_ios(this));
11197 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
11198 /* ??5?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
11199 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z */
11200 /* ??5?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAAEAV01@P6AAEAVios_base@1@AEAV21@@Z@Z */
11201 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_read_func_ios_base
, 8)
11202 basic_istream_wchar
* __thiscall
basic_istream_wchar_read_func_ios_base(
11203 basic_istream_wchar
*this, ios_base
* (__cdecl
*pfunc
)(ios_base
*))
11205 TRACE("(%p %p)\n", this, pfunc
);
11206 pfunc(&basic_istream_wchar_get_basic_ios(this)->base
);
11210 /* ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z */
11211 /* ?swap@?$basic_istream@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z */
11212 /* ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z */
11213 /* ?swap@?$basic_istream@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z */
11214 DEFINE_THISCALL_WRAPPER(basic_istream_wchar_swap
, 8)
11215 void __thiscall
basic_istream_wchar_swap(basic_istream_wchar
*this, basic_istream_wchar
*r
)
11217 TRACE("(%p %p)\n", this, r
);
11222 basic_ios_wchar_swap(basic_istream_wchar_get_basic_ios(this),
11223 basic_istream_wchar_get_basic_ios(r
));
11224 this->count
^= r
->count
;
11225 r
->count
^= this->count
;
11226 this->count
^= r
->count
;
11229 static inline basic_ios_char
* basic_iostream_char_to_basic_ios(basic_iostream_char
*ptr
)
11231 return (basic_ios_char
*)((char*)ptr
+basic_iostream_char_vbtable1
[1]);
11234 static inline basic_iostream_char
* basic_iostream_char_from_basic_ios(basic_ios_char
*ptr
)
11236 return (basic_iostream_char
*)((char*)ptr
-basic_iostream_char_vbtable1
[1]);
11239 /* ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QAE@PAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
11240 /* ??0?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAA@PEAV?$basic_streambuf@DU?$char_traits@D@std@@@1@@Z */
11241 DEFINE_THISCALL_WRAPPER(basic_iostream_char_ctor
, 12)
11242 basic_iostream_char
* __thiscall
basic_iostream_char_ctor(basic_iostream_char
*this, basic_streambuf_char
*strbuf
, bool virt_init
)
11244 basic_ios_char
*basic_ios
;
11246 TRACE("(%p %p %d)\n", this, strbuf
, virt_init
);
11249 this->base1
.vbtable
= basic_iostream_char_vbtable1
;
11250 this->base2
.vbtable
= basic_iostream_char_vbtable2
;
11251 basic_ios
= basic_istream_char_get_basic_ios(&this->base1
);
11252 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11253 basic_ios_char_ctor(basic_ios
);
11255 basic_ios
= basic_istream_char_get_basic_ios(&this->base1
);
11258 basic_istream_char_ctor(&this->base1
, strbuf
, FALSE
, FALSE
);
11259 basic_ostream_char_ctor_uninitialized(&this->base2
, 0, FALSE
, FALSE
);
11260 basic_ios
->base
.vtable
= &MSVCP_basic_iostream_char_vtable
;
11264 /* ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UAE@XZ */
11265 /* ??1?$basic_iostream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
11266 DEFINE_THISCALL_WRAPPER(basic_iostream_char_dtor
, 4)
11267 void __thiscall
basic_iostream_char_dtor(basic_ios_char
*base
)
11269 basic_iostream_char
*this = basic_iostream_char_from_basic_ios(base
);
11271 TRACE("(%p)\n", this);
11272 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base2
));
11273 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base1
));
11276 /* ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11277 /* ??_D?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11278 DEFINE_THISCALL_WRAPPER(basic_iostream_char_vbase_dtor
, 4)
11279 void __thiscall
basic_iostream_char_vbase_dtor(basic_iostream_char
*this)
11281 basic_ios_char
*base
= basic_iostream_char_to_basic_ios(this);
11283 TRACE("(%p)\n", this);
11285 basic_iostream_char_dtor(base
);
11286 basic_ios_char_dtor(base
);
11289 DEFINE_THISCALL_WRAPPER(basic_iostream_char_vector_dtor
, 8)
11290 basic_iostream_char
* __thiscall
basic_iostream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
11292 basic_iostream_char
*this = basic_iostream_char_from_basic_ios(base
);
11294 TRACE("(%p %x)\n", this, flags
);
11297 /* we have an array, with the number of elements stored before the first object */
11298 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11300 for(i
=*ptr
-1; i
>=0; i
--)
11301 basic_iostream_char_vbase_dtor(this+i
);
11302 MSVCRT_operator_delete(ptr
);
11304 basic_iostream_char_vbase_dtor(this);
11306 MSVCRT_operator_delete(this);
11312 /* ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@QAEXAAV12@@Z */
11313 /* ?swap@?$basic_iostream@DU?$char_traits@D@std@@@std@@QEAAXAEAV12@@Z */
11314 DEFINE_THISCALL_WRAPPER(basic_iostream_char_swap
, 8)
11315 void __thiscall
basic_iostream_char_swap(basic_iostream_char
*this, basic_iostream_char
*r
)
11317 TRACE("(%p %p)\n", this, r
);
11322 basic_ios_char_swap(basic_istream_char_get_basic_ios(&this->base1
),
11323 basic_istream_char_get_basic_ios(&r
->base1
));
11326 static inline basic_ios_wchar
* basic_iostream_wchar_to_basic_ios(basic_iostream_wchar
*ptr
)
11328 return (basic_ios_wchar
*)((char*)ptr
+basic_iostream_wchar_vbtable1
[1]);
11331 static inline basic_iostream_wchar
* basic_iostream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
11333 return (basic_iostream_wchar
*)((char*)ptr
-basic_iostream_wchar_vbtable1
[1]);
11336 /* ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAE@PAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
11337 /* ??0?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAV?$basic_streambuf@_WU?$char_traits@_W@std@@@1@@Z */
11338 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_ctor
, 12)
11339 basic_iostream_wchar
* __thiscall
basic_iostream_wchar_ctor(basic_iostream_wchar
*this,
11340 basic_streambuf_wchar
*strbuf
, bool virt_init
)
11342 basic_ios_wchar
*basic_ios
;
11344 TRACE("(%p %p %d)\n", this, strbuf
, virt_init
);
11347 this->base1
.vbtable
= basic_iostream_wchar_vbtable1
;
11348 this->base2
.vbtable
= basic_iostream_wchar_vbtable2
;
11349 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base1
);
11350 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11351 basic_ios_wchar_ctor(basic_ios
);
11353 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base1
);
11356 basic_istream_wchar_ctor(&this->base1
, strbuf
, FALSE
, FALSE
);
11357 basic_ostream_wchar_ctor_uninitialized(&this->base2
, 0, FALSE
, FALSE
);
11359 basic_ios
->base
.vtable
= &MSVCP_basic_iostream_wchar_vtable
;
11363 /* ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QAE@PAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
11364 /* ??0?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAA@PEAV?$basic_streambuf@GU?$char_traits@G@std@@@1@@Z */
11365 DEFINE_THISCALL_WRAPPER(basic_iostream_short_ctor
, 12)
11366 basic_iostream_wchar
* __thiscall
basic_iostream_short_ctor(basic_iostream_wchar
*this,
11367 basic_streambuf_wchar
*strbuf
, bool virt_init
)
11369 basic_iostream_wchar_ctor(this, strbuf
, virt_init
);
11370 basic_istream_wchar_get_basic_ios(&this->base1
)->base
.vtable
= &MSVCP_basic_iostream_short_vtable
;
11374 /* ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
11375 /* ??1?$basic_iostream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
11376 /* ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UAE@XZ */
11377 /* ??1?$basic_iostream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
11378 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_dtor
, 4)
11379 void __thiscall
basic_iostream_wchar_dtor(basic_ios_wchar
*base
)
11381 basic_iostream_wchar
*this = basic_iostream_wchar_from_basic_ios(base
);
11383 TRACE("(%p)\n", this);
11384 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base2
));
11385 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base1
));
11388 /* ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11389 /* ??_D?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11390 /* ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11391 /* ??_D?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11392 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_vbase_dtor
, 4)
11393 void __thiscall
basic_iostream_wchar_vbase_dtor(basic_iostream_wchar
*this)
11395 basic_ios_wchar
*base
= basic_iostream_wchar_to_basic_ios(this);
11397 TRACE("(%p)\n", this);
11399 basic_iostream_wchar_dtor(base
);
11400 basic_ios_wchar_dtor(base
);
11403 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_vector_dtor
, 8)
11404 basic_iostream_wchar
* __thiscall
basic_iostream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
11406 basic_iostream_wchar
*this = basic_iostream_wchar_from_basic_ios(base
);
11408 TRACE("(%p %x)\n", this, flags
);
11411 /* we have an array, with the number of elements stored before the first object */
11412 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11414 for(i
=*ptr
-1; i
>=0; i
--)
11415 basic_iostream_wchar_vbase_dtor(this+i
);
11416 MSVCRT_operator_delete(ptr
);
11418 basic_iostream_wchar_vbase_dtor(this);
11420 MSVCRT_operator_delete(this);
11426 /* ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@QAEXAAV12@@Z */
11427 /* ?swap@?$basic_iostream@GU?$char_traits@G@std@@@std@@QEAAXAEAV12@@Z */
11428 /* ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QAEXAAV12@@Z */
11429 /* ?swap@?$basic_iostream@_WU?$char_traits@_W@std@@@std@@QEAAXAEAV12@@Z */
11430 DEFINE_THISCALL_WRAPPER(basic_iostream_wchar_swap
, 8)
11431 void __thiscall
basic_iostream_wchar_swap(basic_iostream_wchar
*this, basic_iostream_wchar
*r
)
11433 TRACE("(%p %p)\n", this, r
);
11438 basic_ios_wchar_swap(basic_istream_wchar_get_basic_ios(&this->base1
),
11439 basic_istream_wchar_get_basic_ios(&r
->base1
));
11442 static inline basic_ios_char
* basic_ofstream_char_to_basic_ios(basic_ofstream_char
*ptr
)
11444 return (basic_ios_char
*)((char*)ptr
+basic_ofstream_char_vbtable
[1]);
11447 static inline basic_ofstream_char
* basic_ofstream_char_from_basic_ios(basic_ios_char
*ptr
)
11449 return (basic_ofstream_char
*)((char*)ptr
-basic_ofstream_char_vbtable
[1]);
11452 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
11453 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
11454 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor
, 8)
11455 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor(basic_ofstream_char
*this, bool virt_init
)
11457 basic_ios_char
*basic_ios
;
11459 TRACE("(%p %d)\n", this, virt_init
);
11462 this->base
.vbtable
= basic_ofstream_char_vbtable
;
11463 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11464 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11465 basic_ios_char_ctor(basic_ios
);
11467 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11470 basic_filebuf_char_ctor(&this->filebuf
);
11471 basic_ostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11472 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_char_vtable
;
11476 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
11477 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11478 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_file
, 12)
11479 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor_file(
11480 basic_ofstream_char
*this, FILE *file
, bool virt_init
)
11482 basic_ios_char
*basic_ios
;
11484 TRACE("(%p %p %d)\n", this, file
, virt_init
);
11487 this->base
.vbtable
= basic_ofstream_char_vbtable
;
11488 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11489 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11490 basic_ios_char_ctor(basic_ios
);
11492 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11495 basic_filebuf_char_ctor_file(&this->filebuf
, file
);
11496 basic_ostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11497 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_char_vtable
;
11501 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
11502 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
11503 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_name
, 20)
11504 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor_name(basic_ofstream_char
*this,
11505 const char *name
, int mode
, int prot
, bool virt_init
)
11507 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
11509 basic_ofstream_char_ctor(this, virt_init
);
11511 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11512 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11513 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11518 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
11519 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
11520 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
11521 /* ??0?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
11522 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_ctor_name_wchar
, 20)
11523 basic_ofstream_char
* __thiscall
basic_ofstream_char_ctor_name_wchar(basic_ofstream_char
*this,
11524 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
11526 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
11528 basic_ofstream_char_ctor(this, virt_init
);
11530 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11531 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11532 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11537 /* ??1?$basic_ofstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
11538 /* ??1?$basic_ofstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
11539 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_dtor
, 4)
11540 void __thiscall
basic_ofstream_char_dtor(basic_ios_char
*base
)
11542 basic_ofstream_char
*this = basic_ofstream_char_from_basic_ios(base
);
11544 TRACE("(%p)\n", this);
11546 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base
));
11547 basic_filebuf_char_dtor(&this->filebuf
);
11550 /* ??_D?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11551 /* ??_D?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11552 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_vbase_dtor
, 4)
11553 void __thiscall
basic_ofstream_char_vbase_dtor(basic_ofstream_char
*this)
11555 basic_ios_char
*base
= basic_ofstream_char_to_basic_ios(this);
11557 TRACE("(%p)\n", this);
11559 basic_ofstream_char_dtor(base
);
11560 basic_ios_char_dtor(base
);
11563 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_vector_dtor
, 8)
11564 basic_ofstream_char
* __thiscall
basic_ofstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
11566 basic_ofstream_char
*this = basic_ofstream_char_from_basic_ios(base
);
11568 TRACE("(%p %x)\n", this, flags
);
11571 /* we have an array, with the number of elements stored before the first object */
11572 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11574 for(i
=*ptr
-1; i
>=0; i
--)
11575 basic_ofstream_char_vbase_dtor(this+i
);
11576 MSVCRT_operator_delete(ptr
);
11578 basic_ofstream_char_vbase_dtor(this);
11580 MSVCRT_operator_delete(this);
11586 /* ?close@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
11587 /* ?close@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
11588 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_close
, 4)
11589 void __thiscall
basic_ofstream_char_close(basic_ofstream_char
*this)
11591 TRACE("(%p)\n", this);
11593 if(!basic_filebuf_char_close(&this->filebuf
)) {
11594 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11595 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11599 /* ?is_open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
11600 /* ?is_open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
11601 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_is_open
, 4)
11602 bool __thiscall
basic_ofstream_char_is_open(const basic_ofstream_char
*this)
11604 TRACE("(%p)\n", this);
11605 return basic_filebuf_char_is_open(&this->filebuf
);
11608 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
11609 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
11610 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open
, 16)
11611 void __thiscall
basic_ofstream_char_open(basic_ofstream_char
*this,
11612 const char *name
, int mode
, int prot
)
11614 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
11616 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11617 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11618 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11622 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
11623 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
11624 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_old
, 12)
11625 void __thiscall
basic_ofstream_char_open_old(basic_ofstream_char
*this,
11626 const char *name
, unsigned int mode
)
11628 basic_ofstream_char_open(this, name
, mode
, _SH_DENYNO
);
11631 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
11632 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
11633 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
11634 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
11635 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_wchar
, 16)
11636 void __thiscall
basic_ofstream_char_open_wchar(basic_ofstream_char
*this,
11637 const wchar_t *name
, int mode
, int prot
)
11639 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
11641 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11642 basic_ios_char
*basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
11643 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
11647 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
11648 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
11649 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
11650 /* ?open@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
11651 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_open_wchar_old
, 12)
11652 void __thiscall
basic_ofstream_char_open_wchar_old(basic_ofstream_char
*this,
11653 const wchar_t *name
, unsigned int mode
)
11655 basic_ofstream_char_open_wchar(this, name
, mode
, _SH_DENYNO
);
11658 /* ?rdbuf@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11659 /* ?rdbuf@?$basic_ofstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
11660 DEFINE_THISCALL_WRAPPER(basic_ofstream_char_rdbuf
, 4)
11661 basic_filebuf_char
* __thiscall
basic_ofstream_char_rdbuf(const basic_ofstream_char
*this)
11663 TRACE("(%p)\n", this);
11664 return (basic_filebuf_char
*)&this->filebuf
;
11667 static inline basic_ios_wchar
* basic_ofstream_wchar_to_basic_ios(basic_ofstream_wchar
*ptr
)
11669 return (basic_ios_wchar
*)((char*)ptr
+basic_ofstream_wchar_vbtable
[1]);
11672 static inline basic_ofstream_wchar
* basic_ofstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
11674 return (basic_ofstream_wchar
*)((char*)ptr
-basic_ofstream_wchar_vbtable
[1]);
11677 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
11678 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
11679 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor
, 8)
11680 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor(basic_ofstream_wchar
*this, bool virt_init
)
11682 basic_ios_wchar
*basic_ios
;
11684 TRACE("(%p %d)\n", this, virt_init
);
11687 this->base
.vbtable
= basic_ofstream_wchar_vbtable
;
11688 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11689 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11690 basic_ios_wchar_ctor(basic_ios
);
11692 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11695 basic_filebuf_wchar_ctor(&this->filebuf
);
11696 basic_ostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11697 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_wchar_vtable
;
11701 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
11702 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
11703 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor
, 8)
11704 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor(basic_ofstream_wchar
*this, bool virt_init
)
11706 basic_ofstream_wchar_ctor(this, virt_init
);
11707 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11711 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
11712 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11713 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_file
, 12)
11714 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor_file(
11715 basic_ofstream_wchar
*this, FILE *file
, bool virt_init
)
11717 basic_ios_wchar
*basic_ios
;
11719 TRACE("(%p %p %d)\n", this, file
, virt_init
);
11722 this->base
.vbtable
= basic_ofstream_wchar_vbtable
;
11723 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11724 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11725 basic_ios_wchar_ctor(basic_ios
);
11727 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11730 basic_filebuf_wchar_ctor_file(&this->filebuf
, file
);
11731 basic_ostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11732 basic_ios
->base
.vtable
= &MSVCP_basic_ofstream_wchar_vtable
;
11736 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
11737 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11738 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_file
, 12)
11739 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor_file(
11740 basic_ofstream_wchar
*this, FILE *file
, bool virt_init
)
11742 basic_ofstream_wchar_ctor_file(this, file
, virt_init
);
11743 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11747 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDHH@Z */
11748 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDHH@Z */
11749 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_name
, 20)
11750 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor_name(basic_ofstream_wchar
*this,
11751 const char *name
, int mode
, int prot
, bool virt_init
)
11753 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
11755 basic_ofstream_wchar_ctor(this, virt_init
);
11757 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11758 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11759 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11764 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PBDHH@Z */
11765 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDHH@Z */
11766 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_name
, 20)
11767 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor_name(basic_ofstream_wchar
*this,
11768 const char *name
, int mode
, int prot
, bool virt_init
)
11770 basic_ofstream_wchar_ctor_name(this, name
, mode
, prot
, virt_init
);
11771 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11775 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
11776 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
11777 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
11778 /* ??0?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
11779 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_ctor_name_wchar
, 20)
11780 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_ctor_name_wchar(basic_ofstream_wchar
*this,
11781 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
11783 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
11785 basic_ofstream_wchar_ctor(this, virt_init
);
11787 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11788 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11789 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11794 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
11795 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
11796 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
11797 /* ??0?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
11798 DEFINE_THISCALL_WRAPPER(basic_ofstream_short_ctor_name_wchar
, 20)
11799 basic_ofstream_wchar
* __thiscall
basic_ofstream_short_ctor_name_wchar(basic_ofstream_wchar
*this,
11800 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
11802 basic_ofstream_wchar_ctor_name_wchar(this, name
, mode
, prot
, virt_init
);
11803 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ofstream_short_vtable
;
11807 /* ??1?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
11808 /* ??1?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
11809 /* ??1?$basic_ofstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
11810 /* ??1?$basic_ofstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
11811 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_dtor
, 4)
11812 void __thiscall
basic_ofstream_wchar_dtor(basic_ios_wchar
*base
)
11814 basic_ofstream_wchar
*this = basic_ofstream_wchar_from_basic_ios(base
);
11816 TRACE("(%p)\n", this);
11818 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base
));
11819 basic_filebuf_wchar_dtor(&this->filebuf
);
11822 /* ??_D?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11823 /* ??_D?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11824 /* ??_D?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11825 /* ??_D?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11826 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_vbase_dtor
, 4)
11827 void __thiscall
basic_ofstream_wchar_vbase_dtor(basic_ofstream_wchar
*this)
11829 basic_ios_wchar
*base
= basic_ofstream_wchar_to_basic_ios(this);
11831 TRACE("(%p)\n", this);
11833 basic_ofstream_wchar_dtor(base
);
11834 basic_ios_wchar_dtor(base
);
11837 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_vector_dtor
, 8)
11838 basic_ofstream_wchar
* __thiscall
basic_ofstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
11840 basic_ofstream_wchar
*this = basic_ofstream_wchar_from_basic_ios(base
);
11842 TRACE("(%p %x)\n", this, flags
);
11845 /* we have an array, with the number of elements stored before the first object */
11846 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
11848 for(i
=*ptr
-1; i
>=0; i
--)
11849 basic_ofstream_wchar_vbase_dtor(this+i
);
11850 MSVCRT_operator_delete(ptr
);
11852 basic_ofstream_wchar_vbase_dtor(this);
11854 MSVCRT_operator_delete(this);
11860 /* ?close@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
11861 /* ?close@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
11862 /* ?close@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
11863 /* ?close@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
11864 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_close
, 4)
11865 void __thiscall
basic_ofstream_wchar_close(basic_ofstream_wchar
*this)
11867 TRACE("(%p)\n", this);
11869 if(!basic_filebuf_wchar_close(&this->filebuf
)) {
11870 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11871 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11875 /* ?is_open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
11876 /* ?is_open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
11877 /* ?is_open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
11878 /* ?is_open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
11879 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_is_open
, 4)
11880 bool __thiscall
basic_ofstream_wchar_is_open(const basic_ofstream_wchar
*this)
11882 TRACE("(%p)\n", this);
11883 return basic_filebuf_wchar_is_open(&this->filebuf
);
11886 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
11887 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
11888 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
11889 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
11890 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open
, 16)
11891 void __thiscall
basic_ofstream_wchar_open(basic_ofstream_wchar
*this,
11892 const char *name
, int mode
, int prot
)
11894 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
11896 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11897 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11898 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11902 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
11903 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
11904 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
11905 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
11906 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_old
, 12)
11907 void __thiscall
basic_ofstream_wchar_open_old(basic_ofstream_wchar
*this,
11908 const char *name
, unsigned int mode
)
11910 basic_ofstream_wchar_open(this, name
, mode
, _SH_DENYNO
);
11913 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
11914 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
11915 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
11916 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
11917 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
11918 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
11919 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
11920 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
11921 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_wchar
, 16)
11922 void __thiscall
basic_ofstream_wchar_open_wchar(basic_ofstream_wchar
*this,
11923 const wchar_t *name
, int mode
, int prot
)
11925 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
11927 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_out
, prot
)) {
11928 basic_ios_wchar
*basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
11929 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
11933 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
11934 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
11935 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
11936 /* ?open@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
11937 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
11938 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
11939 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
11940 /* ?open@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
11941 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_open_wchar_old
, 12)
11942 void __thiscall
basic_ofstream_wchar_open_wchar_old(basic_ofstream_wchar
*this,
11943 const wchar_t *name
, unsigned int mode
)
11945 basic_ofstream_wchar_open_wchar(this, name
, mode
, _SH_DENYNO
);
11948 /* ?rdbuf@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
11949 /* ?rdbuf@?$basic_ofstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
11950 /* ?rdbuf@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
11951 /* ?rdbuf@?$basic_ofstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
11952 DEFINE_THISCALL_WRAPPER(basic_ofstream_wchar_rdbuf
, 4)
11953 basic_filebuf_wchar
* __thiscall
basic_ofstream_wchar_rdbuf(const basic_ofstream_wchar
*this)
11955 TRACE("(%p)\n", this);
11956 return (basic_filebuf_wchar
*)&this->filebuf
;
11959 static inline basic_ios_char
* basic_ifstream_char_to_basic_ios(basic_ifstream_char
*ptr
)
11961 return (basic_ios_char
*)((char*)ptr
+basic_ifstream_char_vbtable
[1]);
11964 static inline basic_ifstream_char
* basic_ifstream_char_from_basic_ios(basic_ios_char
*ptr
)
11966 return (basic_ifstream_char
*)((char*)ptr
-basic_ifstream_char_vbtable
[1]);
11969 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
11970 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
11971 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor
, 8)
11972 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor(basic_ifstream_char
*this, bool virt_init
)
11974 basic_ios_char
*basic_ios
;
11976 TRACE("(%p %d)\n", this, virt_init
);
11979 this->base
.vbtable
= basic_ifstream_char_vbtable
;
11980 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11981 INIT_BASIC_IOS_VTORDISP(basic_ios
);
11982 basic_ios_char_ctor(basic_ios
);
11984 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
11987 basic_filebuf_char_ctor(&this->filebuf
);
11988 basic_istream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
11989 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_char_vtable
;
11993 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
11994 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
11995 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_file
, 12)
11996 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_file(
11997 basic_ifstream_char
*this, FILE *file
, bool virt_init
)
11999 basic_ios_char
*basic_ios
;
12001 TRACE("(%p %p %d)\n", this, file
, virt_init
);
12004 this->base
.vbtable
= basic_ifstream_char_vbtable
;
12005 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12006 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12007 basic_ios_char_ctor(basic_ios
);
12009 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12012 basic_filebuf_char_ctor_file(&this->filebuf
, file
);
12013 basic_istream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
12014 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_char_vtable
;
12018 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
12019 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
12020 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name
, 20)
12021 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_name(basic_ifstream_char
*this,
12022 const char *name
, int mode
, int prot
, bool virt_init
)
12024 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
12026 basic_ifstream_char_ctor(this, virt_init
);
12028 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12029 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12030 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12035 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBDH@Z */
12036 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDH@Z */
12037 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name_old
, 16)
12038 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_name_old(basic_ifstream_char
*this,
12039 const char *name
, int mode
, bool virt_init
)
12041 return basic_ifstream_char_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12044 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
12045 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
12046 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
12047 /* ??0?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
12048 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_ctor_name_wchar
, 20)
12049 basic_ifstream_char
* __thiscall
basic_ifstream_char_ctor_name_wchar(basic_ifstream_char
*this,
12050 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
12052 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
12054 basic_ifstream_char_ctor(this, virt_init
);
12056 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12057 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12058 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12063 /* ??1?$basic_ifstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
12064 /* ??1?$basic_ifstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
12065 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_dtor
, 4)
12066 void __thiscall
basic_ifstream_char_dtor(basic_ios_char
*base
)
12068 basic_ifstream_char
*this = basic_ifstream_char_from_basic_ios(base
);
12070 TRACE("(%p)\n", this);
12072 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base
));
12073 basic_filebuf_char_dtor(&this->filebuf
);
12076 /* ??_D?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
12077 /* ??_D?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
12078 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_vbase_dtor
, 4)
12079 void __thiscall
basic_ifstream_char_vbase_dtor(basic_ifstream_char
*this)
12081 basic_ios_char
*base
= basic_ifstream_char_to_basic_ios(this);
12083 TRACE("(%p)\n", this);
12085 basic_ifstream_char_dtor(base
);
12086 basic_ios_char_dtor(base
);
12089 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_vector_dtor
, 8)
12090 basic_ifstream_char
* __thiscall
basic_ifstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
12092 basic_ifstream_char
*this = basic_ifstream_char_from_basic_ios(base
);
12094 TRACE("(%p %x)\n", this, flags
);
12097 /* we have an array, with the number of elements stored before the first object */
12098 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12100 for(i
=*ptr
-1; i
>=0; i
--)
12101 basic_ifstream_char_vbase_dtor(this+i
);
12102 MSVCRT_operator_delete(ptr
);
12104 basic_ifstream_char_vbase_dtor(this);
12106 MSVCRT_operator_delete(this);
12112 /* ?close@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
12113 /* ?close@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
12114 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_close
, 4)
12115 void __thiscall
basic_ifstream_char_close(basic_ifstream_char
*this)
12117 TRACE("(%p)\n", this);
12119 if(!basic_filebuf_char_close(&this->filebuf
)) {
12120 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12121 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12125 /* ?is_open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
12126 /* ?is_open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
12127 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_is_open
, 4)
12128 bool __thiscall
basic_ifstream_char_is_open(const basic_ifstream_char
*this)
12130 TRACE("(%p)\n", this);
12131 return basic_filebuf_char_is_open(&this->filebuf
);
12134 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
12135 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
12136 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open
, 16)
12137 void __thiscall
basic_ifstream_char_open(basic_ifstream_char
*this,
12138 const char *name
, int mode
, int prot
)
12140 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12142 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12143 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12144 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12148 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
12149 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
12150 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_old
, 12)
12151 void __thiscall
basic_ifstream_char_open_old(basic_ifstream_char
*this,
12152 const char *name
, unsigned int mode
)
12154 basic_ifstream_char_open(this, name
, mode
, _SH_DENYNO
);
12157 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
12158 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
12159 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
12160 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
12161 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_wchar
, 16)
12162 void __thiscall
basic_ifstream_char_open_wchar(basic_ifstream_char
*this,
12163 const wchar_t *name
, int mode
, int prot
)
12165 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
12167 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12168 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
12169 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12173 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
12174 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
12175 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
12176 /* ?open@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
12177 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_open_wchar_old
, 12)
12178 void __thiscall
basic_ifstream_char_open_wchar_old(basic_ifstream_char
*this,
12179 const wchar_t *name
, unsigned int mode
)
12181 basic_ifstream_char_open_wchar(this, name
, mode
, _SH_DENYNO
);
12184 /* ?rdbuf@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
12185 /* ?rdbuf@?$basic_ifstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
12186 DEFINE_THISCALL_WRAPPER(basic_ifstream_char_rdbuf
, 4)
12187 basic_filebuf_char
* __thiscall
basic_ifstream_char_rdbuf(const basic_ifstream_char
*this)
12189 TRACE("(%p)\n", this);
12190 return (basic_filebuf_char
*)&this->filebuf
;
12193 static inline basic_ios_wchar
* basic_ifstream_wchar_to_basic_ios(basic_ifstream_wchar
*ptr
)
12195 return (basic_ios_wchar
*)((char*)ptr
+basic_ifstream_wchar_vbtable
[1]);
12198 static inline basic_ifstream_wchar
* basic_ifstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
12200 return (basic_ifstream_wchar
*)((char*)ptr
-basic_ifstream_wchar_vbtable
[1]);
12203 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
12204 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
12205 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor
, 8)
12206 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor(basic_ifstream_wchar
*this, bool virt_init
)
12208 basic_ios_wchar
*basic_ios
;
12210 TRACE("(%p %d)\n", this, virt_init
);
12213 this->base
.vbtable
= basic_ifstream_wchar_vbtable
;
12214 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12215 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12216 basic_ios_wchar_ctor(basic_ios
);
12218 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12221 basic_filebuf_wchar_ctor(&this->filebuf
);
12222 basic_istream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
12223 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_wchar_vtable
;
12227 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
12228 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
12229 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor
, 8)
12230 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor(basic_ifstream_wchar
*this, bool virt_init
)
12232 basic_ifstream_wchar_ctor(this, virt_init
);
12233 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
12237 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
12238 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12239 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_file
, 12)
12240 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_file(
12241 basic_ifstream_wchar
*this, FILE *file
, bool virt_init
)
12243 basic_ios_wchar
*basic_ios
;
12245 TRACE("(%p %p %d)\n", this, file
, virt_init
);
12248 this->base
.vbtable
= basic_ifstream_wchar_vbtable
;
12249 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12250 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12251 basic_ios_wchar_ctor(basic_ios
);
12253 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12256 basic_filebuf_wchar_ctor_file(&this->filebuf
, file
);
12257 basic_istream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
, FALSE
);
12258 basic_ios
->base
.vtable
= &MSVCP_basic_ifstream_wchar_vtable
;
12262 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
12263 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12264 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_file
, 12)
12265 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_file(
12266 basic_ifstream_wchar
*this, FILE *file
, bool virt_init
)
12268 basic_ifstream_wchar_ctor_file(this, file
, virt_init
);
12269 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
12273 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDHH@Z */
12274 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDHH@Z */
12275 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name
, 20)
12276 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_name(basic_ifstream_wchar
*this,
12277 const char *name
, int mode
, int prot
, bool virt_init
)
12279 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
12281 basic_ifstream_wchar_ctor(this, virt_init
);
12283 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12284 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12285 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12290 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBDHH@Z */
12291 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDHH@Z */
12292 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name
, 20)
12293 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_name(basic_ifstream_wchar
*this,
12294 const char *name
, int mode
, int prot
, bool virt_init
)
12296 basic_ifstream_wchar_ctor_name(this, name
, mode
, prot
, virt_init
);
12297 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
12301 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDH@Z */
12302 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBDH@Z */
12303 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name_old
, 16)
12304 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_name_old(basic_ifstream_wchar
*this,
12305 const char *name
, int mode
, bool virt_init
)
12307 return basic_ifstream_wchar_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12310 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBDH@Z */
12311 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDH@Z */
12312 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name_old
, 16)
12313 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_name_old(basic_ifstream_wchar
*this,
12314 const char *name
, int mode
, bool virt_init
)
12316 return basic_ifstream_short_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12319 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
12320 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
12321 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
12322 /* ??0?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
12323 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_ctor_name_wchar
, 20)
12324 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_ctor_name_wchar(basic_ifstream_wchar
*this,
12325 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
12327 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
12329 basic_ifstream_wchar_ctor(this, virt_init
);
12331 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12332 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12333 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12338 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
12339 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
12340 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
12341 /* ??0?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
12342 DEFINE_THISCALL_WRAPPER(basic_ifstream_short_ctor_name_wchar
, 20)
12343 basic_ifstream_wchar
* __thiscall
basic_ifstream_short_ctor_name_wchar(basic_ifstream_wchar
*this,
12344 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
12346 basic_ifstream_wchar_ctor_name_wchar(this, name
, mode
, prot
, virt_init
);
12347 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ifstream_short_vtable
;
12351 /* ??1?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
12352 /* ??1?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
12353 /* ??1?$basic_ifstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
12354 /* ??1?$basic_ifstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
12355 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_dtor
, 4)
12356 void __thiscall
basic_ifstream_wchar_dtor(basic_ios_wchar
*base
)
12358 basic_ifstream_wchar
*this = basic_ifstream_wchar_from_basic_ios(base
);
12360 TRACE("(%p)\n", this);
12362 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base
));
12363 basic_filebuf_wchar_dtor(&this->filebuf
);
12366 /* ??_D?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
12367 /* ??_D?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
12368 /* ??_D?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
12369 /* ??_D?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
12370 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_vbase_dtor
, 4)
12371 void __thiscall
basic_ifstream_wchar_vbase_dtor(basic_ifstream_wchar
*this)
12373 basic_ios_wchar
*base
= basic_ifstream_wchar_to_basic_ios(this);
12375 TRACE("(%p)\n", this);
12377 basic_ifstream_wchar_dtor(base
);
12378 basic_ios_wchar_dtor(base
);
12381 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_vector_dtor
, 8)
12382 basic_ifstream_wchar
* __thiscall
basic_ifstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
12384 basic_ifstream_wchar
*this = basic_ifstream_wchar_from_basic_ios(base
);
12386 TRACE("(%p %x)\n", this, flags
);
12389 /* we have an array, with the number of elements stored before the first object */
12390 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12392 for(i
=*ptr
-1; i
>=0; i
--)
12393 basic_ifstream_wchar_vbase_dtor(this+i
);
12394 MSVCRT_operator_delete(ptr
);
12396 basic_ifstream_wchar_vbase_dtor(this);
12398 MSVCRT_operator_delete(this);
12404 /* ?close@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
12405 /* ?close@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
12406 /* ?close@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
12407 /* ?close@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
12408 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_close
, 4)
12409 void __thiscall
basic_ifstream_wchar_close(basic_ifstream_wchar
*this)
12411 TRACE("(%p)\n", this);
12413 if(!basic_filebuf_wchar_close(&this->filebuf
)) {
12414 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12415 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12419 /* ?is_open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
12420 /* ?is_open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
12421 /* ?is_open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
12422 /* ?is_open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
12423 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_is_open
, 4)
12424 bool __thiscall
basic_ifstream_wchar_is_open(const basic_ifstream_wchar
*this)
12426 TRACE("(%p)\n", this);
12427 return basic_filebuf_wchar_is_open(&this->filebuf
);
12430 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
12431 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
12432 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
12433 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
12434 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open
, 16)
12435 void __thiscall
basic_ifstream_wchar_open(basic_ifstream_wchar
*this,
12436 const char *name
, int mode
, int prot
)
12438 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12440 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12441 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12442 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12446 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
12447 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
12448 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
12449 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
12450 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_old
, 12)
12451 void __thiscall
basic_ifstream_wchar_open_old(basic_ifstream_wchar
*this,
12452 const char *name
, unsigned int mode
)
12454 basic_ifstream_wchar_open(this, name
, mode
, _SH_DENYNO
);
12457 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
12458 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
12459 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
12460 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
12461 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
12462 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
12463 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
12464 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
12465 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_wchar
, 16)
12466 void __thiscall
basic_ifstream_wchar_open_wchar(basic_ifstream_wchar
*this,
12467 const wchar_t *name
, int mode
, int prot
)
12469 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
12471 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
|OPENMODE_in
, prot
)) {
12472 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
12473 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12477 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
12478 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
12479 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
12480 /* ?open@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
12481 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
12482 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
12483 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
12484 /* ?open@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
12485 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_open_wchar_old
, 12)
12486 void __thiscall
basic_ifstream_wchar_open_wchar_old(basic_ifstream_wchar
*this,
12487 const wchar_t *name
, unsigned int mode
)
12489 basic_ifstream_wchar_open_wchar(this, name
, mode
, _SH_DENYNO
);
12492 /* ?rdbuf@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
12493 /* ?rdbuf@?$basic_ifstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
12494 /* ?rdbuf@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
12495 /* ?rdbuf@?$basic_ifstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
12496 DEFINE_THISCALL_WRAPPER(basic_ifstream_wchar_rdbuf
, 4)
12497 basic_filebuf_wchar
* __thiscall
basic_ifstream_wchar_rdbuf(const basic_ifstream_wchar
*this)
12499 TRACE("(%p)\n", this);
12500 return (basic_filebuf_wchar
*)&this->filebuf
;
12503 static inline basic_ios_char
* basic_fstream_char_to_basic_ios(basic_fstream_char
*ptr
)
12505 return (basic_ios_char
*)((char*)ptr
+basic_fstream_char_vbtable1
[1]);
12508 static inline basic_fstream_char
* basic_fstream_char_from_basic_ios(basic_ios_char
*ptr
)
12510 return (basic_fstream_char
*)((char*)ptr
-basic_fstream_char_vbtable1
[1]);
12513 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@XZ */
12514 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@XZ */
12515 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor
, 8)
12516 basic_fstream_char
* __thiscall
basic_fstream_char_ctor(basic_fstream_char
*this, bool virt_init
)
12518 basic_ios_char
*basic_ios
;
12520 TRACE("(%p %d)\n", this, virt_init
);
12523 this->base
.base1
.vbtable
= basic_fstream_char_vbtable1
;
12524 this->base
.base2
.vbtable
= basic_fstream_char_vbtable2
;
12525 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12526 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12527 basic_ios_char_ctor(basic_ios
);
12529 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12532 basic_filebuf_char_ctor(&this->filebuf
);
12533 basic_iostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12534 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_char_vtable
;
12538 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PAU_iobuf@@@Z */
12539 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12540 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_file
, 12)
12541 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_file(basic_fstream_char
*this,
12542 FILE *file
, bool virt_init
)
12544 basic_ios_char
*basic_ios
;
12546 TRACE("(%p %p %d)\n", this, file
, virt_init
);
12549 this->base
.base1
.vbtable
= basic_fstream_char_vbtable1
;
12550 this->base
.base2
.vbtable
= basic_fstream_char_vbtable2
;
12551 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12552 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12553 basic_ios_char_ctor(basic_ios
);
12555 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12558 basic_filebuf_char_ctor_file(&this->filebuf
, file
);
12559 basic_iostream_char_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12560 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_char_vtable
;
12564 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBDHH@Z */
12565 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDHH@Z */
12566 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name
, 20)
12567 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_name(basic_fstream_char
*this,
12568 const char *name
, int mode
, int prot
, bool virt_init
)
12570 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
12572 basic_fstream_char_ctor(this, virt_init
);
12574 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
, prot
)) {
12575 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12576 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12581 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBDH@Z */
12582 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBDH@Z */
12583 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name_noprot
, 16)
12584 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_name_noprot(basic_fstream_char
*this,
12585 const char *name
, int mode
, bool virt_init
)
12587 return basic_fstream_char_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12590 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PBGHH@Z */
12591 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEBGHH@Z */
12592 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QAE@PB_WHH@Z */
12593 /* ??0?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAA@PEB_WHH@Z */
12594 DEFINE_THISCALL_WRAPPER(basic_fstream_char_ctor_name_wchar
, 20)
12595 basic_fstream_char
* __thiscall
basic_fstream_char_ctor_name_wchar(basic_fstream_char
*this,
12596 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
12598 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
12600 basic_fstream_char_ctor(this, virt_init
);
12602 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12603 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12604 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12609 /* ??1?$basic_fstream@DU?$char_traits@D@std@@@std@@UAE@XZ */
12610 /* ??1?$basic_fstream@DU?$char_traits@D@std@@@std@@UEAA@XZ */
12611 DEFINE_THISCALL_WRAPPER(basic_fstream_char_dtor
, 4)
12612 void __thiscall
basic_fstream_char_dtor(basic_ios_char
*base
)
12614 basic_fstream_char
*this = basic_fstream_char_from_basic_ios(base
);
12616 TRACE("(%p)\n", this);
12618 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base
));
12619 basic_filebuf_char_dtor(&this->filebuf
);
12622 /* ??_D?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
12623 /* ??_D?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
12624 DEFINE_THISCALL_WRAPPER(basic_fstream_char_vbase_dtor
, 4)
12625 void __thiscall
basic_fstream_char_vbase_dtor(basic_fstream_char
*this)
12627 basic_ios_char
*base
= basic_fstream_char_to_basic_ios(this);
12629 TRACE("(%p)\n", this);
12631 basic_fstream_char_dtor(base
);
12632 basic_ios_char_dtor(base
);
12635 DEFINE_THISCALL_WRAPPER(basic_fstream_char_vector_dtor
, 8)
12636 basic_fstream_char
* __thiscall
basic_fstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
12638 basic_fstream_char
*this = basic_fstream_char_from_basic_ios(base
);
12640 TRACE("(%p %x)\n", this, flags
);
12643 /* we have an array, with the number of elements stored before the first object */
12644 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12646 for(i
=*ptr
-1; i
>=0; i
--)
12647 basic_fstream_char_vbase_dtor(this+i
);
12648 MSVCRT_operator_delete(ptr
);
12650 basic_fstream_char_vbase_dtor(this);
12652 MSVCRT_operator_delete(this);
12658 /* ?close@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXXZ */
12659 /* ?close@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXXZ */
12660 DEFINE_THISCALL_WRAPPER(basic_fstream_char_close
, 4)
12661 void __thiscall
basic_fstream_char_close(basic_fstream_char
*this)
12663 TRACE("(%p)\n", this);
12665 if(!basic_filebuf_char_close(&this->filebuf
)) {
12666 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12667 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12671 /* ?is_open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QBE_NXZ */
12672 /* ?is_open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEBA_NXZ */
12673 DEFINE_THISCALL_WRAPPER(basic_fstream_char_is_open
, 4)
12674 bool __thiscall
basic_fstream_char_is_open(const basic_fstream_char
*this)
12676 TRACE("(%p)\n", this);
12677 return basic_filebuf_char_is_open(&this->filebuf
);
12680 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBDHH@Z */
12681 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDHH@Z */
12682 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open
, 16)
12683 void __thiscall
basic_fstream_char_open(basic_fstream_char
*this,
12684 const char *name
, int mode
, int prot
)
12686 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12688 if(!basic_filebuf_char_open(&this->filebuf
, name
, mode
, prot
)) {
12689 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12690 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12694 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBDI@Z */
12695 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBDI@Z */
12696 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_old
, 12)
12697 void __thiscall
basic_fstream_char_open_old(basic_fstream_char
*this,
12698 const char *name
, unsigned int mode
)
12700 basic_fstream_char_open(this, name
, mode
, _SH_DENYNO
);
12703 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBGHH@Z */
12704 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGHH@Z */
12705 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPB_WHH@Z */
12706 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WHH@Z */
12707 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_wchar
, 16)
12708 void __thiscall
basic_fstream_char_open_wchar(basic_fstream_char
*this,
12709 const wchar_t *name
, int mode
, int prot
)
12711 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
12713 if(!basic_filebuf_char_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12714 basic_ios_char
*basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
12715 basic_ios_char_setstate(basic_ios
, IOSTATE_failbit
);
12719 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPBGI@Z */
12720 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEBGI@Z */
12721 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QAEXPB_WI@Z */
12722 /* ?open@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEAAXPEB_WI@Z */
12723 DEFINE_THISCALL_WRAPPER(basic_fstream_char_open_wchar_old
, 12)
12724 void __thiscall
basic_fstream_char_open_wchar_old(basic_fstream_char
*this,
12725 const wchar_t *name
, unsigned int mode
)
12727 basic_fstream_char_open_wchar(this, name
, mode
, _SH_DENYNO
);
12730 /* ?rdbuf@?$basic_fstream@DU?$char_traits@D@std@@@std@@QBEPAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
12731 /* ?rdbuf@?$basic_fstream@DU?$char_traits@D@std@@@std@@QEBAPEAV?$basic_filebuf@DU?$char_traits@D@std@@@2@XZ */
12732 DEFINE_THISCALL_WRAPPER(basic_fstream_char_rdbuf
, 4)
12733 basic_filebuf_char
* __thiscall
basic_fstream_char_rdbuf(const basic_fstream_char
*this)
12735 TRACE("(%p)\n", this);
12736 return (basic_filebuf_char
*)&this->filebuf
;
12739 static inline basic_ios_wchar
* basic_fstream_wchar_to_basic_ios(basic_fstream_wchar
*ptr
)
12741 return (basic_ios_wchar
*)((char*)ptr
+basic_fstream_wchar_vbtable1
[1]);
12744 static inline basic_fstream_wchar
* basic_fstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
12746 return (basic_fstream_wchar
*)((char*)ptr
-basic_fstream_wchar_vbtable1
[1]);
12749 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@XZ */
12750 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@XZ */
12751 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor
, 8)
12752 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor(basic_fstream_wchar
*this, bool virt_init
)
12754 basic_ios_wchar
*basic_ios
;
12756 TRACE("(%p %d)\n", this, virt_init
);
12759 this->base
.base1
.vbtable
= basic_fstream_wchar_vbtable1
;
12760 this->base
.base2
.vbtable
= basic_fstream_wchar_vbtable2
;
12761 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12762 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12763 basic_ios_wchar_ctor(basic_ios
);
12765 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12768 basic_filebuf_wchar_ctor(&this->filebuf
);
12769 basic_iostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12770 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_wchar_vtable
;
12774 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@XZ */
12775 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@XZ */
12776 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor
, 8)
12777 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor(basic_fstream_wchar
*this, bool virt_init
)
12779 basic_fstream_wchar_ctor(this, virt_init
);
12780 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12784 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PAU_iobuf@@@Z */
12785 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12786 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_file
, 12)
12787 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_file(basic_fstream_wchar
*this,
12788 FILE *file
, bool virt_init
)
12790 basic_ios_wchar
*basic_ios
;
12792 TRACE("(%p %p %d)\n", this, file
, virt_init
);
12795 this->base
.base1
.vbtable
= basic_fstream_wchar_vbtable1
;
12796 this->base
.base2
.vbtable
= basic_fstream_wchar_vbtable2
;
12797 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12798 INIT_BASIC_IOS_VTORDISP(basic_ios
);
12799 basic_ios_wchar_ctor(basic_ios
);
12801 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12804 basic_filebuf_wchar_ctor_file(&this->filebuf
, file
);
12805 basic_iostream_wchar_ctor(&this->base
, &this->filebuf
.base
, FALSE
);
12806 basic_ios
->base
.vtable
= &MSVCP_basic_fstream_wchar_vtable
;
12810 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PAU_iobuf@@@Z */
12811 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEAU_iobuf@@@Z */
12812 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_file
, 12)
12813 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_file(basic_fstream_wchar
*this,
12814 FILE *file
, bool virt_init
)
12816 basic_fstream_wchar_ctor_file(this, file
, virt_init
);
12817 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12821 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
12822 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
12823 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name
, 20)
12824 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_name(basic_fstream_wchar
*this,
12825 const char *name
, int mode
, int prot
, bool virt_init
)
12827 TRACE("(%p %s %d %d %d)\n", this, name
, mode
, prot
, virt_init
);
12829 basic_fstream_wchar_ctor(this, virt_init
);
12831 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
, prot
)) {
12832 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12833 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12838 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
12839 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
12840 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name
, 20)
12841 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_name(basic_fstream_wchar
*this,
12842 const char *name
, int mode
, int prot
, bool virt_init
)
12844 basic_fstream_wchar_ctor_name(this, name
, mode
, prot
, virt_init
);
12845 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12849 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PBDH@Z */
12850 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name_noprot
, 16)
12851 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_name_noprot(basic_fstream_wchar
*this,
12852 const char *name
, int mode
, bool virt_init
)
12854 return basic_fstream_wchar_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12857 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBDH@Z */
12858 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBDH@Z */
12859 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name_noprot
, 16)
12860 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_name_noprot(basic_fstream_wchar
*this,
12861 const char *name
, int mode
, bool virt_init
)
12863 return basic_fstream_short_ctor_name(this, name
, mode
, _SH_DENYNO
, virt_init
);
12866 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PBGHH@Z */
12867 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEBGHH@Z */
12868 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAE@PB_WHH@Z */
12869 /* ??0?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAA@PEB_WHH@Z */
12870 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_ctor_name_wchar
, 20)
12871 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_ctor_name_wchar(basic_fstream_wchar
*this,
12872 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
12874 TRACE("(%p %s %d %d %d)\n", this, debugstr_w(name
), mode
, prot
, virt_init
);
12876 basic_fstream_wchar_ctor(this, virt_init
);
12878 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
12879 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12880 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12885 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PBGHH@Z */
12886 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEBGHH@Z */
12887 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QAE@PB_WHH@Z */
12888 /* ??0?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAA@PEB_WHH@Z */
12889 DEFINE_THISCALL_WRAPPER(basic_fstream_short_ctor_name_wchar
, 20)
12890 basic_fstream_wchar
* __thiscall
basic_fstream_short_ctor_name_wchar(basic_fstream_wchar
*this,
12891 const wchar_t *name
, int mode
, int prot
, bool virt_init
)
12893 basic_fstream_wchar_ctor_name_wchar(this, name
, mode
, prot
, virt_init
);
12894 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_fstream_short_vtable
;
12898 /* ??1?$basic_fstream@_WU?$char_traits@_W@std@@@std@@UAE@XZ */
12899 /* ??1?$basic_fstream@_WU?$char_traits@_W@std@@@std@@UEAA@XZ */
12900 /* ??1?$basic_fstream@GU?$char_traits@G@std@@@std@@UAE@XZ */
12901 /* ??1?$basic_fstream@GU?$char_traits@G@std@@@std@@UEAA@XZ */
12902 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_dtor
, 4)
12903 void __thiscall
basic_fstream_wchar_dtor(basic_ios_wchar
*base
)
12905 basic_fstream_wchar
*this = basic_fstream_wchar_from_basic_ios(base
);
12907 TRACE("(%p)\n", this);
12909 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(&this->base
));
12910 basic_filebuf_wchar_dtor(&this->filebuf
);
12913 /* ??_D?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
12914 /* ??_D?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
12915 /* ??_D?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
12916 /* ??_D?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
12917 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_vbase_dtor
, 4)
12918 void __thiscall
basic_fstream_wchar_vbase_dtor(basic_fstream_wchar
*this)
12920 basic_ios_wchar
*base
= basic_fstream_wchar_to_basic_ios(this);
12922 TRACE("(%p)\n", this);
12924 basic_fstream_wchar_dtor(base
);
12925 basic_ios_wchar_dtor(base
);
12928 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_vector_dtor
, 8)
12929 basic_fstream_wchar
* __thiscall
basic_fstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
12931 basic_fstream_wchar
*this = basic_fstream_wchar_from_basic_ios(base
);
12933 TRACE("(%p %x)\n", this, flags
);
12936 /* we have an array, with the number of elements stored before the first object */
12937 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
12939 for(i
=*ptr
-1; i
>=0; i
--)
12940 basic_fstream_wchar_vbase_dtor(this+i
);
12941 MSVCRT_operator_delete(ptr
);
12943 basic_fstream_wchar_vbase_dtor(this);
12945 MSVCRT_operator_delete(this);
12951 /* ?close@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXXZ */
12952 /* ?close@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXXZ */
12953 /* ?close@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXXZ */
12954 /* ?close@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXXZ */
12955 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_close
, 4)
12956 void __thiscall
basic_fstream_wchar_close(basic_fstream_wchar
*this)
12958 TRACE("(%p)\n", this);
12960 if(!basic_filebuf_wchar_close(&this->filebuf
)) {
12961 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12962 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12966 /* ?is_open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QBE_NXZ */
12967 /* ?is_open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEBA_NXZ */
12968 /* ?is_open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QBE_NXZ */
12969 /* ?is_open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEBA_NXZ */
12970 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_is_open
, 4)
12971 bool __thiscall
basic_fstream_wchar_is_open(const basic_fstream_wchar
*this)
12973 TRACE("(%p)\n", this);
12974 return basic_filebuf_wchar_is_open(&this->filebuf
);
12977 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDHH@Z */
12978 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDHH@Z */
12979 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBDHH@Z */
12980 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDHH@Z */
12981 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open
, 16)
12982 void __thiscall
basic_fstream_wchar_open(basic_fstream_wchar
*this,
12983 const char *name
, int mode
, int prot
)
12985 TRACE("(%p %s %d %d)\n", this, name
, mode
, prot
);
12987 if(!basic_filebuf_wchar_open(&this->filebuf
, name
, mode
, prot
)) {
12988 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
12989 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
12993 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBDI@Z */
12994 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBDI@Z */
12995 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBDI@Z */
12996 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBDI@Z */
12997 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_old
, 12)
12998 void __thiscall
basic_fstream_wchar_open_old(basic_fstream_wchar
*this,
12999 const char *name
, unsigned int mode
)
13001 basic_fstream_wchar_open(this, name
, mode
, _SH_DENYNO
);
13004 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGHH@Z */
13005 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGHH@Z */
13006 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WHH@Z */
13007 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WHH@Z */
13008 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBGHH@Z */
13009 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGHH@Z */
13010 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPB_WHH@Z */
13011 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WHH@Z */
13012 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_wchar
, 16)
13013 void __thiscall
basic_fstream_wchar_open_wchar(basic_fstream_wchar
*this,
13014 const wchar_t *name
, int mode
, int prot
)
13016 TRACE("(%p %s %d %d)\n", this, debugstr_w(name
), mode
, prot
);
13018 if(!basic_filebuf_wchar_open_wchar(&this->filebuf
, name
, mode
, prot
)) {
13019 basic_ios_wchar
*basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13020 basic_ios_wchar_setstate(basic_ios
, IOSTATE_failbit
);
13024 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPBGI@Z */
13025 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEBGI@Z */
13026 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QAEXPB_WI@Z */
13027 /* ?open@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEAAXPEB_WI@Z */
13028 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPBGI@Z */
13029 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEBGI@Z */
13030 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QAEXPB_WI@Z */
13031 /* ?open@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEAAXPEB_WI@Z */
13032 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_open_wchar_old
, 12)
13033 void __thiscall
basic_fstream_wchar_open_wchar_old(basic_fstream_wchar
*this,
13034 const wchar_t *name
, unsigned int mode
)
13036 basic_fstream_wchar_open_wchar(this, name
, mode
, _SH_DENYNO
);
13039 /* ?rdbuf@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QBEPAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
13040 /* ?rdbuf@?$basic_fstream@_WU?$char_traits@_W@std@@@std@@QEBAPEAV?$basic_filebuf@_WU?$char_traits@_W@std@@@2@XZ */
13041 /* ?rdbuf@?$basic_fstream@GU?$char_traits@G@std@@@std@@QBEPAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
13042 /* ?rdbuf@?$basic_fstream@GU?$char_traits@G@std@@@std@@QEBAPEAV?$basic_filebuf@GU?$char_traits@G@std@@@2@XZ */
13043 DEFINE_THISCALL_WRAPPER(basic_fstream_wchar_rdbuf
, 4)
13044 basic_filebuf_wchar
* __thiscall
basic_fstream_wchar_rdbuf(const basic_fstream_wchar
*this)
13046 TRACE("(%p)\n", this);
13047 return (basic_filebuf_wchar
*)&this->filebuf
;
13050 static inline basic_ios_char
* basic_ostringstream_char_to_basic_ios(basic_ostringstream_char
*ptr
)
13052 return (basic_ios_char
*)((char*)ptr
+basic_ostringstream_char_vbtable
[1]);
13055 static inline basic_ostringstream_char
* basic_ostringstream_char_from_basic_ios(basic_ios_char
*ptr
)
13057 return (basic_ostringstream_char
*)((char*)ptr
-basic_ostringstream_char_vbtable
[1]);
13060 /* ??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 */
13061 /* ??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 */
13062 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor_str
, 16)
13063 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_ctor_str(basic_ostringstream_char
*this,
13064 const basic_string_char
*str
, int mode
, bool virt_init
)
13066 basic_ios_char
*basic_ios
;
13068 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13071 this->base
.vbtable
= basic_ostringstream_char_vbtable
;
13072 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
13073 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13074 basic_ios_char_ctor(basic_ios
);
13076 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
13079 basic_stringbuf_char_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_out
);
13080 basic_ostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13081 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_char_vtable
;
13085 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
13086 /* ??0?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
13087 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor_mode
, 12)
13088 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_ctor_mode(
13089 basic_ostringstream_char
*this, int mode
, bool virt_init
)
13091 basic_ios_char
*basic_ios
;
13093 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13096 this->base
.vbtable
= basic_ostringstream_char_vbtable
;
13097 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
13098 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13099 basic_ios_char_ctor(basic_ios
);
13101 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
13104 basic_stringbuf_char_ctor_mode(&this->strbuf
, mode
|OPENMODE_out
);
13105 basic_ostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13106 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_char_vtable
;
13110 /* ??_F?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13111 /* ??_F?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13112 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_ctor
, 4)
13113 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_ctor(
13114 basic_ostringstream_char
*this)
13116 return basic_ostringstream_char_ctor_mode(this, 0, TRUE
);
13119 /* ??1?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
13120 /* ??1?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
13121 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_dtor
, 4)
13122 void __thiscall
basic_ostringstream_char_dtor(basic_ios_char
*base
)
13124 basic_ostringstream_char
*this = basic_ostringstream_char_from_basic_ios(base
);
13126 TRACE("(%p)\n", this);
13128 basic_stringbuf_char_dtor(&this->strbuf
);
13129 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base
));
13132 /* ??_D?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13133 /* ??_D?$basic_ostringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13134 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_vbase_dtor
, 4)
13135 void __thiscall
basic_ostringstream_char_vbase_dtor(basic_ostringstream_char
*this)
13137 basic_ios_char
*base
= basic_ostringstream_char_to_basic_ios(this);
13139 TRACE("(%p)\n", this);
13141 basic_ostringstream_char_dtor(base
);
13142 basic_ios_char_dtor(base
);
13145 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_vector_dtor
, 8)
13146 basic_ostringstream_char
* __thiscall
basic_ostringstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
13148 basic_ostringstream_char
*this = basic_ostringstream_char_from_basic_ios(base
);
13150 TRACE("(%p %x)\n", this, flags
);
13153 /* we have an array, with the number of elements stored before the first object */
13154 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13156 for(i
=*ptr
-1; i
>=0; i
--)
13157 basic_ostringstream_char_vbase_dtor(this+i
);
13158 MSVCRT_operator_delete(ptr
);
13160 basic_ostringstream_char_vbase_dtor(this);
13162 MSVCRT_operator_delete(this);
13168 /* ?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 */
13169 /* ?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 */
13170 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_rdbuf
, 4)
13171 basic_stringbuf_char
* __thiscall
basic_ostringstream_char_rdbuf(const basic_ostringstream_char
*this)
13173 TRACE("(%p)\n", this);
13174 return (basic_stringbuf_char
*)&this->strbuf
;
13177 /* ?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 */
13178 /* ?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 */
13179 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_str_set
, 8)
13180 void __thiscall
basic_ostringstream_char_str_set(basic_ostringstream_char
*this, const basic_string_char
*str
)
13182 TRACE("(%p %p)\n", this, str
);
13183 basic_stringbuf_char_str_set(&this->strbuf
, str
);
13186 /* ?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 */
13187 /* ?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 */
13188 DEFINE_THISCALL_WRAPPER(basic_ostringstream_char_str_get
, 8)
13189 basic_string_char
* __thiscall
basic_ostringstream_char_str_get(const basic_ostringstream_char
*this, basic_string_char
*ret
)
13191 TRACE("(%p %p)\n", this, ret
);
13192 return basic_stringbuf_char_str_get(&this->strbuf
, ret
);
13195 static inline basic_ios_wchar
* basic_ostringstream_wchar_to_basic_ios(basic_ostringstream_wchar
*ptr
)
13197 return (basic_ios_wchar
*)((char*)ptr
+basic_ostringstream_wchar_vbtable
[1]);
13200 static inline basic_ostringstream_wchar
* basic_ostringstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
13202 return (basic_ostringstream_wchar
*)((char*)ptr
-basic_ostringstream_wchar_vbtable
[1]);
13205 /* ??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 */
13206 /* ??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 */
13207 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor_str
, 16)
13208 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_ctor_str(basic_ostringstream_wchar
*this,
13209 const basic_string_wchar
*str
, int mode
, bool virt_init
)
13211 basic_ios_wchar
*basic_ios
;
13213 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13216 this->base
.vbtable
= basic_ostringstream_wchar_vbtable
;
13217 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
13218 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13219 basic_ios_wchar_ctor(basic_ios
);
13221 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
13224 basic_stringbuf_wchar_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_out
);
13225 basic_ostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13226 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_wchar_vtable
;
13230 /* ??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 */
13231 /* ??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 */
13232 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor_str
, 16)
13233 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_short_ctor_str(basic_ostringstream_wchar
*this,
13234 const basic_string_wchar
*str
, int mode
, bool virt_init
)
13236 basic_ostringstream_wchar_ctor_str(this, str
, mode
, virt_init
);
13237 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ostringstream_short_vtable
;
13241 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
13242 /* ??0?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
13243 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor_mode
, 12)
13244 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_ctor_mode(
13245 basic_ostringstream_wchar
*this, int mode
, bool virt_init
)
13247 basic_ios_wchar
*basic_ios
;
13249 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13252 this->base
.vbtable
= basic_ostringstream_wchar_vbtable
;
13253 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
13254 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13255 basic_ios_wchar_ctor(basic_ios
);
13257 basic_ios
= basic_ostream_wchar_get_basic_ios(&this->base
);
13260 basic_stringbuf_wchar_ctor_mode(&this->strbuf
, mode
|OPENMODE_out
);
13261 basic_ostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13262 basic_ios
->base
.vtable
= &MSVCP_basic_ostringstream_wchar_vtable
;
13266 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
13267 /* ??0?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
13268 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor_mode
, 12)
13269 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_short_ctor_mode(
13270 basic_ostringstream_wchar
*this, int mode
, bool virt_init
)
13272 basic_ostringstream_wchar_ctor_mode(this, mode
, virt_init
);
13273 basic_ostream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_ostringstream_short_vtable
;
13277 /* ??_F?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13278 /* ??_F?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13279 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_ctor
, 4)
13280 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_ctor(
13281 basic_ostringstream_wchar
*this)
13283 return basic_ostringstream_wchar_ctor_mode(this, 0, TRUE
);
13286 /* ??_F?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13287 /* ??_F?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13288 DEFINE_THISCALL_WRAPPER(basic_ostringstream_short_ctor
, 4)
13289 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_short_ctor(
13290 basic_ostringstream_wchar
*this)
13292 return basic_ostringstream_short_ctor_mode(this, 0, TRUE
);
13295 /* ??1?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
13296 /* ??1?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
13297 /* ??1?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
13298 /* ??1?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
13299 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_dtor
, 4)
13300 void __thiscall
basic_ostringstream_wchar_dtor(basic_ios_wchar
*base
)
13302 basic_ostringstream_wchar
*this = basic_ostringstream_wchar_from_basic_ios(base
);
13304 TRACE("(%p)\n", this);
13306 basic_stringbuf_wchar_dtor(&this->strbuf
);
13307 basic_ostream_wchar_dtor(basic_ostream_wchar_to_basic_ios(&this->base
));
13310 /* ??_D?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13311 /* ??_D?$basic_ostringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13312 /* ??_D?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13313 /* ??_D?$basic_ostringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13314 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_vbase_dtor
, 4)
13315 void __thiscall
basic_ostringstream_wchar_vbase_dtor(basic_ostringstream_wchar
*this)
13317 basic_ios_wchar
*base
= basic_ostringstream_wchar_to_basic_ios(this);
13319 TRACE("(%p)\n", this);
13321 basic_ostringstream_wchar_dtor(base
);
13322 basic_ios_wchar_dtor(base
);
13325 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_vector_dtor
, 8)
13326 basic_ostringstream_wchar
* __thiscall
basic_ostringstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
13328 basic_ostringstream_wchar
*this = basic_ostringstream_wchar_from_basic_ios(base
);
13330 TRACE("(%p %x)\n", this, flags
);
13333 /* we have an array, with the number of elements stored before the first object */
13334 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13336 for(i
=*ptr
-1; i
>=0; i
--)
13337 basic_ostringstream_wchar_vbase_dtor(this+i
);
13338 MSVCRT_operator_delete(ptr
);
13340 basic_ostringstream_wchar_vbase_dtor(this);
13342 MSVCRT_operator_delete(this);
13348 /* ?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 */
13349 /* ?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 */
13350 /* ?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 */
13351 /* ?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 */
13352 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_rdbuf
, 4)
13353 basic_stringbuf_wchar
* __thiscall
basic_ostringstream_wchar_rdbuf(const basic_ostringstream_wchar
*this)
13355 TRACE("(%p)\n", this);
13356 return (basic_stringbuf_wchar
*)&this->strbuf
;
13359 /* ?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 */
13360 /* ?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 */
13361 /* ?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 */
13362 /* ?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 */
13363 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_str_set
, 8)
13364 void __thiscall
basic_ostringstream_wchar_str_set(basic_ostringstream_wchar
*this, const basic_string_wchar
*str
)
13366 TRACE("(%p %p)\n", this, str
);
13367 basic_stringbuf_wchar_str_set(&this->strbuf
, str
);
13370 /* ?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 */
13371 /* ?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 */
13372 /* ?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 */
13373 /* ?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 */
13374 DEFINE_THISCALL_WRAPPER(basic_ostringstream_wchar_str_get
, 8)
13375 basic_string_wchar
* __thiscall
basic_ostringstream_wchar_str_get(const basic_ostringstream_wchar
*this, basic_string_wchar
*ret
)
13377 TRACE("(%p %p)\n", this, ret
);
13378 return basic_stringbuf_wchar_str_get(&this->strbuf
, ret
);
13381 static inline basic_ios_char
* basic_istringstream_char_to_basic_ios(basic_istringstream_char
*ptr
)
13383 return (basic_ios_char
*)((char*)ptr
+basic_istringstream_char_vbtable
[1]);
13386 static inline basic_istringstream_char
* basic_istringstream_char_from_basic_ios(basic_ios_char
*ptr
)
13388 return (basic_istringstream_char
*)((char*)ptr
-basic_istringstream_char_vbtable
[1]);
13391 /* ??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 */
13392 /* ??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 */
13393 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor_str
, 16)
13394 basic_istringstream_char
* __thiscall
basic_istringstream_char_ctor_str(basic_istringstream_char
*this,
13395 const basic_string_char
*str
, int mode
, bool virt_init
)
13397 basic_ios_char
*basic_ios
;
13399 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13402 this->base
.vbtable
= basic_istringstream_char_vbtable
;
13403 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
13404 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13405 basic_ios_char_ctor(basic_ios
);
13407 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
13410 basic_stringbuf_char_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_in
);
13411 basic_istream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13412 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_char_vtable
;
13416 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
13417 /* ??0?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
13418 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor_mode
, 12)
13419 basic_istringstream_char
* __thiscall
basic_istringstream_char_ctor_mode(
13420 basic_istringstream_char
*this, int mode
, bool virt_init
)
13422 basic_ios_char
*basic_ios
;
13424 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13427 this->base
.vbtable
= basic_istringstream_char_vbtable
;
13428 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
13429 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13430 basic_ios_char_ctor(basic_ios
);
13432 basic_ios
= basic_istream_char_get_basic_ios(&this->base
);
13435 basic_stringbuf_char_ctor_mode(&this->strbuf
, mode
|OPENMODE_in
);
13436 basic_istream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13437 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_char_vtable
;
13441 /* ??_F?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13442 /* ??_F?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13443 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_ctor
, 4)
13444 basic_istringstream_char
* __thiscall
basic_istringstream_char_ctor(
13445 basic_istringstream_char
*this)
13447 return basic_istringstream_char_ctor_mode(this, 0, TRUE
);
13450 /* ??1?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
13451 /* ??1?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
13452 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_dtor
, 4)
13453 void __thiscall
basic_istringstream_char_dtor(basic_ios_char
*base
)
13455 basic_istringstream_char
*this = basic_istringstream_char_from_basic_ios(base
);
13457 TRACE("(%p)\n", this);
13459 basic_stringbuf_char_dtor(&this->strbuf
);
13460 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base
));
13463 /* ??_D?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13464 /* ??_D?$basic_istringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13465 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_vbase_dtor
, 4)
13466 void __thiscall
basic_istringstream_char_vbase_dtor(basic_istringstream_char
*this)
13468 basic_ios_char
*base
= basic_istringstream_char_to_basic_ios(this);
13470 TRACE("(%p)\n", this);
13472 basic_istringstream_char_dtor(base
);
13473 basic_ios_char_dtor(base
);
13476 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_vector_dtor
, 8)
13477 basic_istringstream_char
* __thiscall
basic_istringstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
13479 basic_istringstream_char
*this = basic_istringstream_char_from_basic_ios(base
);
13481 TRACE("(%p %x)\n", this, flags
);
13484 /* we have an array, with the number of elements stored before the first object */
13485 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13487 for(i
=*ptr
-1; i
>=0; i
--)
13488 basic_istringstream_char_vbase_dtor(this+i
);
13489 MSVCRT_operator_delete(ptr
);
13491 basic_istringstream_char_vbase_dtor(this);
13493 MSVCRT_operator_delete(this);
13499 /* ?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 */
13500 /* ?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 */
13501 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_rdbuf
, 4)
13502 basic_stringbuf_char
* __thiscall
basic_istringstream_char_rdbuf(const basic_istringstream_char
*this)
13504 TRACE("(%p)\n", this);
13505 return (basic_stringbuf_char
*)&this->strbuf
;
13508 /* ?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 */
13509 /* ?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 */
13510 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_str_set
, 8)
13511 void __thiscall
basic_istringstream_char_str_set(basic_istringstream_char
*this, const basic_string_char
*str
)
13513 TRACE("(%p %p)\n", this, str
);
13514 basic_stringbuf_char_str_set(&this->strbuf
, str
);
13517 /* ?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 */
13518 /* ?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 */
13519 DEFINE_THISCALL_WRAPPER(basic_istringstream_char_str_get
, 8)
13520 basic_string_char
* __thiscall
basic_istringstream_char_str_get(const basic_istringstream_char
*this, basic_string_char
*ret
)
13522 TRACE("(%p %p)\n", this, ret
);
13523 return basic_stringbuf_char_str_get(&this->strbuf
, ret
);
13526 static inline basic_ios_wchar
* basic_istringstream_wchar_to_basic_ios(basic_istringstream_wchar
*ptr
)
13528 return (basic_ios_wchar
*)((char*)ptr
+basic_istringstream_wchar_vbtable
[1]);
13531 static inline basic_istringstream_wchar
* basic_istringstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
13533 return (basic_istringstream_wchar
*)((char*)ptr
-basic_istringstream_wchar_vbtable
[1]);
13536 /* ??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 */
13537 /* ??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 */
13538 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor_str
, 16)
13539 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_ctor_str(basic_istringstream_wchar
*this,
13540 const basic_string_wchar
*str
, int mode
, bool virt_init
)
13542 basic_ios_wchar
*basic_ios
;
13544 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13547 this->base
.vbtable
= basic_istringstream_wchar_vbtable
;
13548 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13549 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13550 basic_ios_wchar_ctor(basic_ios
);
13552 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13555 basic_stringbuf_wchar_ctor_str(&this->strbuf
, str
, mode
|OPENMODE_in
);
13556 basic_istream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13557 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_wchar_vtable
;
13561 /* ??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 */
13562 /* ??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 */
13563 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor_str
, 16)
13564 basic_istringstream_wchar
* __thiscall
basic_istringstream_short_ctor_str(basic_istringstream_wchar
*this,
13565 const basic_string_wchar
*str
, int mode
, bool virt_init
)
13567 basic_istringstream_wchar_ctor_str(this, str
, mode
, virt_init
);
13568 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_istringstream_short_vtable
;
13572 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
13573 /* ??0?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
13574 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor_mode
, 12)
13575 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_ctor_mode(
13576 basic_istringstream_wchar
*this, int mode
, bool virt_init
)
13578 basic_ios_wchar
*basic_ios
;
13580 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13583 this->base
.vbtable
= basic_istringstream_wchar_vbtable
;
13584 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13585 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13586 basic_ios_wchar_ctor(basic_ios
);
13588 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
);
13591 basic_stringbuf_wchar_ctor_mode(&this->strbuf
, mode
|OPENMODE_in
);
13592 basic_istream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
, FALSE
);
13593 basic_ios
->base
.vtable
= &MSVCP_basic_istringstream_wchar_vtable
;
13597 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
13598 /* ??0?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
13599 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor_mode
, 12)
13600 basic_istringstream_wchar
* __thiscall
basic_istringstream_short_ctor_mode(
13601 basic_istringstream_wchar
*this, int mode
, bool virt_init
)
13603 basic_istringstream_wchar_ctor_mode(this, mode
, virt_init
);
13604 basic_istream_wchar_get_basic_ios(&this->base
)->base
.vtable
= &MSVCP_basic_istringstream_short_vtable
;
13608 /* ??_F?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13609 /* ??_F?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13610 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_ctor
, 4)
13611 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_ctor(
13612 basic_istringstream_wchar
*this)
13614 return basic_istringstream_wchar_ctor_mode(this, 0, TRUE
);
13617 /* ??_F?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13618 /* ??_F?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13619 DEFINE_THISCALL_WRAPPER(basic_istringstream_short_ctor
, 4)
13620 basic_istringstream_wchar
* __thiscall
basic_istringstream_short_ctor(
13621 basic_istringstream_wchar
*this)
13623 return basic_istringstream_short_ctor_mode(this, 0, TRUE
);
13626 /* ??1?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
13627 /* ??1?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
13628 /* ??1?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
13629 /* ??1?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
13630 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_dtor
, 4)
13631 void __thiscall
basic_istringstream_wchar_dtor(basic_ios_wchar
*base
)
13633 basic_istringstream_wchar
*this = basic_istringstream_wchar_from_basic_ios(base
);
13635 TRACE("(%p)\n", this);
13637 basic_stringbuf_wchar_dtor(&this->strbuf
);
13638 basic_istream_wchar_dtor(basic_istream_wchar_to_basic_ios(&this->base
));
13641 /* ??_D?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13642 /* ??_D?$basic_istringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13643 /* ??_D?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13644 /* ??_D?$basic_istringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13645 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_vbase_dtor
, 4)
13646 void __thiscall
basic_istringstream_wchar_vbase_dtor(basic_istringstream_wchar
*this)
13648 basic_ios_wchar
*base
= basic_istringstream_wchar_to_basic_ios(this);
13650 TRACE("(%p)\n", this);
13652 basic_istringstream_wchar_dtor(base
);
13653 basic_ios_wchar_dtor(base
);
13656 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_vector_dtor
, 8)
13657 basic_istringstream_wchar
* __thiscall
basic_istringstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
13659 basic_istringstream_wchar
*this = basic_istringstream_wchar_from_basic_ios(base
);
13661 TRACE("(%p %x)\n", this, flags
);
13664 /* we have an array, with the number of elements stored before the first object */
13665 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13667 for(i
=*ptr
-1; i
>=0; i
--)
13668 basic_istringstream_wchar_vbase_dtor(this+i
);
13669 MSVCRT_operator_delete(ptr
);
13671 basic_istringstream_wchar_vbase_dtor(this);
13673 MSVCRT_operator_delete(this);
13679 /* ?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 */
13680 /* ?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 */
13681 /* ?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 */
13682 /* ?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 */
13683 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_rdbuf
, 4)
13684 basic_stringbuf_wchar
* __thiscall
basic_istringstream_wchar_rdbuf(const basic_istringstream_wchar
*this)
13686 TRACE("(%p)\n", this);
13687 return (basic_stringbuf_wchar
*)&this->strbuf
;
13690 /* ?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 */
13691 /* ?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 */
13692 /* ?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 */
13693 /* ?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 */
13694 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_str_set
, 8)
13695 void __thiscall
basic_istringstream_wchar_str_set(basic_istringstream_wchar
*this, const basic_string_wchar
*str
)
13697 TRACE("(%p %p)\n", this, str
);
13698 basic_stringbuf_wchar_str_set(&this->strbuf
, str
);
13701 /* ?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 */
13702 /* ?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 */
13703 /* ?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 */
13704 /* ?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 */
13705 DEFINE_THISCALL_WRAPPER(basic_istringstream_wchar_str_get
, 8)
13706 basic_string_wchar
* __thiscall
basic_istringstream_wchar_str_get(const basic_istringstream_wchar
*this, basic_string_wchar
*ret
)
13708 TRACE("(%p %p)\n", this, ret
);
13709 return basic_stringbuf_wchar_str_get(&this->strbuf
, ret
);
13712 static inline basic_ios_char
* basic_stringstream_char_to_basic_ios(basic_stringstream_char
*ptr
)
13714 return (basic_ios_char
*)((char*)ptr
+basic_stringstream_char_vbtable1
[1]);
13717 static inline basic_stringstream_char
* basic_stringstream_char_from_basic_ios(basic_ios_char
*ptr
)
13719 return (basic_stringstream_char
*)((char*)ptr
-basic_stringstream_char_vbtable1
[1]);
13722 /* ??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 */
13723 /* ??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 */
13724 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor_str
, 16)
13725 basic_stringstream_char
* __thiscall
basic_stringstream_char_ctor_str(basic_stringstream_char
*this,
13726 const basic_string_char
*str
, int mode
, bool virt_init
)
13728 basic_ios_char
*basic_ios
;
13730 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13733 this->base
.base1
.vbtable
= basic_stringstream_char_vbtable1
;
13734 this->base
.base2
.vbtable
= basic_stringstream_char_vbtable2
;
13735 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13736 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13737 basic_ios_char_ctor(basic_ios
);
13739 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13742 basic_stringbuf_char_ctor_str(&this->strbuf
, str
, mode
);
13743 basic_iostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13744 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_char_vtable
;
13748 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAE@H@Z */
13749 /* ??0?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAA@H@Z */
13750 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor_mode
, 12)
13751 basic_stringstream_char
* __thiscall
basic_stringstream_char_ctor_mode(
13752 basic_stringstream_char
*this, int mode
, bool virt_init
)
13754 basic_ios_char
*basic_ios
;
13756 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13759 this->base
.base1
.vbtable
= basic_stringstream_char_vbtable1
;
13760 this->base
.base2
.vbtable
= basic_stringstream_char_vbtable2
;
13761 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13762 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13763 basic_ios_char_ctor(basic_ios
);
13765 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
13768 basic_stringbuf_char_ctor_mode(&this->strbuf
, mode
);
13769 basic_iostream_char_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13770 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_char_vtable
;
13774 /* ??_F?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13775 /* ??_F?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13776 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_ctor
, 4)
13777 basic_stringstream_char
* __thiscall
basic_stringstream_char_ctor(
13778 basic_stringstream_char
*this)
13780 return basic_stringstream_char_ctor_mode(
13781 this, OPENMODE_out
|OPENMODE_in
, TRUE
);
13784 /* ??1?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UAE@XZ */
13785 /* ??1?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@UEAA@XZ */
13786 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_dtor
, 4)
13787 void __thiscall
basic_stringstream_char_dtor(basic_ios_char
*base
)
13789 basic_stringstream_char
*this = basic_stringstream_char_from_basic_ios(base
);
13791 TRACE("(%p)\n", this);
13793 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base
));
13794 basic_stringbuf_char_dtor(&this->strbuf
);
13797 /* ??_D?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QAEXXZ */
13798 /* ??_D?$basic_stringstream@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@QEAAXXZ */
13799 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_vbase_dtor
, 4)
13800 void __thiscall
basic_stringstream_char_vbase_dtor(basic_stringstream_char
*this)
13802 basic_ios_char
*base
= basic_stringstream_char_to_basic_ios(this);
13804 TRACE("(%p)\n", this);
13806 basic_stringstream_char_dtor(base
);
13807 basic_ios_char_dtor(base
);
13810 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_vector_dtor
, 8)
13811 basic_stringstream_char
* __thiscall
basic_stringstream_char_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
13813 basic_stringstream_char
*this = basic_stringstream_char_from_basic_ios(base
);
13815 TRACE("(%p %x)\n", this, flags
);
13818 /* we have an array, with the number of elements stored before the first object */
13819 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
13821 for(i
=*ptr
-1; i
>=0; i
--)
13822 basic_stringstream_char_vbase_dtor(this+i
);
13823 MSVCRT_operator_delete(ptr
);
13825 basic_stringstream_char_vbase_dtor(this);
13827 MSVCRT_operator_delete(this);
13833 /* ?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 */
13834 /* ?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 */
13835 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_rdbuf
, 4)
13836 basic_stringbuf_char
* __thiscall
basic_stringstream_char_rdbuf(const basic_stringstream_char
*this)
13838 TRACE("(%p)\n", this);
13839 return (basic_stringbuf_char
*)&this->strbuf
;
13842 /* ?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 */
13843 /* ?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 */
13844 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_str_set
, 8)
13845 void __thiscall
basic_stringstream_char_str_set(basic_stringstream_char
*this, const basic_string_char
*str
)
13847 TRACE("(%p %p)\n", this, str
);
13848 basic_stringbuf_char_str_set(&this->strbuf
, str
);
13851 /* ?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 */
13852 /* ?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 */
13853 DEFINE_THISCALL_WRAPPER(basic_stringstream_char_str_get
, 8)
13854 basic_string_char
* __thiscall
basic_stringstream_char_str_get(const basic_stringstream_char
*this, basic_string_char
*ret
)
13856 TRACE("(%p %p)\n", this, ret
);
13857 return basic_stringbuf_char_str_get(&this->strbuf
, ret
);
13860 static inline basic_ios_wchar
* basic_stringstream_wchar_to_basic_ios(basic_stringstream_wchar
*ptr
)
13862 return (basic_ios_wchar
*)((char*)ptr
+basic_stringstream_wchar_vbtable1
[1]);
13865 static inline basic_stringstream_wchar
* basic_stringstream_wchar_from_basic_ios(basic_ios_wchar
*ptr
)
13867 return (basic_stringstream_wchar
*)((char*)ptr
-basic_stringstream_wchar_vbtable1
[1]);
13870 /* ??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 */
13871 /* ??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 */
13872 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor_str
, 16)
13873 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_ctor_str(basic_stringstream_wchar
*this,
13874 const basic_string_wchar
*str
, int mode
, bool virt_init
)
13876 basic_ios_wchar
*basic_ios
;
13878 TRACE("(%p %p %d %d)\n", this, str
, mode
, virt_init
);
13881 this->base
.base1
.vbtable
= basic_stringstream_wchar_vbtable1
;
13882 this->base
.base2
.vbtable
= basic_stringstream_wchar_vbtable2
;
13883 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13884 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13885 basic_ios_wchar_ctor(basic_ios
);
13887 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13890 basic_stringbuf_wchar_ctor_str(&this->strbuf
, str
, mode
);
13891 basic_iostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13892 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_wchar_vtable
;
13896 /* ??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 */
13897 /* ??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 */
13898 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor_str
, 16)
13899 basic_stringstream_wchar
* __thiscall
basic_stringstream_short_ctor_str(basic_stringstream_wchar
*this,
13900 const basic_string_wchar
*str
, int mode
, bool virt_init
)
13902 basic_stringstream_wchar_ctor_str(this, str
, mode
, virt_init
);
13903 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_stringstream_short_vtable
;
13907 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAE@H@Z */
13908 /* ??0?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAA@H@Z */
13909 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor_mode
, 12)
13910 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_ctor_mode(
13911 basic_stringstream_wchar
*this, int mode
, bool virt_init
)
13913 basic_ios_wchar
*basic_ios
;
13915 TRACE("(%p %d %d)\n", this, mode
, virt_init
);
13918 this->base
.base1
.vbtable
= basic_stringstream_wchar_vbtable1
;
13919 this->base
.base2
.vbtable
= basic_stringstream_wchar_vbtable2
;
13920 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13921 INIT_BASIC_IOS_VTORDISP(basic_ios
);
13922 basic_ios_wchar_ctor(basic_ios
);
13924 basic_ios
= basic_istream_wchar_get_basic_ios(&this->base
.base1
);
13927 basic_stringbuf_wchar_ctor_mode(&this->strbuf
, mode
);
13928 basic_iostream_wchar_ctor(&this->base
, &this->strbuf
.base
, FALSE
);
13929 basic_ios
->base
.vtable
= &MSVCP_basic_stringstream_wchar_vtable
;
13933 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAE@H@Z */
13934 /* ??0?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAA@H@Z */
13935 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor_mode
, 12)
13936 basic_stringstream_wchar
* __thiscall
basic_stringstream_short_ctor_mode(
13937 basic_stringstream_wchar
*this, int mode
, bool virt_init
)
13939 basic_stringstream_wchar_ctor_mode(this, mode
, virt_init
);
13940 basic_istream_wchar_get_basic_ios(&this->base
.base1
)->base
.vtable
= &MSVCP_basic_stringstream_short_vtable
;
13944 /* ??_F?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13945 /* ??_F?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13946 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_ctor
, 4)
13947 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_ctor(
13948 basic_stringstream_wchar
*this)
13950 return basic_stringstream_wchar_ctor_mode(
13951 this, OPENMODE_out
|OPENMODE_in
, TRUE
);
13954 /* ??_F?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13955 /* ??_F?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13956 DEFINE_THISCALL_WRAPPER(basic_stringstream_short_ctor
, 4)
13957 basic_stringstream_wchar
* __thiscall
basic_stringstream_short_ctor(
13958 basic_stringstream_wchar
*this)
13960 return basic_stringstream_short_ctor_mode(
13961 this, OPENMODE_out
|OPENMODE_in
, TRUE
);
13964 /* ??1?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UAE@XZ */
13965 /* ??1?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@UEAA@XZ */
13966 /* ??1?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UAE@XZ */
13967 /* ??1?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@UEAA@XZ */
13968 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_dtor
, 4)
13969 void __thiscall
basic_stringstream_wchar_dtor(basic_ios_wchar
*base
)
13971 basic_stringstream_wchar
*this = basic_stringstream_wchar_from_basic_ios(base
);
13973 TRACE("(%p)\n", this);
13975 basic_iostream_wchar_dtor(basic_iostream_wchar_to_basic_ios(&this->base
));
13976 basic_stringbuf_wchar_dtor(&this->strbuf
);
13979 /* ??_D?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QAEXXZ */
13980 /* ??_D?$basic_stringstream@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@std@@QEAAXXZ */
13981 /* ??_D?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QAEXXZ */
13982 /* ??_D?$basic_stringstream@GU?$char_traits@G@std@@V?$allocator@G@2@@std@@QEAAXXZ */
13983 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_vbase_dtor
, 4)
13984 void __thiscall
basic_stringstream_wchar_vbase_dtor(basic_stringstream_wchar
*this)
13986 basic_ios_wchar
*base
= basic_stringstream_wchar_to_basic_ios(this);
13988 TRACE("(%p)\n", this);
13990 basic_stringstream_wchar_dtor(base
);
13991 basic_ios_wchar_dtor(base
);
13994 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_vector_dtor
, 8)
13995 basic_stringstream_wchar
* __thiscall
basic_stringstream_wchar_vector_dtor(basic_ios_wchar
*base
, unsigned int flags
)
13997 basic_stringstream_wchar
*this = basic_stringstream_wchar_from_basic_ios(base
);
13999 TRACE("(%p %x)\n", this, flags
);
14002 /* we have an array, with the number of elements stored before the first object */
14003 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
14005 for(i
=*ptr
-1; i
>=0; i
--)
14006 basic_stringstream_wchar_vbase_dtor(this+i
);
14007 MSVCRT_operator_delete(ptr
);
14009 basic_stringstream_wchar_vbase_dtor(this);
14011 MSVCRT_operator_delete(this);
14017 /* ?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 */
14018 /* ?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 */
14019 /* ?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 */
14020 /* ?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 */
14021 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_rdbuf
, 4)
14022 basic_stringbuf_wchar
* __thiscall
basic_stringstream_wchar_rdbuf(const basic_stringstream_wchar
*this)
14024 TRACE("(%p)\n", this);
14025 return (basic_stringbuf_wchar
*)&this->strbuf
;
14028 /* ?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 */
14029 /* ?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 */
14030 /* ?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 */
14031 /* ?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 */
14032 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_str_set
, 8)
14033 void __thiscall
basic_stringstream_wchar_str_set(basic_stringstream_wchar
*this, const basic_string_wchar
*str
)
14035 TRACE("(%p %p)\n", this, str
);
14036 basic_stringbuf_wchar_str_set(&this->strbuf
, str
);
14039 /* ?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 */
14040 /* ?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 */
14041 /* ?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 */
14042 /* ?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 */
14043 DEFINE_THISCALL_WRAPPER(basic_stringstream_wchar_str_get
, 8)
14044 basic_string_wchar
* __thiscall
basic_stringstream_wchar_str_get(const basic_stringstream_wchar
*this, basic_string_wchar
*ret
)
14046 TRACE("(%p %p)\n", this, ret
);
14047 return basic_stringbuf_wchar_str_get(&this->strbuf
, ret
);
14050 /* ?_Init@strstreambuf@std@@IAEXHPAD0H@Z */
14051 /* ?_Init@strstreambuf@std@@IEAAX_JPEAD1H@Z */
14052 #if STREAMSIZE_BITS == 64
14053 DEFINE_THISCALL_WRAPPER(strstreambuf__Init
, 24)
14055 DEFINE_THISCALL_WRAPPER(strstreambuf__Init
, 20)
14057 void __thiscall
strstreambuf__Init(strstreambuf
*this, streamsize len
, char *g
, char *p
, int mode
)
14059 TRACE("(%p %s %p %p %d)\n", this, wine_dbgstr_longlong(len
), g
, p
, mode
);
14061 this->minsize
= 32;
14062 this->endsave
= NULL
;
14063 this->strmode
= mode
;
14064 this->palloc
= NULL
;
14065 this->pfree
= NULL
;
14068 this->strmode
|= STRSTATE_Dynamic
;
14069 if(len
> this->minsize
)
14070 this->minsize
= len
;
14071 this->seekhigh
= NULL
;
14080 this->seekhigh
= g
+len
;
14081 basic_streambuf_char_setg(&this->base
, g
, g
, p
? p
: this->seekhigh
);
14083 basic_streambuf_char_setp(&this->base
, p
, this->seekhigh
);
14086 /* ??0strstreambuf@std@@QAE@PACH0@Z */
14087 /* ??0strstreambuf@std@@QEAA@PEAC_J0@Z */
14088 /* ??0strstreambuf@std@@QAE@PADH0@Z */
14089 /* ??0strstreambuf@std@@QEAA@PEAD_J0@Z */
14090 /* ??0strstreambuf@std@@QAE@PAEH0@Z */
14091 /* ??0strstreambuf@std@@QEAA@PEAE_J0@Z */
14092 #if STREAMSIZE_BITS == 64
14093 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get_put
, 20)
14095 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get_put
, 16)
14097 strstreambuf
* __thiscall
strstreambuf_ctor_get_put(strstreambuf
*this, char *g
, streamsize len
, char *p
)
14099 TRACE("(%p %p %s %p)\n", this, g
, wine_dbgstr_longlong(len
), p
);
14101 basic_streambuf_char_ctor(&this->base
);
14102 this->base
.vtable
= &MSVCP_strstreambuf_vtable
;
14104 strstreambuf__Init(this, len
, g
, p
, 0);
14108 /* ??0strstreambuf@std@@QAE@H@Z */
14109 /* ??0strstreambuf@std@@QEAA@_J@Z */
14110 #if STREAMSIZE_BITS == 64
14111 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_len
, 12)
14113 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_len
, 8)
14115 strstreambuf
* __thiscall
strstreambuf_ctor_len(strstreambuf
*this, streamsize len
)
14117 return strstreambuf_ctor_get_put(this, NULL
, len
, NULL
);
14120 /* ??0strstreambuf@std@@QAE@P6APAXI@ZP6AXPAX@Z@Z */
14121 /* ??0strstreambuf@std@@QEAA@P6APEAX_K@ZP6AXPEAX@Z@Z */
14122 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_alloc
, 12)
14123 strstreambuf
* __thiscall
strstreambuf_ctor_alloc(strstreambuf
*this,
14124 void* (__cdecl
*palloc
)(size_t), void (__cdecl
*pfree
)(void*))
14126 TRACE("(%p %p %p)\n", this, palloc
, pfree
);
14128 strstreambuf_ctor_get_put(this, NULL
, 0, NULL
);
14129 this->palloc
= palloc
;
14130 this->pfree
= pfree
;
14134 /* ??0strstreambuf@std@@QAE@PBCH@Z */
14135 /* ??0strstreambuf@std@@QEAA@PEBC_J@Z */
14136 /* ??0strstreambuf@std@@QAE@PBDH@Z */
14137 /* ??0strstreambuf@std@@QEAA@PEBD_J@Z */
14138 /* ??0strstreambuf@std@@QAE@PBEH@Z */
14139 /* ??0strstreambuf@std@@QEAA@PEBE_J@Z */
14140 #if STREAMSIZE_BITS == 64
14141 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get
, 16)
14143 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor_get
, 12)
14145 strstreambuf
* __thiscall
strstreambuf_ctor_get(strstreambuf
*this, const char *g
, streamsize len
)
14147 TRACE("(%p %p %s)\n", this, g
, wine_dbgstr_longlong(len
));
14149 strstreambuf_ctor_get_put(this, (char*)g
, len
, NULL
);
14150 this->strmode
|= STRSTATE_Constant
;
14154 /* ??_Fstrstreambuf@std@@QAEXXZ */
14155 /* ??_Fstrstreambuf@std@@QEAAXXZ */
14156 DEFINE_THISCALL_WRAPPER(strstreambuf_ctor
, 4)
14157 strstreambuf
* __thiscall
strstreambuf_ctor(strstreambuf
*this)
14159 return strstreambuf_ctor_get_put(this, NULL
, 0, NULL
);
14162 /* ?_Tidy@strstreambuf@std@@IAEXXZ */
14163 /* ?_Tidy@strstreambuf@std@@IEAAXXZ */
14164 DEFINE_THISCALL_WRAPPER(strstreambuf__Tidy
, 4)
14165 void __thiscall
strstreambuf__Tidy(strstreambuf
*this)
14167 TRACE("(%p)\n", this);
14169 if((this->strmode
& STRSTATE_Allocated
) && !(this->strmode
& STRSTATE_Frozen
)) {
14171 this->pfree(basic_streambuf_char_eback(&this->base
));
14173 MSVCRT_operator_delete(basic_streambuf_char_eback(&this->base
));
14176 this->endsave
= NULL
;
14177 this->seekhigh
= NULL
;
14178 this->strmode
&= ~(STRSTATE_Allocated
| STRSTATE_Frozen
);
14179 basic_streambuf_char_setg(&this->base
, NULL
, NULL
, NULL
);
14180 basic_streambuf_char_setp(&this->base
, NULL
, NULL
);
14183 /* ??1strstreambuf@std@@UAE@XZ */
14184 /* ??1strstreambuf@std@@UEAA@XZ */
14185 DEFINE_THISCALL_WRAPPER(strstreambuf_dtor
, 4)
14186 void __thiscall
strstreambuf_dtor(strstreambuf
*this)
14188 TRACE("(%p)\n", this);
14190 strstreambuf__Tidy(this);
14191 basic_streambuf_char_dtor(&this->base
);
14194 DEFINE_THISCALL_WRAPPER(strstreambuf_vector_dtor
, 8)
14195 strstreambuf
* __thiscall
strstreambuf_vector_dtor(strstreambuf
*this, unsigned int flags
)
14197 TRACE("(%p %x)\n", this, flags
);
14199 /* we have an array, with the number of elements stored before the first object */
14200 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
14202 for(i
=*ptr
-1; i
>=0; i
--)
14203 strstreambuf_dtor(this+i
);
14204 MSVCRT_operator_delete(ptr
);
14206 strstreambuf_dtor(this);
14208 MSVCRT_operator_delete(this);
14214 /* ?freeze@strstreambuf@std@@QAEX_N@Z */
14215 /* ?freeze@strstreambuf@std@@QEAAX_N@Z */
14216 DEFINE_THISCALL_WRAPPER(strstreambuf_freeze
, 8)
14217 void __thiscall
strstreambuf_freeze(strstreambuf
*this, bool freeze
)
14219 TRACE("(%p %d)\n", this, freeze
);
14221 if(!freeze
== !(this->strmode
& STRSTATE_Frozen
))
14225 this->strmode
|= STRSTATE_Frozen
;
14226 this->endsave
= basic_streambuf_char_epptr(&this->base
);
14227 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
),
14228 basic_streambuf_char_pptr(&this->base
), basic_streambuf_char_eback(&this->base
));
14230 this->strmode
&= ~STRSTATE_Frozen
;
14231 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
),
14232 basic_streambuf_char_pptr(&this->base
), this->endsave
);
14236 /* ?str@strstreambuf@std@@QAEPADXZ */
14237 /* ?str@strstreambuf@std@@QEAAPEADXZ */
14238 DEFINE_THISCALL_WRAPPER(strstreambuf_str
, 4)
14239 char* __thiscall
strstreambuf_str(strstreambuf
*this)
14241 TRACE("(%p)\n", this);
14243 strstreambuf_freeze(this, TRUE
);
14244 return basic_streambuf_char_gptr(&this->base
);
14247 /* ?pcount@strstreambuf@std@@QBEHXZ */
14248 /* ?pcount@strstreambuf@std@@QEBA_JXZ */
14249 DEFINE_THISCALL_WRAPPER(strstreambuf_pcount
, 4)
14250 streamsize __thiscall
strstreambuf_pcount(const strstreambuf
*this)
14252 char *ppos
= basic_streambuf_char_pptr(&this->base
);
14254 TRACE("(%p)\n", this);
14256 return ppos
? ppos
-basic_streambuf_char_pbase(&this->base
) : 0;
14259 /* ?overflow@strstreambuf@std@@MAEHH@Z */
14260 /* ?overflow@strstreambuf@std@@MEAAHH@Z */
14261 DEFINE_THISCALL_WRAPPER(strstreambuf_overflow
, 8)
14262 int __thiscall
strstreambuf_overflow(strstreambuf
*this, int c
)
14264 size_t old_size
, size
;
14267 TRACE("(%p %d)\n", this, c
);
14272 if(this->strmode
& STRSTATE_Frozen
)
14275 ptr
= basic_streambuf_char_pptr(&this->base
);
14276 if(ptr
&& ptr
<basic_streambuf_char_epptr(&this->base
))
14277 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = c
);
14279 if(!(this->strmode
& STRSTATE_Dynamic
) || (this->strmode
& STRSTATE_Constant
))
14282 ptr
= basic_streambuf_char_eback(&this->base
);
14283 old_size
= ptr
? basic_streambuf_char_epptr(&this->base
) - ptr
: 0;
14285 size
= old_size
+ old_size
/2;
14286 if(size
< this->minsize
)
14287 size
= this->minsize
;
14290 buf
= this->palloc(size
);
14292 buf
= MSVCRT_operator_new(size
);
14296 memcpy(buf
, ptr
, old_size
);
14297 if(this->strmode
& STRSTATE_Allocated
) {
14301 MSVCRT_operator_delete(ptr
);
14304 this->strmode
|= STRSTATE_Allocated
;
14306 this->seekhigh
= buf
;
14307 basic_streambuf_char_setp(&this->base
, buf
, buf
+size
);
14308 basic_streambuf_char_setg(&this->base
, buf
, buf
, buf
);
14310 this->seekhigh
= this->seekhigh
-ptr
+buf
;
14311 basic_streambuf_char_setp_next(&this->base
, basic_streambuf_char_pbase(&this->base
)-ptr
+buf
,
14312 basic_streambuf_char_pptr(&this->base
)-ptr
+buf
, buf
+size
);
14313 basic_streambuf_char_setg(&this->base
, buf
, basic_streambuf_char_gptr(&this->base
)-ptr
+buf
,
14314 basic_streambuf_char_pptr(&this->base
));
14317 return (unsigned char)(*basic_streambuf_char__Pninc(&this->base
) = c
);
14320 /* ?pbackfail@strstreambuf@std@@MAEHH@Z */
14321 /* ?pbackfail@strstreambuf@std@@MEAAHH@Z */
14322 DEFINE_THISCALL_WRAPPER(strstreambuf_pbackfail
, 8)
14323 int __thiscall
strstreambuf_pbackfail(strstreambuf
*this, int c
)
14325 char *ptr
= basic_streambuf_char_gptr(&this->base
);
14327 TRACE("(%p %d)\n", this, c
);
14329 if(ptr
<=basic_streambuf_char_eback(&this->base
)
14330 || ((this->strmode
& STRSTATE_Constant
) && c
!=ptr
[-1]))
14333 basic_streambuf_char_gbump(&this->base
, -1);
14336 if(this->strmode
& STRSTATE_Constant
)
14337 return (unsigned char)c
;
14339 return (unsigned char)(ptr
[0] = c
);
14342 /* ?seekoff@strstreambuf@std@@MAE?AV?$fpos@H@2@JW4seekdir@ios_base@2@H@Z */
14343 /* ?seekoff@strstreambuf@std@@MEAA?AV?$fpos@H@2@_JW4seekdir@ios_base@2@H@Z */
14344 /* ?seekoff@strstreambuf@std@@MAE?AV?$fpos@H@2@JHH@Z */
14345 /* ?seekoff@strstreambuf@std@@MEAA?AV?$fpos@H@2@_JHH@Z */
14346 #if STREAMOFF_BITS == 64
14347 DEFINE_THISCALL_WRAPPER(strstreambuf_seekoff
, 24)
14349 DEFINE_THISCALL_WRAPPER(strstreambuf_seekoff
, 20)
14351 fpos_mbstatet
* __thiscall
strstreambuf_seekoff(strstreambuf
*this, fpos_mbstatet
*ret
, streamoff off
, int way
, int mode
)
14353 char *eback
= basic_streambuf_char_eback(&this->base
);
14354 char *pptr
= basic_streambuf_char_pptr(&this->base
);
14355 char *gptr
= basic_streambuf_char_gptr(&this->base
);
14357 TRACE("(%p %p %s %d %d)\n", this, ret
, wine_dbgstr_longlong(off
), way
, mode
);
14360 memset(&ret
->state
, 0, sizeof(ret
->state
));
14362 if(pptr
> this->seekhigh
)
14363 this->seekhigh
= pptr
;
14365 if((mode
& OPENMODE_in
) && gptr
) {
14366 if(way
==SEEKDIR_cur
&& !(mode
& OPENMODE_out
))
14368 else if(way
== SEEKDIR_end
)
14369 off
+= this->seekhigh
-eback
;
14370 else if(way
!= SEEKDIR_beg
)
14373 if(off
<0 || off
>this->seekhigh
-eback
) {
14376 basic_streambuf_char_gbump(&this->base
, eback
-gptr
+off
);
14377 if((mode
& OPENMODE_out
) && pptr
) {
14378 basic_streambuf_char_setp_next(&this->base
, eback
,
14379 gptr
, basic_streambuf_char_epptr(&this->base
));
14382 }else if((mode
& OPENMODE_out
) && pptr
) {
14383 if(way
== SEEKDIR_cur
)
14385 else if(way
== SEEKDIR_end
)
14386 off
+= this->seekhigh
-eback
;
14387 else if(way
!= SEEKDIR_beg
)
14390 if(off
<0 || off
>this->seekhigh
-eback
)
14393 basic_streambuf_char_pbump(&this->base
, eback
-pptr
+off
);
14402 /* ?seekpos@strstreambuf@std@@MAE?AV?$fpos@H@2@V32@H@Z */
14403 /* ?seekpos@strstreambuf@std@@MEAA?AV?$fpos@H@2@V32@H@Z */
14404 DEFINE_THISCALL_WRAPPER(strstreambuf_seekpos
, 36)
14405 fpos_mbstatet
* __thiscall
strstreambuf_seekpos(strstreambuf
*this, fpos_mbstatet
*ret
, fpos_mbstatet pos
, int mode
)
14407 TRACE("(%p %p %s %d)\n", this, ret
, debugstr_fpos_mbstatet(&pos
), mode
);
14409 if(pos
.off
==-1 && pos
.pos
==0 && MBSTATET_TO_INT(&pos
.state
)==0) {
14414 return strstreambuf_seekoff(this, ret
, pos
.pos
+pos
.off
, SEEKDIR_beg
, mode
);
14417 /* ?underflow@strstreambuf@std@@MAEHXZ */
14418 /* ?underflow@strstreambuf@std@@MEAAHXZ */
14419 DEFINE_THISCALL_WRAPPER(strstreambuf_underflow
, 4)
14420 int __thiscall
strstreambuf_underflow(strstreambuf
*this)
14422 char *gptr
= basic_streambuf_char_gptr(&this->base
);
14425 TRACE("(%p)\n", this);
14430 if(gptr
< basic_streambuf_char_egptr(&this->base
))
14431 return (unsigned char)(*gptr
);
14433 pptr
= basic_streambuf_char_gptr(&this->base
);
14434 if(pptr
> this->seekhigh
)
14435 this->seekhigh
= pptr
;
14437 if(this->seekhigh
<= gptr
)
14440 basic_streambuf_char_setg(&this->base
, basic_streambuf_char_eback(&this->base
),
14441 gptr
, this->seekhigh
);
14442 return (unsigned char)(*gptr
);
14445 static inline basic_ios_char
* ostrstream_to_basic_ios(ostrstream
*ptr
)
14447 return (basic_ios_char
*)((char*)ptr
+ostrstream_vbtable
[1]);
14450 static inline ostrstream
* ostrstream_from_basic_ios(basic_ios_char
*ptr
)
14452 return (ostrstream
*)((char*)ptr
-ostrstream_vbtable
[1]);
14455 /* ??0ostrstream@std@@QAE@PADHH@Z */
14456 #if STREAMSIZE_BITS == 64
14457 DEFINE_THISCALL_WRAPPER(ostrstream_ctor
, 24)
14459 DEFINE_THISCALL_WRAPPER(ostrstream_ctor
, 20)
14461 ostrstream
* __thiscall
ostrstream_ctor(ostrstream
*this, char *buf
, streamsize size
, int mode
, bool virt_init
)
14463 basic_ios_char
*basic_ios
;
14465 TRACE("(%p %p %s %d %d)\n", this, buf
, wine_dbgstr_longlong(size
), mode
, virt_init
);
14468 this->base
.vbtable
= ostrstream_vbtable
;
14469 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
14470 INIT_BASIC_IOS_VTORDISP(basic_ios
);
14471 basic_ios_char_ctor(basic_ios
);
14473 basic_ios
= basic_ostream_char_get_basic_ios(&this->base
);
14476 strstreambuf_ctor_get_put(&this->buf
, buf
, size
,
14477 buf
&& (mode
& OPENMODE_app
) ? buf
+strlen(buf
) : buf
);
14478 basic_ostream_char_ctor(&this->base
, &this->buf
.base
, FALSE
, FALSE
);
14479 basic_ios
->base
.vtable
= &MSVCP_ostrstream_vtable
;
14483 /* ??1ostrstream@std@@UAE@XZ */
14484 /* ??1ostrstream@std@@UEAA@XZ */
14485 DEFINE_THISCALL_WRAPPER(ostrstream_dtor
, 4)
14486 void __thiscall
ostrstream_dtor(basic_ios_char
*base
)
14488 ostrstream
*this = ostrstream_from_basic_ios(base
);
14490 TRACE("(%p)\n", this);
14492 basic_ostream_char_dtor(basic_ostream_char_to_basic_ios(&this->base
));
14493 strstreambuf_dtor(&this->buf
);
14496 static void ostrstream_vbase_dtor(ostrstream
*this)
14498 basic_ios_char
*base
= ostrstream_to_basic_ios(this);
14500 TRACE("(%p)\n", this);
14502 ostrstream_dtor(base
);
14503 basic_ios_char_dtor(base
);
14506 DEFINE_THISCALL_WRAPPER(ostrstream_vector_dtor
, 8)
14507 ostrstream
* __thiscall
ostrstream_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
14509 ostrstream
*this = ostrstream_from_basic_ios(base
);
14511 TRACE("(%p %x)\n", this, flags
);
14514 /* we have an array, with the number of elements stored before the first object */
14515 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
14517 for(i
=*ptr
-1; i
>=0; i
--)
14518 ostrstream_vbase_dtor(this+i
);
14519 MSVCRT_operator_delete(ptr
);
14521 ostrstream_vbase_dtor(this);
14523 MSVCRT_operator_delete(this);
14529 static inline istrstream
* istrstream_from_basic_ios(basic_ios_char
*ptr
)
14531 return (istrstream
*)((char*)ptr
-istrstream_vbtable
[1]);
14534 /* ??1istrstream@std@@UAE@XZ */
14535 /* ??1istrstream@std@@UEAA@XZ */
14536 DEFINE_THISCALL_WRAPPER(istrstream_dtor
, 4)
14537 void __thiscall
istrstream_dtor(basic_ios_char
*base
)
14539 istrstream
*this = istrstream_from_basic_ios(base
);
14541 TRACE("(%p)\n", this);
14543 basic_istream_char_dtor(basic_istream_char_to_basic_ios(&this->base
));
14544 strstreambuf_dtor(&this->buf
);
14547 static inline basic_ios_char
* strstream_to_basic_ios(strstream
*ptr
)
14549 return (basic_ios_char
*)((char*)ptr
+strstream_vbtable1
[1]);
14552 static inline strstream
* strstream_from_basic_ios(basic_ios_char
*ptr
)
14554 return (strstream
*)((char*)ptr
-strstream_vbtable1
[1]);
14557 /* ??$?6MDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@M@0@@Z */
14558 /* ??$?6MDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@M@0@@Z */
14559 basic_ostream_char
* __cdecl
basic_ostream_char_print_complex_float(basic_ostream_char
*ostr
, const complex_float
*val
)
14562 basic_ostringstream_char obj
;
14563 basic_ios_char vbase
;
14565 ios_base
*ostringstream_ios_base
, *ostream_ios_base
;
14567 basic_string_char str
;
14568 basic_ostringstream_char_ctor(&oss
.obj
);
14569 ostringstream_ios_base
= &oss
.vbase
.base
;
14570 ostream_ios_base
= &basic_ostream_char_get_basic_ios(ostr
)->base
;
14571 TRACE("(%p %p)\n", ostr
, val
);
14573 ios_base_imbue(ostringstream_ios_base
, &loc
, IOS_LOCALE(ostream_ios_base
));
14575 ios_base_precision_set(ostringstream_ios_base
, ios_base_precision_get(ostream_ios_base
));
14576 ios_base_flags_set(ostringstream_ios_base
, ios_base_flags_get(ostream_ios_base
));
14578 basic_ostream_char_print_ch(&oss
.obj
.base
, '(');
14579 basic_ostream_char_print_float(&oss
.obj
.base
, val
->real
);
14580 basic_ostream_char_print_ch(&oss
.obj
.base
, ',');
14581 basic_ostream_char_print_float(&oss
.obj
.base
, val
->imag
);
14582 basic_ostream_char_print_ch(&oss
.obj
.base
, ')');
14584 basic_ostringstream_char_str_get(&oss
.obj
, &str
);
14585 basic_ostringstream_char_dtor(&oss
.vbase
);
14586 basic_ostream_char_print_bstr(ostr
, &str
);
14587 MSVCP_basic_string_char_dtor(&str
);
14591 /* ??$?6NDU?$char_traits@D@std@@@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABV?$complex@N@0@@Z */
14592 /* ??$?6NDU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@N@0@@Z */
14593 basic_ostream_char
* __cdecl
basic_ostream_char_print_complex_double(basic_ostream_char
*ostr
, const complex_double
*val
)
14596 basic_ostringstream_char obj
;
14597 basic_ios_char vbase
;
14599 ios_base
*ostringstream_ios_base
, *ostream_ios_base
;
14601 basic_string_char str
;
14602 basic_ostringstream_char_ctor(&oss
.obj
);
14603 ostringstream_ios_base
= &oss
.vbase
.base
;
14604 ostream_ios_base
= &basic_ostream_char_get_basic_ios(ostr
)->base
;
14605 TRACE("(%p %p)\n", ostr
, val
);
14607 ios_base_imbue(ostringstream_ios_base
, &loc
, IOS_LOCALE(ostream_ios_base
));
14609 ios_base_precision_set(ostringstream_ios_base
, ios_base_precision_get(ostream_ios_base
));
14610 ios_base_flags_set(ostringstream_ios_base
, ios_base_flags_get(ostream_ios_base
));
14612 basic_ostream_char_print_ch(&oss
.obj
.base
, '(');
14613 basic_ostream_char_print_double(&oss
.obj
.base
, val
->real
);
14614 basic_ostream_char_print_ch(&oss
.obj
.base
, ',');
14615 basic_ostream_char_print_double(&oss
.obj
.base
, val
->imag
);
14616 basic_ostream_char_print_ch(&oss
.obj
.base
, ')');
14618 basic_ostringstream_char_str_get(&oss
.obj
, &str
);
14619 basic_ostringstream_char_dtor(&oss
.vbase
);
14620 basic_ostream_char_print_bstr(ostr
, &str
);
14621 MSVCP_basic_string_char_dtor(&str
);
14625 /* ??$?6odu?$char_traits@d@std@@@std@@yaaav?$basic_ostream@du?$char_traits@d@std@@@0@aav10@abv?$complex@o@0@@Z */
14626 /* ??$?6ODU?$char_traits@D@std@@@std@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@0@AEAV10@AEBV?$complex@O@0@@Z */
14627 basic_ostream_char
* __cdecl
basic_ostream_char_print_complex_ldouble(basic_ostream_char
*ostr
, const complex_double
*val
)
14630 basic_ostringstream_char obj
;
14631 basic_ios_char vbase
;
14633 ios_base
*ostringstream_ios_base
, *ostream_ios_base
;
14635 basic_string_char str
;
14636 basic_ostringstream_char_ctor(&oss
.obj
);
14637 ostringstream_ios_base
= &oss
.vbase
.base
;
14638 ostream_ios_base
= &basic_ostream_char_get_basic_ios(ostr
)->base
;
14639 TRACE("(%p %p)\n", ostr
, val
);
14641 ios_base_imbue(ostringstream_ios_base
, &loc
, IOS_LOCALE(ostream_ios_base
));
14643 ios_base_precision_set(ostringstream_ios_base
, ios_base_precision_get(ostream_ios_base
));
14644 ios_base_flags_set(ostringstream_ios_base
, ios_base_flags_get(ostream_ios_base
));
14646 basic_ostream_char_print_ch(&oss
.obj
.base
, '(');
14647 basic_ostream_char_print_ldouble(&oss
.obj
.base
, val
->real
);
14648 basic_ostream_char_print_ch(&oss
.obj
.base
, ',');
14649 basic_ostream_char_print_ldouble(&oss
.obj
.base
, val
->imag
);
14650 basic_ostream_char_print_ch(&oss
.obj
.base
, ')');
14652 basic_ostringstream_char_str_get(&oss
.obj
, &str
);
14653 basic_ostringstream_char_dtor(&oss
.vbase
);
14654 basic_ostream_char_print_bstr(ostr
, &str
);
14655 MSVCP_basic_string_char_dtor(&str
);
14659 /* ?_File_size@sys@tr2@std@@YA_KPBD@Z */
14660 /* ?_File_size@sys@tr2@std@@YA_KPEBD@Z */
14661 ULONGLONG __cdecl
tr2_sys__File_size(char const* path
)
14663 WIN32_FILE_ATTRIBUTE_DATA fad
;
14665 TRACE("(%s)\n", debugstr_a(path
));
14666 if(!GetFileAttributesExA(path
, GetFileExInfoStandard
, &fad
))
14669 return ((ULONGLONG
)(fad
.nFileSizeHigh
) << 32) + fad
.nFileSizeLow
;
14672 static int equivalent_handles(HANDLE h1
, HANDLE h2
)
14675 BY_HANDLE_FILE_INFORMATION info1
, info2
;
14677 if(h1
== INVALID_HANDLE_VALUE
)
14678 return h2
== INVALID_HANDLE_VALUE
? -1 : 0;
14679 else if(h2
== INVALID_HANDLE_VALUE
)
14682 ret
= GetFileInformationByHandle(h1
, &info1
) && GetFileInformationByHandle(h2
, &info2
);
14685 return (info1
.dwVolumeSerialNumber
== info2
.dwVolumeSerialNumber
14686 && info1
.nFileIndexHigh
== info2
.nFileIndexHigh
14687 && info1
.nFileIndexLow
== info2
.nFileIndexLow
14691 /* ?_Equivalent@sys@tr2@std@@YAHPBD0@Z */
14692 /* ?_Equivalent@sys@tr2@std@@YAHPEBD0@Z */
14693 int __cdecl
tr2_sys__Equivalent(char const* path1
, char const* path2
)
14698 TRACE("(%s %s)\n", debugstr_a(path1
), debugstr_a(path2
));
14700 h1
= CreateFileA(path1
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14701 NULL
, OPEN_EXISTING
, 0, 0);
14702 h2
= CreateFileA(path2
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14703 NULL
, OPEN_EXISTING
, 0, 0);
14704 ret
= equivalent_handles(h1
, h2
);
14710 /* ?_Current_get@sys@tr2@std@@YAPADAAY0BAE@D@Z */
14711 /* ?_Current_get@sys@tr2@std@@YAPEADAEAY0BAE@D@Z */
14712 char* __cdecl
tr2_sys__Current_get(char *current_path
)
14714 TRACE("(%s)\n", debugstr_a(current_path
));
14716 if(!GetCurrentDirectoryA(MAX_PATH
, current_path
))
14718 return current_path
;
14721 /* ?_Current_set@sys@tr2@std@@YA_NPBD@Z */
14722 /* ?_Current_set@sys@tr2@std@@YA_NPEBD@Z */
14723 bool __cdecl
tr2_sys__Current_set(char const* path
)
14725 TRACE("(%s)\n", debugstr_a(path
));
14726 return SetCurrentDirectoryA(path
) != 0;
14729 /* ?_Make_dir@sys@tr2@std@@YAHPBD@Z */
14730 /* ?_Make_dir@sys@tr2@std@@YAHPEBD@Z */
14731 int __cdecl
tr2_sys__Make_dir(char const* path
)
14733 TRACE("(%s)\n", debugstr_a(path
));
14735 if(!CreateDirectoryA(path
, NULL
)) {
14736 if(GetLastError() == ERROR_ALREADY_EXISTS
)
14745 /* ?_Remove_dir@sys@tr2@std@@YA_NPBD@Z */
14746 /* ?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z */
14747 bool __cdecl
tr2_sys__Remove_dir(char const* path
)
14749 TRACE("(%s)\n", debugstr_a(path
));
14750 return RemoveDirectoryA(path
) != 0;
14753 /* ?_Copy_file@sys@tr2@std@@YAHPBD0_N@Z */
14754 /* ?_Copy_file@sys@tr2@std@@YAHPEBD0_N@Z */
14755 int __cdecl
tr2_sys__Copy_file(char const* source
, char const* dest
, bool fail_if_exists
)
14757 TRACE("(%s %s %x)\n", debugstr_a(source
), debugstr_a(dest
), fail_if_exists
);
14759 if(!source
|| !dest
)
14760 return ERROR_INVALID_PARAMETER
;
14762 if(CopyFileA(source
, dest
, fail_if_exists
))
14763 return ERROR_SUCCESS
;
14764 return GetLastError();
14767 /* ?_Rename@sys@tr2@std@@YAHPBD0@Z */
14768 /* ?_Rename@sys@tr2@std@@YAHPEBD0@Z */
14769 int __cdecl
tr2_sys__Rename(char const* old_path
, char const* new_path
)
14771 TRACE("(%s %s)\n", debugstr_a(old_path
), debugstr_a(new_path
));
14773 if(!old_path
|| !new_path
)
14774 return ERROR_INVALID_PARAMETER
;
14776 if(MoveFileExA(old_path
, new_path
, MOVEFILE_COPY_ALLOWED
))
14777 return ERROR_SUCCESS
;
14778 return GetLastError();
14781 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PBD@Z */
14782 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PEBD@Z */
14783 struct space_info
* __cdecl
tr2_sys__Statvfs(struct space_info
*ret
, const char* path
)
14785 ULARGE_INTEGER available
, total
, free
;
14787 TRACE("(%s)\n", debugstr_a(path
));
14789 if(!path
|| !GetDiskFreeSpaceExA(path
, &available
, &total
, &free
)) {
14790 ret
->capacity
= ret
->free
= ret
->available
= 0;
14792 ret
->capacity
= total
.QuadPart
;
14793 ret
->free
= free
.QuadPart
;
14794 ret
->available
= available
.QuadPart
;
14799 /* ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PBDAAH@Z */
14800 /* ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PEBDAEAH@Z */
14801 enum file_type __cdecl
tr2_sys__Stat(char const* path
, int* err_code
)
14804 TRACE("(%s %p)\n", debugstr_a(path
), err_code
);
14806 *err_code
= ERROR_INVALID_PARAMETER
;
14807 return status_unknown
;
14810 attr
=GetFileAttributesA(path
);
14811 if(attr
== INVALID_FILE_ATTRIBUTES
) {
14812 enum file_type ret
;
14813 switch(GetLastError()) {
14814 case ERROR_FILE_NOT_FOUND
:
14815 case ERROR_BAD_NETPATH
:
14816 case ERROR_INVALID_NAME
:
14817 case ERROR_BAD_PATHNAME
:
14818 case ERROR_PATH_NOT_FOUND
:
14819 ret
= file_not_found
;
14820 *err_code
= ERROR_SUCCESS
;
14823 ret
= status_unknown
;
14824 *err_code
= GetLastError();
14829 *err_code
= ERROR_SUCCESS
;
14830 return (attr
& FILE_ATTRIBUTE_DIRECTORY
)?directory_file
:regular_file
;
14833 /* ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PBDAAH@Z */
14834 /* ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PEBDAEAH@Z */
14835 enum file_type __cdecl
tr2_sys__Lstat(char const* path
, int* err_code
)
14837 return tr2_sys__Stat(path
, err_code
);
14840 static __int64
get_last_write_time(HANDLE h
)
14845 if(!GetFileTime(h
, 0, 0, &wt
))
14848 ret
= (((__int64
)wt
.dwHighDateTime
)<< 32) + wt
.dwLowDateTime
;
14849 ret
-= TICKS_1601_TO_1970
;
14853 /* ?_Last_write_time@sys@tr2@std@@YA_JPBD@Z */
14854 /* ?_Last_write_time@sys@tr2@std@@YA_JPEBD@Z */
14855 __int64 __cdecl
tr2_sys__Last_write_time(char const* path
)
14860 TRACE("(%s)\n", debugstr_a(path
));
14862 handle
= CreateFileA(path
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14863 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
14864 if(handle
== INVALID_HANDLE_VALUE
)
14867 ret
= get_last_write_time(handle
);
14868 CloseHandle(handle
);
14869 return ret
/ TICKSPERSEC
;
14872 /* _Last_write_time */
14873 __int64 __cdecl
_Last_write_time(const wchar_t *path
)
14878 TRACE("(%s)\n", debugstr_w(path
));
14880 handle
= CreateFileW(path
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14881 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
14882 if(handle
== INVALID_HANDLE_VALUE
)
14885 ret
= get_last_write_time(handle
);
14886 CloseHandle(handle
);
14890 /* ?_Last_write_time@sys@tr2@std@@YA_JPB_W@Z */
14891 /* ?_Last_write_time@sys@tr2@std@@YA_JPEB_W@Z */
14892 __int64 __cdecl
tr2_sys__Last_write_time_wchar(const wchar_t *path
)
14894 TRACE("(%s)\n", debugstr_w(path
));
14895 return _Last_write_time(path
) / TICKSPERSEC
;
14898 static int set_last_write_time(HANDLE h
, __int64 time
)
14902 time
+= TICKS_1601_TO_1970
;
14903 wt
.dwLowDateTime
= (DWORD
)time
;
14904 wt
.dwHighDateTime
= (DWORD
)(time
>> 32);
14905 return SetFileTime(h
, 0, 0, &wt
);
14908 /* ?_Last_write_time@sys@tr2@std@@YAXPBD_J@Z */
14909 /* ?_Last_write_time@sys@tr2@std@@YAXPEBD_J@Z */
14910 void __cdecl
tr2_sys__Last_write_time_set(char const* path
, __int64 newtime
)
14914 TRACE("(%s)\n", debugstr_a(path
));
14916 handle
= CreateFileA(path
, FILE_WRITE_ATTRIBUTES
,
14917 FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14918 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
14919 if(handle
== INVALID_HANDLE_VALUE
)
14922 /* This is the implementation based on the test of msvcp110.
14923 * According to the test of msvcp120,
14924 * msvcp120's implementation does nothing. Obviously, this is a bug of windows.
14926 set_last_write_time(handle
, newtime
* TICKSPERSEC
);
14927 CloseHandle(handle
);
14930 /* _Set_last_write_time */
14931 int __cdecl
_Set_last_write_time(const wchar_t *path
, __int64 time
)
14936 TRACE("(%s)\n", debugstr_w(path
));
14938 handle
= CreateFileW(path
, FILE_WRITE_ATTRIBUTES
,
14939 FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
14940 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
14941 if(handle
== INVALID_HANDLE_VALUE
)
14944 ret
= set_last_write_time(handle
, time
);
14945 CloseHandle(handle
);
14949 /* ?_Last_write_time@sys@tr2@std@@YAXPB_W_J@Z */
14950 /* ?_Last_write_time@sys@tr2@std@@YAXPEB_W_J@Z */
14951 void __cdecl
tr2_sys__Last_write_time_set_wchar(const wchar_t *path
, __int64 time
)
14953 TRACE("(%s)\n", debugstr_w(path
));
14954 _Set_last_write_time(path
, time
* TICKSPERSEC
);
14957 /* ??_Open_dir@sys@tr2@std@@YAPAXPA_WPB_WAAHAAW4file_type@123@@Z */
14958 /* ??_Open_dir@sys@tr2@std@@YAPEAXPEA_WPEB_WAEAHAEAW4file_type@123@@Z */
14959 void* __cdecl
tr2_sys__Open_dir_wchar(wchar_t* target
, wchar_t const* dest
, int* err_code
, enum file_type
* type
)
14962 WIN32_FIND_DATAW data
;
14963 wchar_t temppath
[MAX_PATH
];
14965 TRACE("(%p %s %p %p)\n", target
, debugstr_w(dest
), err_code
, type
);
14966 if(wcslen(dest
) > MAX_PATH
- 3) {
14967 *err_code
= ERROR_BAD_PATHNAME
;
14971 wcscpy(temppath
, dest
);
14972 wcscat(temppath
, L
"\\*");
14974 handle
= FindFirstFileW(temppath
, &data
);
14975 if(handle
== INVALID_HANDLE_VALUE
) {
14976 *err_code
= ERROR_BAD_PATHNAME
;
14980 while(!wcscmp(data
.cFileName
, L
".") || !wcscmp(data
.cFileName
, L
"..")) {
14981 if(!FindNextFileW(handle
, &data
)) {
14982 *err_code
= ERROR_SUCCESS
;
14983 *type
= status_unknown
;
14990 wcscpy(target
, data
.cFileName
);
14991 *err_code
= ERROR_SUCCESS
;
14992 if(data
.dwFileAttributes
& FILE_ATTRIBUTE_DIRECTORY
)
14993 *type
= directory_file
;
14995 *type
= regular_file
;
14999 /* ?_Open_dir@sys@tr2@std@@YAPAXAAY0BAE@DPBDAAHAAW4file_type@123@@Z */
15000 /* ?_Open_dir@sys@tr2@std@@YAPEAXAEAY0BAE@DPEBDAEAHAEAW4file_type@123@@Z */
15001 void* __cdecl
tr2_sys__Open_dir(char* target
, char const* dest
, int* err_code
, enum file_type
* type
)
15004 wchar_t target_w
[MAX_PATH
];
15005 wchar_t dest_w
[MAX_PATH
];
15007 TRACE("(%p %s %p %p)\n", target
, debugstr_a(dest
), err_code
, type
);
15009 if (dest
&& !MultiByteToWideChar(CP_ACP
, 0, dest
, -1, dest_w
, MAX_PATH
))
15011 WARN("Failed to convert input string.\n");
15012 *err_code
= ERROR_BAD_PATHNAME
;
15016 handle
= tr2_sys__Open_dir_wchar(target_w
, dest
? dest_w
: NULL
, err_code
, type
);
15018 WideCharToMultiByte(CP_ACP
, 0, target_w
, -1, target
, MAX_PATH
, NULL
, NULL
);
15023 /* ??_Read_dir@sys@tr2@std@@YAPA_WPA_WPAXAAW4file_type@123@@Z */
15024 /* ??_Read_dir@sys@tr2@std@@YAPEA_WPEA_WPEAXAEAW4file_type@123@@Z */
15025 wchar_t* __cdecl
tr2_sys__Read_dir_wchar(wchar_t* target
, void* handle
, enum file_type
* type
)
15027 WIN32_FIND_DATAW data
;
15029 TRACE("(%p %p %p)\n", target
, handle
, type
);
15032 if(!FindNextFileW(handle
, &data
)) {
15033 *type
= status_unknown
;
15037 } while(!wcscmp(data
.cFileName
, L
".") || !wcscmp(data
.cFileName
, L
".."));
15039 wcscpy(target
, data
.cFileName
);
15040 if(data
.dwFileAttributes
& FILE_ATTRIBUTE_DIRECTORY
)
15041 *type
= directory_file
;
15043 *type
= regular_file
;
15047 /* ?_Read_dir@sys@tr2@std@@YAPADAAY0BAE@DPAXAAW4file_type@123@@Z */
15048 /* ?_Read_dir@sys@tr2@std@@YAPEADAEAY0BAE@DPEAXAEAW4file_type@123@@Z */
15049 char* __cdecl
tr2_sys__Read_dir(char* target
, void* handle
, enum file_type
* type
)
15051 wchar_t target_w
[MAX_PATH
];
15053 tr2_sys__Read_dir_wchar(target_w
, handle
, type
);
15054 WideCharToMultiByte(CP_ACP
, 0, target_w
, -1, target
, MAX_PATH
, NULL
, NULL
);
15059 /* ?_Close_dir@sys@tr2@std@@YAXPAX@Z */
15060 /* ?_Close_dir@sys@tr2@std@@YAXPEAX@Z */
15061 void __cdecl
tr2_sys__Close_dir(void* handle
)
15063 TRACE("(%p)\n", handle
);
15068 /* ?_Link@sys@tr2@std@@YAHPBD0@Z */
15069 /* ?_Link@sys@tr2@std@@YAHPEBD0@Z */
15070 int __cdecl
tr2_sys__Link(char const* existing_path
, char const* new_path
)
15072 TRACE("(%s %s)\n", debugstr_a(existing_path
), debugstr_a(new_path
));
15073 if(!existing_path
|| !new_path
)
15074 return ERROR_INVALID_PARAMETER
;
15076 if(CreateHardLinkA(new_path
, existing_path
, NULL
))
15077 return ERROR_SUCCESS
;
15078 return GetLastError();
15081 /* ?_Link@sys@tr2@std@@YAHPB_W0@Z */
15082 /* ?_Link@sys@tr2@std@@YAHPEB_W0@Z */
15084 int __cdecl
tr2_sys__Link_wchar(WCHAR
const* existing_path
, WCHAR
const* new_path
)
15086 TRACE("(%s %s)\n", debugstr_w(existing_path
), debugstr_w(new_path
));
15087 if(!existing_path
|| !new_path
)
15088 return ERROR_INVALID_PARAMETER
;
15090 if(CreateHardLinkW(new_path
, existing_path
, NULL
))
15091 return ERROR_SUCCESS
;
15092 return GetLastError();
15095 /* ?_Symlink@sys@tr2@std@@YAHPBD0@Z */
15096 /* ?_Symlink@sys@tr2@std@@YAHPEBD0@Z */
15097 int __cdecl
tr2_sys__Symlink(char const* existing_file_name
, char const* file_name
)
15099 TRACE("(%s %s)\n", debugstr_a(existing_file_name
), debugstr_a(file_name
));
15100 if(!existing_file_name
|| !file_name
)
15101 return ERROR_INVALID_PARAMETER
;
15103 if(CreateSymbolicLinkA(file_name
, existing_file_name
, 0))
15104 return ERROR_SUCCESS
;
15105 return GetLastError();
15108 /* ?_Symlink@sys@tr2@std@@YAHPB_W0@Z */
15109 /* ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z */
15111 int __cdecl
tr2_sys__Symlink_wchar(WCHAR
const* existing_file_name
, WCHAR
const* file_name
)
15113 TRACE("(%s %s)\n", debugstr_w(existing_file_name
), debugstr_w(file_name
));
15114 if(!existing_file_name
|| !file_name
)
15115 return ERROR_INVALID_PARAMETER
;
15117 if(CreateSymbolicLinkW(file_name
, existing_file_name
, 0))
15118 return ERROR_SUCCESS
;
15119 return GetLastError();
15122 /* ?_Unlink@sys@tr2@std@@YAHPBD@Z */
15123 /* ?_Unlink@sys@tr2@std@@YAHPEBD@Z */
15124 int __cdecl
tr2_sys__Unlink(char const* path
)
15126 TRACE("(%s)\n", debugstr_a(path
));
15128 if(DeleteFileA(path
))
15129 return ERROR_SUCCESS
;
15130 return GetLastError();
15133 /* ?_Unlink@sys@tr2@std@@YAHPB_W@Z */
15134 /* ?_Unlink@sys@tr2@std@@YAHPEB_W@Z */
15136 int __cdecl
tr2_sys__Unlink_wchar(WCHAR
const* path
)
15138 TRACE("(%s)\n", debugstr_w(path
));
15140 if(DeleteFileW(path
))
15141 return ERROR_SUCCESS
;
15142 return GetLastError();
15145 /* ??0strstream@std@@QAE@PADHH@Z */
15146 /* ??0strstream@std@@QEAA@PEAD_JH@Z */
15147 #if STREAMSIZE_BITS == 64
15148 DEFINE_THISCALL_WRAPPER(strstream_ctor
, 24)
15150 DEFINE_THISCALL_WRAPPER(strstream_ctor
, 20)
15152 strstream
* __thiscall
strstream_ctor(strstream
*this, char *buf
, streamsize size
, int mode
, bool virt_init
)
15154 basic_ios_char
*basic_ios
;
15156 TRACE("(%p %p %s %d %d)\n", this, buf
, wine_dbgstr_longlong(size
), mode
, virt_init
);
15159 this->base
.base1
.vbtable
= strstream_vbtable1
;
15160 this->base
.base2
.vbtable
= strstream_vbtable2
;
15161 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
15162 INIT_BASIC_IOS_VTORDISP(basic_ios
);
15163 basic_ios_char_ctor(basic_ios
);
15165 basic_ios
= basic_istream_char_get_basic_ios(&this->base
.base1
);
15168 strstreambuf_ctor_get_put(&this->buf
, buf
, size
,
15169 buf
&& (mode
& OPENMODE_app
) ? buf
+strlen(buf
) : buf
);
15170 basic_iostream_char_ctor(&this->base
, &this->buf
.base
, FALSE
);
15171 basic_ios
->base
.vtable
= &MSVCP_strstream_vtable
;
15175 /* ??1strstream@std@@UAE@XZ */
15176 /* ??1strstream@std@@UEAA@XZ */
15177 DEFINE_THISCALL_WRAPPER(strstream_dtor
, 4)
15178 void __thiscall
strstream_dtor(basic_ios_char
*base
)
15180 strstream
*this = strstream_from_basic_ios(base
);
15182 TRACE("(%p)\n", this);
15184 basic_iostream_char_dtor(basic_iostream_char_to_basic_ios(&this->base
));
15185 strstreambuf_dtor(&this->buf
);
15188 static void strstream_vbase_dtor(strstream
*this)
15190 basic_ios_char
*base
= strstream_to_basic_ios(this);
15192 TRACE("(%p)\n", this);
15194 strstream_dtor(base
);
15195 basic_ios_char_dtor(base
);
15198 DEFINE_THISCALL_WRAPPER(strstream_vector_dtor
, 8)
15199 strstream
* __thiscall
strstream_vector_dtor(basic_ios_char
*base
, unsigned int flags
)
15201 strstream
*this = strstream_from_basic_ios(base
);
15203 TRACE("(%p %x)\n", this, flags
);
15206 /* we have an array, with the number of elements stored before the first object */
15207 INT_PTR i
, *ptr
= (INT_PTR
*)this-1;
15209 for(i
=*ptr
-1; i
>=0; i
--)
15210 strstream_vbase_dtor(this+i
);
15211 MSVCRT_operator_delete(ptr
);
15213 strstream_vbase_dtor(this);
15215 MSVCRT_operator_delete(this);
15221 static void __cdecl
setprecision_func(ios_base
*base
, streamsize prec
)
15223 ios_base_precision_set(base
, prec
);
15226 /* ?setprecision@std@@YA?AU?$_Smanip@H@1@H@Z */
15227 /* ?setprecision@std@@YA?AU?$_Smanip@_J@1@_J@Z */
15228 manip_streamsize
* __cdecl
setprecision(manip_streamsize
*ret
, streamsize prec
)
15230 TRACE("(%p %s)\n", ret
, wine_dbgstr_longlong(prec
));
15232 ret
->pfunc
= setprecision_func
;
15237 static void __cdecl
setw_func(ios_base
*base
, streamsize width
)
15239 ios_base_width_set(base
, width
);
15242 /* ?setw@std@@YA?AU?$_Smanip@H@1@H@Z */
15243 /* ?setw@std@@YA?AU?$_Smanip@_J@1@_J@Z */
15244 manip_streamsize
* __cdecl
setw(manip_streamsize
*ret
, streamsize width
)
15246 TRACE("(%p %s)\n", ret
, wine_dbgstr_longlong(width
));
15248 ret
->pfunc
= setw_func
;
15253 static void __cdecl
resetioflags_func(ios_base
*base
, int mask
)
15255 ios_base_setf_mask(base
, 0, mask
);
15258 /* ?resetiosflags@std@@YA?AU?$_Smanip@H@1@H@Z */
15259 manip_int
* __cdecl
resetiosflags(manip_int
*ret
, int mask
)
15261 TRACE("(%p %d)\n", ret
, mask
);
15263 ret
->pfunc
= resetioflags_func
;
15268 static void __cdecl
setiosflags_func(ios_base
*base
, int mask
)
15270 ios_base_setf_mask(base
, FMTFLAG_mask
, mask
);
15273 /* ?setiosflags@std@@YA?AU?$_Smanip@H@1@H@Z */
15274 manip_int
* __cdecl
setiosflags(manip_int
*ret
, int mask
)
15276 TRACE("(%p %d)\n", ret
, mask
);
15278 ret
->pfunc
= setiosflags_func
;
15283 static void __cdecl
setbase_func(ios_base
*base
, int set_base
)
15286 set_base
= FMTFLAG_dec
;
15287 else if(set_base
== 8)
15288 set_base
= FMTFLAG_oct
;
15289 else if(set_base
== 16)
15290 set_base
= FMTFLAG_hex
;
15294 ios_base_setf_mask(base
, set_base
, FMTFLAG_basefield
);
15297 /* ?setbase@std@@YA?AU?$_Smanip@H@1@H@Z */
15298 manip_int
* __cdecl
setbase(manip_int
*ret
, int base
)
15300 TRACE("(%p %d)\n", ret
, base
);
15302 ret
->pfunc
= setbase_func
;
15307 static basic_filebuf_char filebuf_char_stdin
;
15308 /* ?cin@std@@3V?$basic_istream@DU?$char_traits@D@std@@@1@A */
15310 basic_istream_char obj
;
15311 #if _MSVCP_VER >= 110
15314 basic_ios_char vbase
;
15316 C_ASSERT(sizeof(cin
) == VBTABLE_BASIC_IOS_ENTRY(basic_istream_char
, 0)+sizeof(basic_ios_char
));
15317 /* ?_Ptr_cin@std@@3PAV?$basic_istream@DU?$char_traits@D@std@@@1@A */
15318 /* ?_Ptr_cin@std@@3PEAV?$basic_istream@DU?$char_traits@D@std@@@1@EA */
15319 basic_istream_char
*_Ptr_cin
= &cin
.obj
;
15321 static basic_filebuf_wchar filebuf_short_stdin
;
15322 /* ?wcin@std@@3V?$basic_istream@GU?$char_traits@G@std@@@1@A */
15324 basic_istream_wchar obj
;
15325 #if _MSVCP_VER >= 110
15328 basic_ios_wchar vbase
;
15329 } ucin
= { { 0 } };
15330 C_ASSERT(sizeof(ucin
) == VBTABLE_BASIC_IOS_ENTRY(basic_istream_wchar
, 0)+sizeof(basic_ios_wchar
));
15331 /* ?_Ptr_wcin@std@@3PAV?$basic_istream@GU?$char_traits@G@std@@@1@A */
15332 /* ?_Ptr_wcin@std@@3PEAV?$basic_istream@GU?$char_traits@G@std@@@1@EA */
15333 basic_istream_wchar
*_Ptr_ucin
= &ucin
.obj
;
15335 static basic_filebuf_wchar filebuf_wchar_stdin
;
15336 /* ?wcin@std@@3V?$basic_istream@_WU?$char_traits@_W@std@@@1@A */
15338 basic_istream_wchar obj
;
15339 #if _MSVCP_VER >= 110
15342 basic_ios_wchar vbase
;
15343 } wcin
= { { 0 } };
15344 C_ASSERT(sizeof(wcin
) == VBTABLE_BASIC_IOS_ENTRY(basic_istream_wchar
, 0)+sizeof(basic_ios_wchar
));
15345 /* ?_Ptr_wcin@std@@3PAV?$basic_istream@_WU?$char_traits@_W@std@@@1@A */
15346 /* ?_Ptr_wcin@std@@3PEAV?$basic_istream@_WU?$char_traits@_W@std@@@1@EA */
15347 basic_istream_wchar
*_Ptr_wcin
= &wcin
.obj
;
15349 static basic_filebuf_char filebuf_char_stdout
;
15350 /* ?cout@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
15352 basic_ostream_char obj
;
15353 #if _MSVCP_VER >= 110
15356 basic_ios_char vbase
;
15357 } cout
= { { 0 } };
15358 C_ASSERT(sizeof(cout
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_char
, 0)+sizeof(basic_ios_char
));
15359 /* ?_Ptr_cout@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
15360 /* ?_Ptr_cout@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
15361 basic_ostream_char
*_Ptr_cout
= &cout
.obj
;
15363 static basic_filebuf_wchar filebuf_short_stdout
;
15364 /* ?wcout@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
15366 basic_ostream_wchar obj
;
15367 #if _MSVCP_VER >= 110
15370 basic_ios_wchar vbase
;
15371 } ucout
= { { 0 } };
15372 C_ASSERT(sizeof(ucout
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)+sizeof(basic_ios_wchar
));
15373 /* ?_Ptr_wcout@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
15374 /* ?_Ptr_wcout@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
15375 basic_ostream_wchar
*_Ptr_ucout
= &ucout
.obj
;
15377 static basic_filebuf_wchar filebuf_wchar_stdout
;
15378 /* ?wcout@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
15380 basic_ostream_wchar obj
;
15381 #if _MSVCP_VER >= 110
15384 basic_ios_wchar vbase
;
15385 } wcout
= { { 0 } };
15386 C_ASSERT(sizeof(wcout
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)+sizeof(basic_ios_wchar
));
15387 /* ?_Ptr_wcout@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
15388 /* ?_Ptr_wcout@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
15389 basic_ostream_wchar
*_Ptr_wcout
= &wcout
.obj
;
15391 static basic_filebuf_char filebuf_char_stderr
;
15392 /* ?cerr@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
15394 basic_ostream_char obj
;
15395 #if _MSVCP_VER >= 110
15398 basic_ios_char vbase
;
15399 } cerr
= { { 0 } };
15400 C_ASSERT(sizeof(cerr
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_char
, 0)+sizeof(basic_ios_char
));
15401 /* ?_Ptr_cerr@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
15402 /* ?_Ptr_cerr@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
15403 basic_ostream_char
*_Ptr_cerr
= &cerr
.obj
;
15405 static basic_filebuf_wchar filebuf_short_stderr
;
15406 /* ?wcerr@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
15408 basic_ostream_wchar obj
;
15409 #if _MSVCP_VER >= 110
15412 basic_ios_wchar vbase
;
15413 } ucerr
= { { 0 } };
15414 C_ASSERT(sizeof(ucerr
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)+sizeof(basic_ios_wchar
));
15415 /* ?_Ptr_wcerr@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
15416 /* ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
15417 basic_ostream_wchar
*_Ptr_ucerr
= &ucerr
.obj
;
15419 static basic_filebuf_wchar filebuf_wchar_stderr
;
15420 /* ?wcerr@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
15422 basic_ostream_wchar obj
;
15423 #if _MSVCP_VER >= 110
15426 basic_ios_wchar vbase
;
15427 } wcerr
= { { 0 } };
15428 C_ASSERT(sizeof(wcerr
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)+sizeof(basic_ios_wchar
));
15429 /* ?_Ptr_wcerr@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
15430 /* ?_Ptr_wcerr@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
15431 basic_ostream_wchar
*_Ptr_wcerr
= &wcerr
.obj
;
15433 static basic_filebuf_char filebuf_char_log
;
15434 /* ?clog@std@@3V?$basic_ostream@DU?$char_traits@D@std@@@1@A */
15436 basic_ostream_char obj
;
15437 #if _MSVCP_VER >= 110
15440 basic_ios_char vbase
;
15441 } MSVCP_clog
= { { 0 } };
15442 C_ASSERT(sizeof(MSVCP_clog
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_char
, 0)+sizeof(basic_ios_char
));
15443 /* ?_Ptr_clog@std@@3PAV?$basic_ostream@DU?$char_traits@D@std@@@1@A */
15444 /* ?_Ptr_clog@std@@3PEAV?$basic_ostream@DU?$char_traits@D@std@@@1@EA */
15445 basic_ostream_char
*_Ptr_clog
= &MSVCP_clog
.obj
;
15447 static basic_filebuf_wchar filebuf_short_log
;
15448 /* ?wclog@std@@3V?$basic_ostream@GU?$char_traits@G@std@@@1@A */
15450 basic_ostream_wchar obj
;
15451 #if _MSVCP_VER >= 110
15454 basic_ios_wchar vbase
;
15455 } uclog
= { { 0 } };
15456 C_ASSERT(sizeof(uclog
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)+sizeof(basic_ios_wchar
));
15457 /* ?_Ptr_wclog@std@@3PAV?$basic_ostream@GU?$char_traits@G@std@@@1@A */
15458 /* ?_Ptr_wclog@std@@3PEAV?$basic_ostream@GU?$char_traits@G@std@@@1@EA */
15459 basic_ostream_wchar
*_Ptr_uclog
= &uclog
.obj
;
15461 static basic_filebuf_wchar filebuf_wchar_log
;
15462 /* ?wclog@std@@3V?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
15464 basic_ostream_wchar obj
;
15465 #if _MSVCP_VER >= 110
15468 basic_ios_wchar vbase
;
15469 } wclog
= { { 0 } };
15470 C_ASSERT(sizeof(wclog
) == VBTABLE_BASIC_IOS_ENTRY(basic_ostream_wchar
, 0)+sizeof(basic_ios_wchar
));
15471 /* ?_Ptr_wclog@std@@3PAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@A */
15472 /* ?_Ptr_wclog@std@@3PEAV?$basic_ostream@_WU?$char_traits@_W@std@@@1@EA */
15473 basic_ostream_wchar
*_Ptr_wclog
= &wclog
.obj
;
15475 /* ?_Init_cnt@Init@ios_base@std@@0HA */
15476 int ios_base_Init__Init_cnt
= -1;
15478 /* ?_Init_cnt_func@Init@ios_base@std@@CAAAHXZ */
15479 /* ?_Init_cnt_func@Init@ios_base@std@@CAAEAHXZ */
15480 int* __cdecl
ios_base_Init__Init_cnt_func(void)
15482 return &ios_base_Init__Init_cnt
;
15485 /* ?_Init_ctor@Init@ios_base@std@@CAXPAV123@@Z */
15486 /* ?_Init_ctor@Init@ios_base@std@@CAXPEAV123@@Z */
15487 void __cdecl
ios_base_Init__Init_ctor(void *this)
15489 TRACE("(%p)\n", this);
15491 if(ios_base_Init__Init_cnt
< 0)
15492 ios_base_Init__Init_cnt
= 1;
15494 ios_base_Init__Init_cnt
++;
15497 /* ??0Init@ios_base@std@@QAE@XZ */
15498 /* ??0Init@ios_base@std@@QEAA@XZ */
15499 DEFINE_THISCALL_WRAPPER(ios_base_Init_ctor
, 4)
15500 void* __thiscall
ios_base_Init_ctor(void *this)
15502 ios_base_Init__Init_ctor(this);
15506 /* ?_Init_dtor@Init@ios_base@std@@CAXPAV123@@Z */
15507 /* ?_Init_dtor@Init@ios_base@std@@CAXPEAV123@@Z */
15508 void __cdecl
ios_base_Init__Init_dtor(void *this)
15510 TRACE("(%p)\n", this);
15512 ios_base_Init__Init_cnt
--;
15513 if(!ios_base_Init__Init_cnt
) {
15514 basic_ostream_char_flush(&cout
.obj
);
15515 basic_ostream_char_flush(&cerr
.obj
);
15516 basic_ostream_char_flush(&MSVCP_clog
.obj
);
15520 /* ??1Init@ios_base@std@@QAE@XZ */
15521 /* ??1Init@ios_base@std@@QEAA@XZ */
15522 DEFINE_THISCALL_WRAPPER(ios_base_Init_dtor
, 4)
15523 void __thiscall
ios_base_Init_dtor(void *this)
15525 ios_base_Init__Init_dtor(this);
15528 /* ??4Init@ios_base@std@@QAEAAV012@ABV012@@Z */
15529 /* ??4Init@ios_base@std@@QEAAAEAV012@AEBV012@@Z */
15530 DEFINE_THISCALL_WRAPPER(ios_base_Init_op_assign
, 8)
15531 void* __thiscall
ios_base_Init_op_assign(void *this, void *rhs
)
15533 TRACE("(%p %p)\n", this, rhs
);
15537 /* ?_Init_cnt@_Winit@std@@0HA */
15538 int _Winit__Init_cnt
= -1;
15540 /* ??0_Winit@std@@QAE@XZ */
15541 /* ??0_Winit@std@@QEAA@XZ */
15542 DEFINE_THISCALL_WRAPPER(_Winit_ctor
, 4)
15543 void* __thiscall
_Winit_ctor(void *this)
15545 TRACE("(%p)\n", this);
15547 if(_Winit__Init_cnt
< 0)
15548 _Winit__Init_cnt
= 1;
15550 _Winit__Init_cnt
++;
15555 /* ?_File_size@sys@tr2@std@@YA_KPB_W@Z */
15556 /* ?_File_size@sys@tr2@std@@YA_KPEB_W@Z */
15557 ULONGLONG __cdecl
tr2_sys__File_size_wchar(WCHAR
const* path
)
15559 WIN32_FILE_ATTRIBUTE_DATA fad
;
15561 TRACE("(%s)\n", debugstr_w(path
));
15562 if(!GetFileAttributesExW(path
, GetFileExInfoStandard
, &fad
))
15565 return ((ULONGLONG
)(fad
.nFileSizeHigh
) << 32) + fad
.nFileSizeLow
;
15568 /* _File_size, msvcp140 version. Different error handling. */
15569 ULONGLONG __cdecl
_File_size(WCHAR
const* path
)
15571 WIN32_FILE_ATTRIBUTE_DATA fad
;
15573 TRACE("(%s)\n", debugstr_w(path
));
15574 if(!GetFileAttributesExW(path
, GetFileExInfoStandard
, &fad
))
15575 return ~(ULONGLONG
)0;
15577 return ((ULONGLONG
)(fad
.nFileSizeHigh
) << 32) + fad
.nFileSizeLow
;
15580 int __cdecl
_Resize(const WCHAR
*path
, UINT64 size
)
15582 LARGE_INTEGER offset
;
15586 TRACE("(%s %s)\n", debugstr_w(path
), wine_dbgstr_longlong(size
));
15588 file
= CreateFileW(path
, FILE_GENERIC_WRITE
, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
15589 NULL
, OPEN_EXISTING
, 0, 0);
15590 if(file
== INVALID_HANDLE_VALUE
)
15591 return GetLastError();
15593 offset
.QuadPart
= size
;
15594 if((ret
= SetFilePointerEx(file
, offset
, NULL
, FILE_BEGIN
)))
15595 ret
= SetEndOfFile(file
);
15597 return ret
? 0 : GetLastError();
15600 /* ?_Equivalent@sys@tr2@std@@YAHPB_W0@Z */
15601 /* ?_Equivalent@sys@tr2@std@@YAHPEB_W0@Z */
15602 int __cdecl
tr2_sys__Equivalent_wchar(WCHAR
const* path1
, WCHAR
const* path2
)
15607 TRACE("(%s %s)\n", debugstr_w(path1
), debugstr_w(path2
));
15609 h1
= CreateFileW(path1
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
15610 NULL
, OPEN_EXISTING
, 0, 0);
15611 h2
= CreateFileW(path2
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
15612 NULL
, OPEN_EXISTING
, 0, 0);
15613 ret
= equivalent_handles(h1
, h2
);
15619 /* _Equivalent, msvcp140 version */
15620 int __cdecl
_Equivalent(WCHAR
const* path1
, WCHAR
const* path2
)
15625 TRACE("(%s %s)\n", debugstr_w(path1
), debugstr_w(path2
));
15627 h1
= CreateFileW(path1
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
15628 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
15629 h2
= CreateFileW(path2
, 0, FILE_SHARE_DELETE
| FILE_SHARE_READ
| FILE_SHARE_WRITE
,
15630 NULL
, OPEN_EXISTING
, FILE_FLAG_BACKUP_SEMANTICS
, 0);
15631 ret
= equivalent_handles(h1
, h2
);
15637 /* ?_Current_get@sys@tr2@std@@YAPA_WAAY0BAE@_W@Z */
15638 /* ?_Current_get@sys@tr2@std@@YAPEA_WAEAY0BAE@_W@Z */
15639 WCHAR
* __cdecl
tr2_sys__Current_get_wchar(WCHAR
*current_path
)
15641 TRACE("(%s)\n", debugstr_w(current_path
));
15643 if(!GetCurrentDirectoryW(MAX_PATH
, current_path
))
15645 return current_path
;
15648 /* _Current_get, msvcp140 version */
15649 BOOL __cdecl
_Current_get(WCHAR
*current_path
)
15651 TRACE("(%s)\n", debugstr_w(current_path
));
15653 if(!GetCurrentDirectoryW(MAX_PATH
, current_path
))
15658 /* ?_Current_set@sys@tr2@std@@YA_NPB_W@Z */
15659 /* ?_Current_set@sys@tr2@std@@YA_NPEB_W@Z */
15660 bool __cdecl
tr2_sys__Current_set_wchar(WCHAR
const* path
)
15662 TRACE("(%s)\n", debugstr_w(path
));
15663 return SetCurrentDirectoryW(path
) != 0;
15666 /* ?_Make_dir@sys@tr2@std@@YAHPB_W@Z */
15667 /* ?_Make_dir@sys@tr2@std@@YAHPEB_W@Z */
15668 int __cdecl
tr2_sys__Make_dir_wchar(WCHAR
const* path
)
15670 TRACE("(%s)\n", debugstr_w(path
));
15672 if(!CreateDirectoryW(path
, NULL
)) {
15673 if(GetLastError() == ERROR_ALREADY_EXISTS
)
15682 /* ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z */
15683 /* ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z */
15684 bool __cdecl
tr2_sys__Remove_dir_wchar(WCHAR
const* path
)
15686 TRACE("(%s)\n", debugstr_w(path
));
15687 return RemoveDirectoryW(path
) != 0;
15690 /* ?_Copy_file@sys@tr2@std@@YAHPB_W0_N@Z */
15691 /* ?_Copy_file@sys@tr2@std@@YAHPEB_W0_N@Z */
15692 int __cdecl
tr2_sys__Copy_file_wchar(WCHAR
const* source
, WCHAR
const* dest
, bool fail_if_exists
)
15694 TRACE("(%s %s %x)\n", debugstr_w(source
), debugstr_w(dest
), fail_if_exists
);
15696 if(CopyFileW(source
, dest
, fail_if_exists
))
15697 return ERROR_SUCCESS
;
15698 return GetLastError();
15701 /* ?_Rename@sys@tr2@std@@YAHPB_W0@Z */
15702 /* ?_Rename@sys@tr2@std@@YAHPEB_W0@Z */
15703 int __cdecl
tr2_sys__Rename_wchar(WCHAR
const* old_path
, WCHAR
const* new_path
)
15705 TRACE("(%s %s)\n", debugstr_w(old_path
), debugstr_w(new_path
));
15707 if(MoveFileExW(old_path
, new_path
, MOVEFILE_COPY_ALLOWED
))
15708 return ERROR_SUCCESS
;
15709 return GetLastError();
15712 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PB_W@Z */
15713 /* ?_Statvfs@sys@tr2@std@@YA?AUspace_info@123@PEB_W@Z */
15714 struct space_info
* __cdecl
tr2_sys__Statvfs_wchar(struct space_info
*ret
, const WCHAR
* path
)
15716 ULARGE_INTEGER available
, total
, free
;
15718 TRACE("(%s)\n", debugstr_w(path
));
15720 if(!path
|| !GetDiskFreeSpaceExW(path
, &available
, &total
, &free
)) {
15721 ret
->capacity
= ret
->free
= ret
->available
= 0;
15723 ret
->capacity
= total
.QuadPart
;
15724 ret
->free
= free
.QuadPart
;
15725 ret
->available
= available
.QuadPart
;
15730 /* ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PB_WAAH@Z */
15731 /* ?_Stat@sys@tr2@std@@YA?AW4file_type@123@PEB_WAEAH@Z */
15732 enum file_type __cdecl
tr2_sys__Stat_wchar(WCHAR
const* path
, int* err_code
)
15735 TRACE("(%s %p)\n", debugstr_w(path
), err_code
);
15737 *err_code
= ERROR_INVALID_PARAMETER
;
15738 return status_unknown
;
15741 attr
=GetFileAttributesW(path
);
15742 if(attr
== INVALID_FILE_ATTRIBUTES
) {
15743 enum file_type ret
;
15744 switch(GetLastError()) {
15745 case ERROR_FILE_NOT_FOUND
:
15746 case ERROR_BAD_NETPATH
:
15747 case ERROR_INVALID_NAME
:
15748 case ERROR_BAD_PATHNAME
:
15749 case ERROR_PATH_NOT_FOUND
:
15750 ret
= file_not_found
;
15751 *err_code
= ERROR_SUCCESS
;
15754 ret
= status_unknown
;
15755 *err_code
= GetLastError();
15760 *err_code
= ERROR_SUCCESS
;
15761 return (attr
& FILE_ATTRIBUTE_DIRECTORY
)?directory_file
:regular_file
;
15764 /* _Stat, msvcp140 version */
15765 enum file_type __cdecl
_Stat(WCHAR
const* path
, int* permissions
)
15768 TRACE("(%s %p)\n", debugstr_w(path
), permissions
);
15770 return file_not_found
;
15773 attr
=GetFileAttributesW(path
);
15774 if(attr
== INVALID_FILE_ATTRIBUTES
) {
15775 enum file_type ret
;
15776 switch(GetLastError()) {
15777 case ERROR_FILE_NOT_FOUND
:
15778 case ERROR_BAD_NETPATH
:
15779 case ERROR_INVALID_NAME
:
15780 case ERROR_BAD_PATHNAME
:
15781 case ERROR_PATH_NOT_FOUND
:
15782 ret
= file_not_found
;
15785 ret
= status_unknown
;
15791 *permissions
= (attr
& FILE_ATTRIBUTE_READONLY
) ? 0555 : 0777;
15792 return (attr
& FILE_ATTRIBUTE_DIRECTORY
) ? directory_file
: regular_file
;
15795 /* ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PB_WAAH@Z */
15796 /* ?_Lstat@sys@tr2@std@@YA?AW4file_type@123@PEB_WAEAH@Z */
15797 enum file_type __cdecl
tr2_sys__Lstat_wchar(WCHAR
const* path
, int* err_code
)
15799 return tr2_sys__Stat_wchar(path
, err_code
);
15802 /* _Lstat, msvcp140 version */
15803 enum file_type __cdecl
_Lstat(WCHAR
const* path
, int* permissions
)
15805 return _Stat(path
, permissions
);
15808 WCHAR
* __cdecl
_Temp_get(WCHAR
*dst
)
15810 GetTempPathW(MAX_PATH
, dst
);
15814 /* ??1_Winit@std@@QAE@XZ */
15815 /* ??1_Winit@std@@QAE@XZ */
15816 DEFINE_THISCALL_WRAPPER(_Winit_dtor
, 4)
15817 void __thiscall
_Winit_dtor(void *this)
15819 TRACE("(%p)\n", this);
15821 _Winit__Init_cnt
--;
15822 if(!_Winit__Init_cnt
) {
15823 basic_ostream_wchar_flush(&wcout
.obj
);
15824 basic_ostream_wchar_flush(&wcerr
.obj
);
15825 basic_ostream_wchar_flush(&wclog
.obj
);
15829 /* ??4_Winit@std@@QAEAAV01@ABV01@@Z */
15830 /* ??4_Winit@std@@QEAAAEAV01@AEBV01@@Z */
15831 DEFINE_THISCALL_WRAPPER(_Winit_op_assign
, 8)
15832 void* __thiscall
_Winit_op_assign(void *this, void *rhs
)
15834 TRACE("(%p %p)\n", this, rhs
);
15838 void init_io(void *base
)
15841 init_iosb_rtti(base
);
15842 init_ios_base_rtti(base
);
15843 init_basic_ios_char_rtti(base
);
15844 init_basic_ios_wchar_rtti(base
);
15845 init_basic_ios_short_rtti(base
);
15846 init_basic_streambuf_char_rtti(base
);
15847 init_basic_streambuf_wchar_rtti(base
);
15848 init_basic_streambuf_short_rtti(base
);
15849 init_basic_filebuf_char_rtti(base
);
15850 init_basic_filebuf_wchar_rtti(base
);
15851 init_basic_filebuf_short_rtti(base
);
15852 init_basic_stringbuf_char_rtti(base
);
15853 init_basic_stringbuf_wchar_rtti(base
);
15854 init_basic_stringbuf_short_rtti(base
);
15855 init_basic_ostream_char_rtti(base
);
15856 init_basic_ostream_wchar_rtti(base
);
15857 init_basic_ostream_short_rtti(base
);
15858 init_basic_istream_char_rtti(base
);
15859 init_basic_istream_wchar_rtti(base
);
15860 init_basic_istream_short_rtti(base
);
15861 init_basic_iostream_char_rtti(base
);
15862 init_basic_iostream_wchar_rtti(base
);
15863 init_basic_iostream_short_rtti(base
);
15864 init_basic_ofstream_char_rtti(base
);
15865 init_basic_ofstream_wchar_rtti(base
);
15866 init_basic_ofstream_short_rtti(base
);
15867 init_basic_ifstream_char_rtti(base
);
15868 init_basic_ifstream_wchar_rtti(base
);
15869 init_basic_ifstream_short_rtti(base
);
15870 init_basic_fstream_char_rtti(base
);
15871 init_basic_fstream_wchar_rtti(base
);
15872 init_basic_fstream_short_rtti(base
);
15873 init_basic_ostringstream_char_rtti(base
);
15874 init_basic_ostringstream_wchar_rtti(base
);
15875 init_basic_ostringstream_short_rtti(base
);
15876 init_basic_istringstream_char_rtti(base
);
15877 init_basic_istringstream_wchar_rtti(base
);
15878 init_basic_istringstream_short_rtti(base
);
15879 init_basic_stringstream_char_rtti(base
);
15880 init_basic_stringstream_wchar_rtti(base
);
15881 init_basic_stringstream_short_rtti(base
);
15882 init_strstreambuf_rtti(base
);
15883 init_strstream_rtti(base
);
15884 init_ostrstream_rtti(base
);
15887 basic_filebuf_char_ctor_file(&filebuf_char_stdin
, stdin
);
15888 basic_istream_char_ctor(&cin
.obj
, &filebuf_char_stdin
.base
, FALSE
/*FIXME*/, TRUE
);
15890 basic_filebuf_short_ctor_file(&filebuf_short_stdin
, stdin
);
15891 basic_istream_short_ctor(&ucin
.obj
, &filebuf_short_stdin
.base
, FALSE
/*FIXME*/, TRUE
);
15893 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stdin
, stdin
);
15894 basic_istream_wchar_ctor(&wcin
.obj
, &filebuf_wchar_stdin
.base
, FALSE
/*FIXME*/, TRUE
);
15896 basic_filebuf_char_ctor_file(&filebuf_char_stdout
, stdout
);
15897 basic_ostream_char_ctor(&cout
.obj
, &filebuf_char_stdout
.base
, FALSE
/*FIXME*/, TRUE
);
15899 basic_filebuf_short_ctor_file(&filebuf_short_stdout
, stdout
);
15900 basic_ostream_short_ctor(&ucout
.obj
, &filebuf_short_stdout
.base
, FALSE
/*FIXME*/, TRUE
);
15902 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stdout
, stdout
);
15903 basic_ostream_wchar_ctor(&wcout
.obj
, &filebuf_wchar_stdout
.base
, FALSE
/*FIXME*/, TRUE
);
15905 basic_filebuf_char_ctor_file(&filebuf_char_stderr
, stderr
);
15906 basic_ostream_char_ctor(&cerr
.obj
, &filebuf_char_stderr
.base
, FALSE
/*FIXME*/, TRUE
);
15908 basic_filebuf_short_ctor_file(&filebuf_short_stderr
, stderr
);
15909 basic_ostream_short_ctor(&ucerr
.obj
, &filebuf_short_stderr
.base
, FALSE
/*FIXME*/, TRUE
);
15911 basic_filebuf_wchar_ctor_file(&filebuf_wchar_stderr
, stderr
);
15912 basic_ostream_wchar_ctor(&wcerr
.obj
, &filebuf_wchar_stderr
.base
, FALSE
/*FIXME*/, TRUE
);
15914 basic_filebuf_char_ctor_file(&filebuf_char_log
, stderr
);
15915 basic_ostream_char_ctor(&MSVCP_clog
.obj
, &filebuf_char_log
.base
, FALSE
/*FIXME*/, TRUE
);
15917 basic_filebuf_short_ctor_file(&filebuf_short_log
, stderr
);
15918 basic_ostream_short_ctor(&uclog
.obj
, &filebuf_short_log
.base
, FALSE
/*FIXME*/, TRUE
);
15920 basic_filebuf_wchar_ctor_file(&filebuf_wchar_log
, stderr
);
15921 basic_ostream_wchar_ctor(&wclog
.obj
, &filebuf_wchar_log
.base
, FALSE
/*FIXME*/, TRUE
);
15926 basic_istream_char_vbase_dtor(&cin
.obj
);
15927 basic_filebuf_char_dtor(&filebuf_char_stdin
);
15929 basic_istream_wchar_vbase_dtor(&ucin
.obj
);
15930 basic_filebuf_wchar_dtor(&filebuf_short_stdin
);
15932 basic_istream_wchar_vbase_dtor(&wcin
.obj
);
15933 basic_filebuf_wchar_dtor(&filebuf_wchar_stdin
);
15935 basic_ostream_char_vbase_dtor(&cout
.obj
);
15936 basic_filebuf_char_dtor(&filebuf_char_stdout
);
15938 basic_ostream_wchar_vbase_dtor(&ucout
.obj
);
15939 basic_filebuf_wchar_dtor(&filebuf_short_stdout
);
15941 basic_ostream_wchar_vbase_dtor(&wcout
.obj
);
15942 basic_filebuf_wchar_dtor(&filebuf_wchar_stdout
);
15944 basic_ostream_char_vbase_dtor(&cerr
.obj
);
15945 basic_filebuf_char_dtor(&filebuf_char_stderr
);
15947 basic_ostream_wchar_vbase_dtor(&ucerr
.obj
);
15948 basic_filebuf_wchar_dtor(&filebuf_short_stderr
);
15950 basic_ostream_wchar_vbase_dtor(&wcerr
.obj
);
15951 basic_filebuf_wchar_dtor(&filebuf_wchar_stderr
);
15953 basic_ostream_char_vbase_dtor(&MSVCP_clog
.obj
);
15954 basic_filebuf_char_dtor(&filebuf_char_log
);
15956 basic_ostream_wchar_vbase_dtor(&uclog
.obj
);
15957 basic_filebuf_wchar_dtor(&filebuf_short_log
);
15959 basic_ostream_wchar_vbase_dtor(&wclog
.obj
);
15960 basic_filebuf_wchar_dtor(&filebuf_wchar_log
);