2 * Copyright 2010 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/list.h"
33 #include "wine/unicode.h"
34 #include "wine/debug.h"
35 WINE_DEFAULT_DEBUG_CHANNEL(msvcp90);
37 char* __cdecl _Getdays(void);
38 char* __cdecl _Getmonths(void);
39 void* __cdecl _Gettnames(void);
40 unsigned int __cdecl ___lc_codepage_func(void);
41 LCID* __cdecl ___lc_handle_func(void);
42 const locale_facet* __thiscall locale__Getfacet(const locale*, MSVCP_size_t);
50 typedef struct _locale__Locimp {
52 locale_facet **facetvec;
53 MSVCP_size_t facet_cnt;
55 MSVCP_bool transparent;
56 basic_string_char name;
65 basic_string_char days;
66 basic_string_char months;
67 basic_string_char oldlocname;
68 basic_string_char newlocname;
110 const char *grouping;
113 const char *false_name;
114 const char *true_name;
119 const char *grouping;
122 const wchar_t *false_name;
123 const wchar_t *true_name;
132 typedef struct _istreambuf_iterator_char
134 struct _basic_streambuf_char *strbuf;
137 } istreambuf_iterator_char;
139 typedef struct _istreambuf_iterator_wchar
141 struct _basic_streambuf_wchar *strbuf;
144 } istreambuf_iterator_wchar;
146 /* ?_Id_cnt@id@locale@std@@0HA */
147 int locale_id__Id_cnt = 0;
149 static locale__Locimp *global_locale;
150 static locale classic_locale;
152 /* ?_Clocptr@_Locimp@locale@std@@0PAV123@A */
153 /* ?_Clocptr@_Locimp@locale@std@@0PEAV123@EA */
154 locale__Locimp *locale__Locimp__Clocptr = NULL;
156 /* ??1facet@locale@std@@UAE@XZ */
157 /* ??1facet@locale@std@@UEAA@XZ */
158 DEFINE_THISCALL_WRAPPER(locale_facet_dtor, 4)
159 void __thiscall locale_facet_dtor(locale_facet *this)
161 TRACE("(%p)\n", this);
164 DEFINE_THISCALL_WRAPPER(MSVCP_locale_facet_vector_dtor, 8)
165 #define call_locale_facet_vector_dtor(this, flags) CALL_VTBL_FUNC(this, 0, \
166 locale_facet*, (locale_facet*, unsigned int), (this, flags))
167 locale_facet* __thiscall MSVCP_locale_facet_vector_dtor(locale_facet *this, unsigned int flags)
169 TRACE("(%p %x)\n", this, flags);
171 /* we have an array, with the number of elements stored before the first object */
172 int i, *ptr = (int *)this-1;
174 for(i=*ptr-1; i>=0; i--)
175 locale_facet_dtor(this+i);
176 MSVCRT_operator_delete(ptr);
178 locale_facet_dtor(this);
180 MSVCRT_operator_delete(this);
191 static struct list lazy_facets = LIST_INIT(lazy_facets);
193 static void locale_facet_register(locale_facet *add)
195 facets_elem *head = MSVCRT_operator_new(sizeof(*head));
197 ERR("Out of memory\n");
198 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
202 list_add_head(&lazy_facets, &head->entry);
205 extern const vtable_ptr MSVCP_locale_facet_vtable;
207 /* ??0id@locale@std@@QAE@I@Z */
208 /* ??0id@locale@std@@QEAA@_K@Z */
209 DEFINE_THISCALL_WRAPPER(locale_id_ctor_id, 8)
210 locale_id* __thiscall locale_id_ctor_id(locale_id *this, MSVCP_size_t id)
212 TRACE("(%p %lu)\n", this, id);
218 /* ??_Fid@locale@std@@QAEXXZ */
219 /* ??_Fid@locale@std@@QEAAXXZ */
220 DEFINE_THISCALL_WRAPPER(locale_id_ctor, 4)
221 locale_id* __thiscall locale_id_ctor(locale_id *this)
223 TRACE("(%p)\n", this);
229 /* ??Bid@locale@std@@QAEIXZ */
230 /* ??Bid@locale@std@@QEAA_KXZ */
231 DEFINE_THISCALL_WRAPPER(locale_id_operator_size_t, 4)
232 MSVCP_size_t __thiscall locale_id_operator_size_t(locale_id *this)
236 TRACE("(%p)\n", this);
239 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
240 this->id = ++locale_id__Id_cnt;
247 /* ?_Id_cnt_func@id@locale@std@@CAAAHXZ */
248 /* ?_Id_cnt_func@id@locale@std@@CAAEAHXZ */
249 int* __cdecl locale_id__Id_cnt_func(void)
252 return &locale_id__Id_cnt;
255 /* ??_Ffacet@locale@std@@QAEXXZ */
256 /* ??_Ffacet@locale@std@@QEAAXXZ */
257 DEFINE_THISCALL_WRAPPER(locale_facet_ctor, 4)
258 locale_facet* __thiscall locale_facet_ctor(locale_facet *this)
260 TRACE("(%p)\n", this);
261 this->vtable = &MSVCP_locale_facet_vtable;
266 /* ??0facet@locale@std@@IAE@I@Z */
267 /* ??0facet@locale@std@@IEAA@_K@Z */
268 DEFINE_THISCALL_WRAPPER(locale_facet_ctor_refs, 8)
269 locale_facet* __thiscall locale_facet_ctor_refs(locale_facet *this, MSVCP_size_t refs)
271 TRACE("(%p %lu)\n", this, refs);
272 this->vtable = &MSVCP_locale_facet_vtable;
277 /* ?_Incref@facet@locale@std@@QAEXXZ */
278 /* ?_Incref@facet@locale@std@@QEAAXXZ */
279 DEFINE_THISCALL_WRAPPER(locale_facet__Incref, 4)
280 void __thiscall locale_facet__Incref(locale_facet *this)
284 TRACE("(%p)\n", this);
286 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
291 /* ?_Decref@facet@locale@std@@QAEPAV123@XZ */
292 /* ?_Decref@facet@locale@std@@QEAAPEAV123@XZ */
293 DEFINE_THISCALL_WRAPPER(locale_facet__Decref, 4)
294 locale_facet* __thiscall locale_facet__Decref(locale_facet *this)
299 TRACE("(%p)\n", this);
301 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
305 ret = this->refs ? NULL : this;
311 /* ?_Getcat@facet@locale@std@@SAIPAPBV123@PBV23@@Z */
312 /* ?_Getcat@facet@locale@std@@SA_KPEAPEBV123@PEBV23@@Z */
313 MSVCP_size_t __cdecl locale_facet__Getcat(const locale_facet **facet, const locale *loc)
315 TRACE("(%p %p)\n", facet, loc);
319 /* ??0_Timevec@std@@QAE@ABV01@@Z */
320 /* ??0_Timevec@std@@QEAA@AEBV01@@Z */
321 /* This copy constructor modifies copied object */
322 DEFINE_THISCALL_WRAPPER(_Timevec_copy_ctor, 8)
323 _Timevec* __thiscall _Timevec_copy_ctor(_Timevec *this, _Timevec *copy)
325 TRACE("(%p %p)\n", this, copy);
326 this->timeptr = copy->timeptr;
327 copy->timeptr = NULL;
331 /* ??0_Timevec@std@@QAE@PAX@Z */
332 /* ??0_Timevec@std@@QEAA@PEAX@Z */
333 DEFINE_THISCALL_WRAPPER(_Timevec_ctor_timeptr, 8)
334 _Timevec* __thiscall _Timevec_ctor_timeptr(_Timevec *this, void *timeptr)
336 TRACE("(%p %p)\n", this, timeptr);
337 this->timeptr = timeptr;
341 /* ??_F_Timevec@std@@QAEXXZ */
342 /* ??_F_Timevec@std@@QEAAXXZ */
343 DEFINE_THISCALL_WRAPPER(_Timevec_ctor, 4)
344 _Timevec* __thiscall _Timevec_ctor(_Timevec *this)
346 TRACE("(%p)\n", this);
347 this->timeptr = NULL;
351 /* ??1_Timevec@std@@QAE@XZ */
352 /* ??1_Timevec@std@@QEAA@XZ */
353 DEFINE_THISCALL_WRAPPER(_Timevec_dtor, 4)
354 void __thiscall _Timevec_dtor(_Timevec *this)
356 TRACE("(%p)\n", this);
360 /* ??4_Timevec@std@@QAEAAV01@ABV01@@Z */
361 /* ??4_Timevec@std@@QEAAAEAV01@AEBV01@@Z */
362 DEFINE_THISCALL_WRAPPER(_Timevec_op_assign, 8)
363 _Timevec* __thiscall _Timevec_op_assign(_Timevec *this, _Timevec *right)
365 TRACE("(%p %p)\n", this, right);
366 this->timeptr = right->timeptr;
367 right->timeptr = NULL;
371 /* ?_Getptr@_Timevec@std@@QBEPAXXZ */
372 /* ?_Getptr@_Timevec@std@@QEBAPEAXXZ */
373 DEFINE_THISCALL_WRAPPER(_Timevec__Getptr, 4)
374 void* __thiscall _Timevec__Getptr(_Timevec *this)
376 TRACE("(%p)\n", this);
377 return this->timeptr;
380 /* ?_Locinfo_ctor@_Locinfo@std@@SAXPAV12@HPBD@Z */
381 /* ?_Locinfo_ctor@_Locinfo@std@@SAXPEAV12@HPEBD@Z */
382 _Locinfo* __cdecl _Locinfo__Locinfo_ctor_cat_cstr(_Locinfo *locinfo, int category, const char *locstr)
384 const char *locale = NULL;
386 /* This function is probably modifying more global objects */
387 FIXME("(%p %d %s) semi-stub\n", locinfo, category, locstr);
390 throw_exception(EXCEPTION_RUNTIME_ERROR, "bad locale name");
392 _Lockit_ctor_locktype(&locinfo->lock, _LOCK_LOCALE);
393 MSVCP_basic_string_char_ctor_cstr(&locinfo->days, "");
394 MSVCP_basic_string_char_ctor_cstr(&locinfo->months, "");
395 MSVCP_basic_string_char_ctor_cstr(&locinfo->oldlocname, setlocale(LC_ALL, NULL));
398 locale = setlocale(LC_ALL, locstr);
400 locale = setlocale(LC_ALL, NULL);
403 MSVCP_basic_string_char_ctor_cstr(&locinfo->newlocname, locale);
405 MSVCP_basic_string_char_ctor_cstr(&locinfo->newlocname, "*");
410 /* ??0_Locinfo@std@@QAE@HPBD@Z */
411 /* ??0_Locinfo@std@@QEAA@HPEBD@Z */
412 DEFINE_THISCALL_WRAPPER(_Locinfo_ctor_cat_cstr, 12)
413 _Locinfo* __thiscall _Locinfo_ctor_cat_cstr(_Locinfo *this, int category, const char *locstr)
415 return _Locinfo__Locinfo_ctor_cat_cstr(this, category, locstr);
418 /* ?_Locinfo_ctor@_Locinfo@std@@SAXPAV12@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
419 /* ?_Locinfo_ctor@_Locinfo@std@@SAXPEAV12@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@@Z */
420 _Locinfo* __cdecl _Locinfo__Locinfo_ctor_bstr(_Locinfo *locinfo, const basic_string_char *locstr)
422 return _Locinfo__Locinfo_ctor_cat_cstr(locinfo, 1/*FIXME*/, MSVCP_basic_string_char_c_str(locstr));
425 /* ??0_Locinfo@std@@QAE@ABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@@Z */
426 /* ??0_Locinfo@std@@QEAA@AEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@@Z */
427 DEFINE_THISCALL_WRAPPER(_Locinfo_ctor_bstr, 8)
428 _Locinfo* __thiscall _Locinfo_ctor_bstr(_Locinfo *this, const basic_string_char *locstr)
430 return _Locinfo__Locinfo_ctor_cat_cstr(this, 1/*FIXME*/, MSVCP_basic_string_char_c_str(locstr));
433 /* ?_Locinfo_ctor@_Locinfo@std@@SAXPAV12@PBD@Z */
434 /* ?_Locinfo_ctor@_Locinfo@std@@SAXPEAV12@PEBD@Z */
435 _Locinfo* __cdecl _Locinfo__Locinfo_ctor_cstr(_Locinfo *locinfo, const char *locstr)
437 return _Locinfo__Locinfo_ctor_cat_cstr(locinfo, 1/*FIXME*/, locstr);
440 /* ??0_Locinfo@std@@QAE@PBD@Z */
441 /* ??0_Locinfo@std@@QEAA@PEBD@Z */
442 DEFINE_THISCALL_WRAPPER(_Locinfo_ctor_cstr, 8)
443 _Locinfo* __thiscall _Locinfo_ctor_cstr(_Locinfo *this, const char *locstr)
445 return _Locinfo__Locinfo_ctor_cat_cstr(this, 1/*FIXME*/, locstr);
448 /* ?_Locinfo_dtor@_Locinfo@std@@SAXPAV12@@Z */
449 /* ?_Locinfo_dtor@_Locinfo@std@@SAXPEAV12@@Z */
450 void __cdecl _Locinfo__Locinfo_dtor(_Locinfo *locinfo)
452 TRACE("(%p)\n", locinfo);
454 setlocale(LC_ALL, MSVCP_basic_string_char_c_str(&locinfo->oldlocname));
455 MSVCP_basic_string_char_dtor(&locinfo->days);
456 MSVCP_basic_string_char_dtor(&locinfo->months);
457 MSVCP_basic_string_char_dtor(&locinfo->oldlocname);
458 MSVCP_basic_string_char_dtor(&locinfo->newlocname);
459 _Lockit_dtor(&locinfo->lock);
462 /* ??_F_Locinfo@std@@QAEXXZ */
463 /* ??_F_Locinfo@std@@QEAAXXZ */
464 DEFINE_THISCALL_WRAPPER(_Locinfo_ctor, 4)
465 _Locinfo* __thiscall _Locinfo_ctor(_Locinfo *this)
467 return _Locinfo__Locinfo_ctor_cat_cstr(this, 1/*FIXME*/, "C");
470 /* ??1_Locinfo@std@@QAE@XZ */
471 /* ??1_Locinfo@std@@QEAA@XZ */
472 DEFINE_THISCALL_WRAPPER(_Locinfo_dtor, 4)
473 void __thiscall _Locinfo_dtor(_Locinfo *this)
475 _Locinfo__Locinfo_dtor(this);
478 /* ?_Locinfo_Addcats@_Locinfo@std@@SAAAV12@PAV12@HPBD@Z */
479 /* ?_Locinfo_Addcats@_Locinfo@std@@SAAEAV12@PEAV12@HPEBD@Z */
480 _Locinfo* __cdecl _Locinfo__Locinfo_Addcats(_Locinfo *locinfo, int category, const char *locstr)
482 const char *locale = NULL;
484 /* This function is probably modifying more global objects */
485 FIXME("(%p %d %s) semi-stub\n", locinfo, category, locstr);
487 throw_exception(EXCEPTION_RUNTIME_ERROR, "bad locale name");
489 MSVCP_basic_string_char_dtor(&locinfo->newlocname);
492 locale = setlocale(LC_ALL, locstr);
494 locale = setlocale(LC_ALL, NULL);
497 MSVCP_basic_string_char_ctor_cstr(&locinfo->newlocname, locale);
499 MSVCP_basic_string_char_ctor_cstr(&locinfo->newlocname, "*");
504 /* ?_Addcats@_Locinfo@std@@QAEAAV12@HPBD@Z */
505 /* ?_Addcats@_Locinfo@std@@QEAAAEAV12@HPEBD@Z */
506 DEFINE_THISCALL_WRAPPER(_Locinfo__Addcats, 12)
507 _Locinfo* __thiscall _Locinfo__Addcats(_Locinfo *this, int category, const char *locstr)
509 return _Locinfo__Locinfo_Addcats(this, category, locstr);
513 _Collvec __cdecl _Getcoll(void)
516 _locale_t locale = _get_current_locale();
520 ret.page = locale->locinfo->lc_collate_cp;
521 ret.handle = locale->locinfo->lc_handle[LC_COLLATE];
522 _free_locale(locale);
526 /* ?_Getcoll@_Locinfo@std@@QBE?AU_Collvec@@XZ */
527 /* ?_Getcoll@_Locinfo@std@@QEBA?AU_Collvec@@XZ */
528 DEFINE_THISCALL_WRAPPER(_Locinfo__Getcoll, 8)
529 _Collvec* __thiscall _Locinfo__Getcoll(const _Locinfo *this, _Collvec *ret)
536 _Ctypevec __cdecl _Getctype(void)
539 _locale_t locale = _get_current_locale();
544 ret.page = locale->locinfo->lc_codepage;
545 ret.handle = locale->locinfo->lc_handle[LC_COLLATE];
547 table = malloc(sizeof(short[256]));
549 _free_locale(locale);
550 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
552 memcpy(table, locale->locinfo->pctype, sizeof(short[256]));
554 _free_locale(locale);
558 /* ?_Getctype@_Locinfo@std@@QBE?AU_Ctypevec@@XZ */
559 /* ?_Getctype@_Locinfo@std@@QEBA?AU_Ctypevec@@XZ */
560 DEFINE_THISCALL_WRAPPER(_Locinfo__Getctype, 8)
561 _Ctypevec* __thiscall _Locinfo__Getctype(const _Locinfo *this, _Ctypevec *ret)
568 _Cvtvec __cdecl _Getcvt(void)
571 _locale_t locale = _get_current_locale();
575 ret.page = locale->locinfo->lc_codepage;
576 ret.handle = locale->locinfo->lc_handle[LC_CTYPE];
577 _free_locale(locale);
581 /* ?_Getcvt@_Locinfo@std@@QBE?AU_Cvtvec@@XZ */
582 /* ?_Getcvt@_Locinfo@std@@QEBA?AU_Cvtvec@@XZ */
583 DEFINE_THISCALL_WRAPPER(_Locinfo__Getcvt, 8)
584 _Cvtvec* __thiscall _Locinfo__Getcvt(const _Locinfo *this, _Cvtvec *ret)
590 /* ?_Getdateorder@_Locinfo@std@@QBEHXZ */
591 /* ?_Getdateorder@_Locinfo@std@@QEBAHXZ */
592 DEFINE_THISCALL_WRAPPER(_Locinfo__Getdateorder, 4)
593 int __thiscall _Locinfo__Getdateorder(const _Locinfo *this)
595 FIXME("(%p) stub\n", this);
599 /* ?_Getdays@_Locinfo@std@@QBEPBDXZ */
600 /* ?_Getdays@_Locinfo@std@@QEBAPEBDXZ */
601 DEFINE_THISCALL_WRAPPER(_Locinfo__Getdays, 4)
602 const char* __thiscall _Locinfo__Getdays(_Locinfo *this)
604 char *days = _Getdays();
606 TRACE("(%p)\n", this);
609 MSVCP_basic_string_char_dtor(&this->days);
610 MSVCP_basic_string_char_ctor_cstr(&this->days, days);
614 return this->days.size ? MSVCP_basic_string_char_c_str(&this->days) :
615 ":Sun:Sunday:Mon:Monday:Tue:Tuesday:Wed:Wednesday:Thu:Thursday:Fri:Friday:Sat:Saturday";
618 /* ?_Getmonths@_Locinfo@std@@QBEPBDXZ */
619 /* ?_Getmonths@_Locinfo@std@@QEBAPEBDXZ */
620 DEFINE_THISCALL_WRAPPER(_Locinfo__Getmonths, 4)
621 const char* __thiscall _Locinfo__Getmonths(_Locinfo *this)
623 char *months = _Getmonths();
625 TRACE("(%p)\n", this);
628 MSVCP_basic_string_char_dtor(&this->months);
629 MSVCP_basic_string_char_ctor_cstr(&this->months, months);
633 return this->months.size ? MSVCP_basic_string_char_c_str(&this->months) :
634 ":Jan:January:Feb:February:Mar:March:Apr:April:May:May:Jun:June:Jul:July"
635 ":Aug:August:Sep:September:Oct:October:Nov:November:Dec:December";
638 /* ?_Getfalse@_Locinfo@std@@QBEPBDXZ */
639 /* ?_Getfalse@_Locinfo@std@@QEBAPEBDXZ */
640 DEFINE_THISCALL_WRAPPER(_Locinfo__Getfalse, 4)
641 const char* __thiscall _Locinfo__Getfalse(const _Locinfo *this)
643 TRACE("(%p)\n", this);
647 /* ?_Gettrue@_Locinfo@std@@QBEPBDXZ */
648 /* ?_Gettrue@_Locinfo@std@@QEBAPEBDXZ */
649 DEFINE_THISCALL_WRAPPER(_Locinfo__Gettrue, 4)
650 const char* __thiscall _Locinfo__Gettrue(const _Locinfo *this)
652 TRACE("(%p)\n", this);
656 /* ?_Getlconv@_Locinfo@std@@QBEPBUlconv@@XZ */
657 /* ?_Getlconv@_Locinfo@std@@QEBAPEBUlconv@@XZ */
658 DEFINE_THISCALL_WRAPPER(_Locinfo__Getlconv, 4)
659 const struct lconv* __thiscall _Locinfo__Getlconv(const _Locinfo *this)
661 TRACE("(%p)\n", this);
665 /* ?_Getname@_Locinfo@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
666 /* ?_Getname@_Locinfo@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
667 DEFINE_THISCALL_WRAPPER(_Locinfo__Getname, 8)
668 basic_string_char* __thiscall _Locinfo__Getname(const _Locinfo *this, basic_string_char *ret)
670 TRACE("(%p)\n", this);
672 MSVCP_basic_string_char_copy_ctor(ret, &this->newlocname);
676 /* ?_Gettnames@_Locinfo@std@@QBE?AV_Timevec@2@XZ */
677 /* ?_Gettnames@_Locinfo@std@@QEBA?AV_Timevec@2@XZ */
678 DEFINE_THISCALL_WRAPPER(_Locinfo__Gettnames, 8)
679 _Timevec*__thiscall _Locinfo__Gettnames(const _Locinfo *this, _Timevec *ret)
681 TRACE("(%p)\n", this);
683 _Timevec_ctor_timeptr(ret, _Gettnames());
687 /* ?id@?$collate@D@std@@2V0locale@2@A */
688 locale_id collate_char_id = {0};
690 /* ??_7?$collate@D@std@@6B@ */
691 extern const vtable_ptr MSVCP_collate_char_vtable;
693 /* ?_Init@?$collate@D@std@@IAEXABV_Locinfo@2@@Z */
694 /* ?_Init@?$collate@D@std@@IEAAXAEBV_Locinfo@2@@Z */
695 DEFINE_THISCALL_WRAPPER(collate_char__Init, 8)
696 void __thiscall collate_char__Init(collate *this, const _Locinfo *locinfo)
698 TRACE("(%p %p)\n", this, locinfo);
699 _Locinfo__Getcoll(locinfo, &this->coll);
702 /* ??0?$collate@D@std@@IAE@PBDI@Z */
703 /* ??0?$collate@D@std@@IEAA@PEBD_K@Z */
704 DEFINE_THISCALL_WRAPPER(collate_char_ctor_name, 12)
705 collate* __thiscall collate_char_ctor_name(collate *this, const char *name, MSVCP_size_t refs)
709 TRACE("(%p %s %lu)\n", this, name, refs);
711 locale_facet_ctor_refs(&this->facet, refs);
712 this->facet.vtable = &MSVCP_collate_char_vtable;
714 _Locinfo_ctor_cstr(&locinfo, name);
715 collate_char__Init(this, &locinfo);
716 _Locinfo_dtor(&locinfo);
720 /* ??0?$collate@D@std@@QAE@ABV_Locinfo@1@I@Z */
721 /* ??0?$collate@D@std@@QEAA@AEBV_Locinfo@1@_K@Z */
722 DEFINE_THISCALL_WRAPPER(collate_char_ctor_locinfo, 12)
723 collate* __thiscall collate_char_ctor_locinfo(collate *this, _Locinfo *locinfo, MSVCP_size_t refs)
725 TRACE("(%p %p %lu)\n", this, locinfo, refs);
727 locale_facet_ctor_refs(&this->facet, refs);
728 this->facet.vtable = &MSVCP_collate_char_vtable;
729 collate_char__Init(this, locinfo);
733 /* ??0?$collate@D@std@@QAE@I@Z */
734 /* ??0?$collate@D@std@@QEAA@_K@Z */
735 DEFINE_THISCALL_WRAPPER(collate_char_ctor_refs, 8)
736 collate* __thiscall collate_char_ctor_refs(collate *this, MSVCP_size_t refs)
738 return collate_char_ctor_name(this, "C", refs);
741 /* ??1?$collate@D@std@@MAE@XZ */
742 /* ??1?$collate@D@std@@MEAA@XZ */
743 DEFINE_THISCALL_WRAPPER(collate_char_dtor, 4)
744 void __thiscall collate_char_dtor(collate *this)
746 TRACE("(%p)\n", this);
749 DEFINE_THISCALL_WRAPPER(MSVCP_collate_char_vector_dtor, 8)
750 collate* __thiscall MSVCP_collate_char_vector_dtor(collate *this, unsigned int flags)
752 TRACE("(%p %x)\n", this, flags);
754 /* we have an array, with the number of elements stored before the first object */
755 int i, *ptr = (int *)this-1;
757 for(i=*ptr-1; i>=0; i--)
758 collate_char_dtor(this+i);
759 MSVCRT_operator_delete(ptr);
761 collate_char_dtor(this);
763 MSVCRT_operator_delete(this);
769 /* ??_F?$collate@D@std@@QAEXXZ */
770 /* ??_F?$collate@D@std@@QEAAXXZ */
771 DEFINE_THISCALL_WRAPPER(collate_char_ctor, 4)
772 collate* __thiscall collate_char_ctor(collate *this)
774 return collate_char_ctor_name(this, "C", 0);
777 /* ?_Getcat@?$collate@D@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
778 /* ?_Getcat@?$collate@D@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
779 MSVCP_size_t __cdecl collate_char__Getcat(const locale_facet **facet, const locale *loc)
781 TRACE("(%p %p)\n", facet, loc);
783 if(facet && !*facet) {
784 *facet = MSVCRT_operator_new(sizeof(collate));
786 ERR("Out of memory\n");
787 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
790 collate_char_ctor_name((collate*)*facet,
791 MSVCP_basic_string_char_c_str(&loc->ptr->name), 0);
798 int __cdecl _Strcoll(const char *first1, const char *last1, const char *first2,
799 const char *last2, const _Collvec *coll)
803 TRACE("(%s %s)\n", debugstr_an(first1, last1-first1), debugstr_an(first2, last2-first2));
808 lcid = ___lc_handle_func()[LC_COLLATE];
809 return CompareStringA(lcid, 0, first1, last1-first1, first2, last2-first2)-2;
812 /* ?do_compare@?$collate@D@std@@MBEHPBD000@Z */
813 /* ?do_compare@?$collate@D@std@@MEBAHPEBD000@Z */
814 DEFINE_THISCALL_WRAPPER(collate_char_do_compare, 20)
815 #define call_collate_char_do_compare(this, first1, last1, first2, last2) CALL_VTBL_FUNC(this, 4, int, \
816 (const collate*, const char*, const char*, const char*, const char*), \
817 (this, first1, last1, first2, last2))
818 int __thiscall collate_char_do_compare(const collate *this, const char *first1,
819 const char *last1, const char *first2, const char *last2)
821 TRACE("(%p %p %p %p %p)\n", this, first1, last1, first2, last2);
822 return _Strcoll(first1, last1, first2, last2, &this->coll);
825 /* ?compare@?$collate@D@std@@QBEHPBD000@Z */
826 /* ?compare@?$collate@D@std@@QEBAHPEBD000@Z */
827 DEFINE_THISCALL_WRAPPER(collate_char_compare, 20)
828 int __thiscall collate_char_compare(const collate *this, const char *first1,
829 const char *last1, const char *first2, const char *last2)
831 TRACE("(%p %p %p %p %p)\n", this, first1, last1, first2, last2);
832 return call_collate_char_do_compare(this, first1, last1, first2, last2);
835 /* ?do_hash@?$collate@D@std@@MBEJPBD0@Z */
836 /* ?do_hash@?$collate@D@std@@MEBAJPEBD0@Z */
837 DEFINE_THISCALL_WRAPPER(collate_char_do_hash, 12)
838 #define call_collate_char_do_hash(this, first, last) CALL_VTBL_FUNC(this, 12, LONG, \
839 (const collate*, const char*, const char*), (this, first, last))
840 LONG __thiscall collate_char_do_hash(const collate *this,
841 const char *first, const char *last)
845 TRACE("(%p %p %p)\n", this, first, last);
847 for(; first<last; first++)
848 ret = (ret<<8 | ret>>24) + *first;
852 /* ?hash@?$collate@D@std@@QBEJPBD0@Z */
853 /* ?hash@?$collate@D@std@@QEBAJPEBD0@Z */
854 DEFINE_THISCALL_WRAPPER(collate_char_hash, 12)
855 LONG __thiscall collate_char_hash(const collate *this,
856 const char *first, const char *last)
858 TRACE("(%p %p %p)\n", this, first, last);
859 return call_collate_char_do_hash(this, first, last);
862 /* ?do_transform@?$collate@D@std@@MBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@PBD0@Z */
863 /* ?do_transform@?$collate@D@std@@MEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@PEBD0@Z */
864 DEFINE_THISCALL_WRAPPER(collate_char_do_transform, 16)
865 basic_string_char* __thiscall collate_char_do_transform(const collate *this,
866 basic_string_char *ret, const char *first, const char *last)
868 FIXME("(%p %p %p) stub\n", this, first, last);
872 /* ?transform@?$collate@D@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@PBD0@Z */
873 /* ?transform@?$collate@D@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@PEBD0@Z */
874 DEFINE_THISCALL_WRAPPER(collate_char_transform, 16)
875 basic_string_char* __thiscall collate_char_transform(const collate *this,
876 basic_string_char *ret, const char *first, const char *last)
878 FIXME("(%p %p %p) stub\n", this, first, last);
882 /* ?id@?$collate@_W@std@@2V0locale@2@A */
883 locale_id collate_wchar_id = {0};
884 /* ?id@?$collate@G@std@@2V0locale@2@A */
885 locale_id collate_short_id = {0};
887 /* ??_7?$collate@_W@std@@6B@ */
888 extern const vtable_ptr MSVCP_collate_wchar_vtable;
889 /* ??_7?$collate@G@std@@6B@ */
890 extern const vtable_ptr MSVCP_collate_short_vtable;
892 /* ?_Init@?$collate@_W@std@@IAEXABV_Locinfo@2@@Z */
893 /* ?_Init@?$collate@_W@std@@IEAAXAEBV_Locinfo@2@@Z */
894 /* ?_Init@?$collate@G@std@@IAEXABV_Locinfo@2@@Z */
895 /* ?_Init@?$collate@G@std@@IEAAXAEBV_Locinfo@2@@Z */
896 DEFINE_THISCALL_WRAPPER(collate_wchar__Init, 8)
897 void __thiscall collate_wchar__Init(collate *this, const _Locinfo *locinfo)
899 TRACE("(%p %p)\n", this, locinfo);
900 _Locinfo__Getcoll(locinfo, &this->coll);
903 /* ??0?$collate@_W@std@@IAE@PBDI@Z */
904 /* ??0?$collate@_W@std@@IEAA@PEBD_K@Z */
905 DEFINE_THISCALL_WRAPPER(collate_wchar_ctor_name, 12)
906 collate* __thiscall collate_wchar_ctor_name(collate *this, const char *name, MSVCP_size_t refs)
910 TRACE("(%p %s %lu)\n", this, name, refs);
912 locale_facet_ctor_refs(&this->facet, refs);
913 this->facet.vtable = &MSVCP_collate_wchar_vtable;
915 _Locinfo_ctor_cstr(&locinfo, name);
916 collate_wchar__Init(this, &locinfo);
917 _Locinfo_dtor(&locinfo);
921 /* ??0?$collate@G@std@@IAE@PBDI@Z */
922 /* ??0?$collate@G@std@@IEAA@PEBD_K@Z */
923 DEFINE_THISCALL_WRAPPER(collate_short_ctor_name, 12)
924 collate* __thiscall collate_short_ctor_name(collate *this, const char *name, MSVCP_size_t refs)
926 collate *ret = collate_wchar_ctor_name(this, name, refs);
927 ret->facet.vtable = &MSVCP_collate_short_vtable;
931 /* ??0?$collate@_W@std@@QAE@ABV_Locinfo@1@I@Z */
932 /* ??0?$collate@_W@std@@QEAA@AEBV_Locinfo@1@_K@Z */
933 DEFINE_THISCALL_WRAPPER(collate_wchar_ctor_locinfo, 12)
934 collate* __thiscall collate_wchar_ctor_locinfo(collate *this, _Locinfo *locinfo, MSVCP_size_t refs)
936 TRACE("(%p %p %lu)\n", this, locinfo, refs);
938 locale_facet_ctor_refs(&this->facet, refs);
939 this->facet.vtable = &MSVCP_collate_wchar_vtable;
940 collate_wchar__Init(this, locinfo);
944 /* ??0?$collate@G@std@@QAE@ABV_Locinfo@1@I@Z */
945 /* ??0?$collate@G@std@@QEAA@AEBV_Locinfo@1@_K@Z */
946 DEFINE_THISCALL_WRAPPER(collate_short_ctor_locinfo, 12)
947 collate* __thiscall collate_short_ctor_locinfo(collate *this, _Locinfo *locinfo, MSVCP_size_t refs)
949 collate *ret = collate_wchar_ctor_locinfo(this, locinfo, refs);
950 ret->facet.vtable = &MSVCP_collate_short_vtable;
954 /* ??0?$collate@_W@std@@QAE@I@Z */
955 /* ??0?$collate@_W@std@@QEAA@_K@Z */
956 DEFINE_THISCALL_WRAPPER(collate_wchar_ctor_refs, 8)
957 collate* __thiscall collate_wchar_ctor_refs(collate *this, MSVCP_size_t refs)
959 return collate_wchar_ctor_name(this, "C", refs);
962 /* ??0?$collate@G@std@@QAE@I@Z */
963 /* ??0?$collate@G@std@@QEAA@_K@Z */
964 DEFINE_THISCALL_WRAPPER(collate_short_ctor_refs, 8)
965 collate* __thiscall collate_short_ctor_refs(collate *this, MSVCP_size_t refs)
967 collate *ret = collate_wchar_ctor_refs(this, refs);
968 ret->facet.vtable = &MSVCP_collate_short_vtable;
972 /* ??1?$collate@_W@std@@MAE@XZ */
973 /* ??1?$collate@_W@std@@MEAA@XZ */
974 /* ??1?$collate@G@std@@MAE@XZ */
975 /* ??1?$collate@G@std@@MEAA@XZ */
976 DEFINE_THISCALL_WRAPPER(collate_wchar_dtor, 4)
977 void __thiscall collate_wchar_dtor(collate *this)
979 TRACE("(%p)\n", this);
982 DEFINE_THISCALL_WRAPPER(MSVCP_collate_wchar_vector_dtor, 8)
983 collate* __thiscall MSVCP_collate_wchar_vector_dtor(collate *this, unsigned int flags)
985 TRACE("(%p %x)\n", this, flags);
987 /* we have an array, with the number of elements stored before the first object */
988 int i, *ptr = (int *)this-1;
990 for(i=*ptr-1; i>=0; i--)
991 collate_wchar_dtor(this+i);
992 MSVCRT_operator_delete(ptr);
994 collate_wchar_dtor(this);
996 MSVCRT_operator_delete(this);
1002 DEFINE_THISCALL_WRAPPER(MSVCP_collate_short_vector_dtor, 8)
1003 collate* __thiscall MSVCP_collate_short_vector_dtor(collate *this, unsigned int flags)
1005 return MSVCP_collate_wchar_vector_dtor(this, flags);
1008 /* ??_F?$collate@_W@std@@QAEXXZ */
1009 /* ??_F?$collate@_W@std@@QEAAXXZ */
1010 DEFINE_THISCALL_WRAPPER(collate_wchar_ctor, 4)
1011 collate* __thiscall collate_wchar_ctor(collate *this)
1013 return collate_wchar_ctor_name(this, "C", 0);
1016 /* ??_F?$collate@G@std@@QAEXXZ */
1017 /* ??_F?$collate@G@std@@QEAAXXZ */
1018 DEFINE_THISCALL_WRAPPER(collate_short_ctor, 4)
1019 collate* __thiscall collate_short_ctor(collate *this)
1021 collate *ret = collate_wchar_ctor(this);
1022 ret->facet.vtable = &MSVCP_collate_short_vtable;
1026 /* ?_Getcat@?$collate@_W@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
1027 /* ?_Getcat@?$collate@_W@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
1028 MSVCP_size_t __cdecl collate_wchar__Getcat(const locale_facet **facet, const locale *loc)
1030 TRACE("(%p %p)\n", facet, loc);
1032 if(facet && !*facet) {
1033 *facet = MSVCRT_operator_new(sizeof(collate));
1035 ERR("Out of memory\n");
1036 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
1039 collate_wchar_ctor_name((collate*)*facet,
1040 MSVCP_basic_string_char_c_str(&loc->ptr->name), 0);
1046 /* ?_Getcat@?$collate@G@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
1047 /* ?_Getcat@?$collate@G@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
1048 MSVCP_size_t __cdecl collate_short__Getcat(const locale_facet **facet, const locale *loc)
1050 if(facet && !*facet) {
1051 collate_wchar__Getcat(facet, loc);
1052 (*(locale_facet**)facet)->vtable = &MSVCP_collate_short_vtable;
1059 int __cdecl _Wcscoll(const wchar_t *first1, const wchar_t *last1, const wchar_t *first2,
1060 const wchar_t *last2, const _Collvec *coll)
1064 TRACE("(%s %s)\n", debugstr_wn(first1, last1-first1), debugstr_wn(first2, last2-first2));
1067 lcid = coll->handle;
1069 lcid = ___lc_handle_func()[LC_COLLATE];
1070 return CompareStringW(lcid, 0, first1, last1-first1, first2, last2-first2)-2;
1073 /* ?do_compare@?$collate@_W@std@@MBEHPB_W000@Z */
1074 /* ?do_compare@?$collate@_W@std@@MEBAHPEB_W000@Z */
1075 /* ?do_compare@?$collate@G@std@@MBEHPBG000@Z */
1076 /* ?do_compare@?$collate@G@std@@MEBAHPEBG000@Z */
1077 DEFINE_THISCALL_WRAPPER(collate_wchar_do_compare, 20)
1078 #define call_collate_wchar_do_compare(this, first1, last1, first2, last2) CALL_VTBL_FUNC(this, 4, int, \
1079 (const collate*, const wchar_t*, const wchar_t*, const wchar_t*, const wchar_t*), \
1080 (this, first1, last1, first2, last2))
1081 int __thiscall collate_wchar_do_compare(const collate *this, const wchar_t *first1,
1082 const wchar_t *last1, const wchar_t *first2, const wchar_t *last2)
1084 TRACE("(%p %p %p %p %p)\n", this, first1, last1, first2, last2);
1085 return _Wcscoll(first1, last1, first2, last2, &this->coll);
1088 /* ?compare@?$collate@_W@std@@QBEHPB_W000@Z */
1089 /* ?compare@?$collate@_W@std@@QEBAHPEB_W000@Z */
1090 /* ?compare@?$collate@G@std@@QBEHPBG000@Z */
1091 /* ?compare@?$collate@G@std@@QEBAHPEBG000@Z */
1092 DEFINE_THISCALL_WRAPPER(collate_wchar_compare, 20)
1093 int __thiscall collate_wchar_compare(const collate *this, const wchar_t *first1,
1094 const wchar_t *last1, const wchar_t *first2, const wchar_t *last2)
1096 TRACE("(%p %p %p %p %p)\n", this, first1, last1, first2, last2);
1097 return call_collate_wchar_do_compare(this, first1, last1, first2, last2);
1100 /* ?do_hash@?$collate@_W@std@@MBEJPB_W0@Z */
1101 /* ?do_hash@?$collate@_W@std@@MEBAJPEB_W0@Z */
1102 /* ?do_hash@?$collate@G@std@@MBEJPBG0@Z */
1103 /* ?do_hash@?$collate@G@std@@MEBAJPEBG0@Z */
1104 DEFINE_THISCALL_WRAPPER(collate_wchar_do_hash, 12)
1105 #define call_collate_wchar_do_hash(this, first, last) CALL_VTBL_FUNC(this, 12, LONG, \
1106 (const collate*, const wchar_t*, const wchar_t*), (this, first, last))
1107 LONG __thiscall collate_wchar_do_hash(const collate *this,
1108 const wchar_t *first, const wchar_t *last)
1112 TRACE("(%p %p %p)\n", this, first, last);
1114 for(; first<last; first++)
1115 ret = (ret<<8 | ret>>24) + *first;
1119 /* ?hash@?$collate@_W@std@@QBEJPB_W0@Z */
1120 /* ?hash@?$collate@_W@std@@QEBAJPEB_W0@Z */
1121 /* ?hash@?$collate@G@std@@QBEJPBG0@Z */
1122 /* ?hash@?$collate@G@std@@QEBAJPEBG0@Z */
1123 DEFINE_THISCALL_WRAPPER(collate_wchar_hash, 12)
1124 LONG __thiscall collate_wchar_hash(const collate *this,
1125 const wchar_t *first, const wchar_t *last)
1127 TRACE("(%p %p %p)\n", this, first, last);
1128 return call_collate_wchar_do_hash(this, first, last);
1131 /* ?do_transform@?$collate@_W@std@@MBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@PB_W0@Z */
1132 /* ?do_transform@?$collate@_W@std@@MEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@PEB_W0@Z */
1133 /* ?do_transform@?$collate@G@std@@MBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@PBG0@Z */
1134 /* ?do_transform@?$collate@G@std@@MEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@PEBG0@Z */
1135 DEFINE_THISCALL_WRAPPER(collate_wchar_do_transform, 16)
1136 basic_string_wchar* __thiscall collate_wchar_do_transform(const collate *this,
1137 basic_string_wchar *ret, const wchar_t *first, const wchar_t *last)
1139 FIXME("(%p %p %p) stub\n", this, first, last);
1143 /* ?transform@?$collate@_W@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@PB_W0@Z */
1144 /* ?transform@?$collate@_W@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@PEB_W0@Z */
1145 /* ?transform@?$collate@G@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@PBG0@Z */
1146 /* ?transform@?$collate@G@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@PEBG0@Z */
1147 DEFINE_THISCALL_WRAPPER(collate_wchar_transform, 16)
1148 basic_string_wchar* __thiscall collate_wchar_transform(const collate *this,
1149 basic_string_wchar *ret, const wchar_t *first, const wchar_t *last)
1151 FIXME("(%p %p %p) stub\n", this, first, last);
1155 /* ??_7ctype_base@std@@6B@ */
1156 extern const vtable_ptr MSVCP_ctype_base_vtable;
1158 /* ??0ctype_base@std@@QAE@I@Z */
1159 /* ??0ctype_base@std@@QEAA@_K@Z */
1160 DEFINE_THISCALL_WRAPPER(ctype_base_ctor_refs, 8)
1161 ctype_base* __thiscall ctype_base_ctor_refs(ctype_base *this, MSVCP_size_t refs)
1163 TRACE("(%p %lu)\n", this, refs);
1164 locale_facet_ctor_refs(&this->facet, refs);
1165 this->facet.vtable = &MSVCP_ctype_base_vtable;
1169 /* ??_Fctype_base@std@@QAEXXZ */
1170 /* ??_Fctype_base@std@@QEAAXXZ */
1171 DEFINE_THISCALL_WRAPPER(ctype_base_ctor, 4)
1172 ctype_base* __thiscall ctype_base_ctor(ctype_base *this)
1174 TRACE("(%p)\n", this);
1175 locale_facet_ctor_refs(&this->facet, 0);
1176 this->facet.vtable = &MSVCP_ctype_base_vtable;
1180 /* ??1ctype_base@std@@UAE@XZ */
1181 /* ??1ctype_base@std@@UEAA@XZ */
1182 DEFINE_THISCALL_WRAPPER(ctype_base_dtor, 4)
1183 void __thiscall ctype_base_dtor(ctype_base *this)
1185 TRACE("(%p)\n", this);
1188 DEFINE_THISCALL_WRAPPER(MSVCP_ctype_base_vector_dtor, 8)
1189 ctype_base* __thiscall MSVCP_ctype_base_vector_dtor(ctype_base *this, unsigned int flags)
1191 TRACE("(%p %x)\n", this, flags);
1193 /* we have an array, with the number of elements stored before the first object */
1194 int i, *ptr = (int *)this-1;
1196 for(i=*ptr-1; i>=0; i--)
1197 ctype_base_dtor(this+i);
1198 MSVCRT_operator_delete(ptr);
1200 ctype_base_dtor(this);
1202 MSVCRT_operator_delete(this);
1208 /* ?_Xran@ctype_base@std@@KAXXZ */
1209 void __cdecl ctype_base__Xran(void)
1211 throw_exception(EXCEPTION_OUT_OF_RANGE, "out of range in ctype<T>");
1214 /* ?id@?$ctype@D@std@@2V0locale@2@A */
1215 locale_id ctype_char_id = {0};
1216 /* ?table_size@?$ctype@D@std@@2IB */
1217 /* ?table_size@?$ctype@D@std@@2_KB */
1218 MSVCP_size_t ctype_char_table_size = 256;
1220 /* ??_7?$ctype@D@std@@6B@ */
1221 extern const vtable_ptr MSVCP_ctype_char_vtable;
1223 /* ?_Id_func@?$ctype@D@std@@SAAAVid@locale@2@XZ */
1224 /* ?_Id_func@?$ctype@D@std@@SAAEAVid@locale@2@XZ */
1225 locale_id* __cdecl ctype_char__Id_func(void)
1228 return &ctype_char_id;
1231 /* ?_Init@?$ctype@D@std@@IAEXABV_Locinfo@2@@Z */
1232 /* ?_Init@?$ctype@D@std@@IEAAXAEBV_Locinfo@2@@Z */
1233 DEFINE_THISCALL_WRAPPER(ctype_char__Init, 8)
1234 void __thiscall ctype_char__Init(ctype_char *this, _Locinfo *locinfo)
1236 TRACE("(%p %p)\n", this, locinfo);
1237 _Locinfo__Getctype(locinfo, &this->ctype);
1240 /* ?_Tidy@?$ctype@D@std@@IAEXXZ */
1241 /* ?_Tidy@?$ctype@D@std@@IEAAXXZ */
1242 DEFINE_THISCALL_WRAPPER(ctype_char__Tidy, 4)
1243 void __thiscall ctype_char__Tidy(ctype_char *this)
1245 TRACE("(%p)\n", this);
1247 if(this->ctype.delfl)
1248 free((short*)this->ctype.table);
1251 /* ?classic_table@?$ctype@D@std@@KAPBFXZ */
1252 /* ?classic_table@?$ctype@D@std@@KAPEBFXZ */
1253 const short* __cdecl ctype_char_classic_table(void)
1256 return &((short*)GetProcAddress(GetModuleHandleA("msvcrt.dll"), "_ctype"))[1];
1259 /* ??0?$ctype@D@std@@QAE@ABV_Locinfo@1@I@Z */
1260 /* ??0?$ctype@D@std@@QEAA@AEBV_Locinfo@1@_K@Z */
1261 DEFINE_THISCALL_WRAPPER(ctype_char_ctor_locinfo, 12)
1262 ctype_char* __thiscall ctype_char_ctor_locinfo(ctype_char *this,
1263 _Locinfo *locinfo, MSVCP_size_t refs)
1265 TRACE("(%p %p %lu)\n", this, locinfo, refs);
1266 ctype_base_ctor_refs(&this->base, refs);
1267 this->base.facet.vtable = &MSVCP_ctype_char_vtable;
1268 ctype_char__Init(this, locinfo);
1272 /* ??0?$ctype@D@std@@QAE@PBF_NI@Z */
1273 /* ??0?$ctype@D@std@@QEAA@PEBF_N_K@Z */
1274 DEFINE_THISCALL_WRAPPER(ctype_char_ctor_table, 16)
1275 ctype_char* __thiscall ctype_char_ctor_table(ctype_char *this,
1276 const short *table, MSVCP_bool delete, MSVCP_size_t refs)
1280 TRACE("(%p %p %d %lu)\n", this, table, delete, refs);
1282 ctype_base_ctor_refs(&this->base, refs);
1283 this->base.facet.vtable = &MSVCP_ctype_char_vtable;
1285 _Locinfo_ctor(&locinfo);
1286 ctype_char__Init(this, &locinfo);
1287 _Locinfo_dtor(&locinfo);
1290 ctype_char__Tidy(this);
1291 this->ctype.table = table;
1292 this->ctype.delfl = delete;
1297 /* ??_F?$ctype@D@std@@QAEXXZ */
1298 /* ??_F?$ctype@D@std@@QEAAXXZ */
1299 DEFINE_THISCALL_WRAPPER(ctype_char_ctor, 4)
1300 ctype_char* __thiscall ctype_char_ctor(ctype_char *this)
1302 return ctype_char_ctor_table(this, NULL, FALSE, 0);
1305 /* ??1?$ctype@D@std@@MAE@XZ */
1306 /* ??1?$ctype@D@std@@MEAA@XZ */
1307 DEFINE_THISCALL_WRAPPER(ctype_char_dtor, 4)
1308 void __thiscall ctype_char_dtor(ctype_char *this)
1310 TRACE("(%p)\n", this);
1311 ctype_char__Tidy(this);
1314 DEFINE_THISCALL_WRAPPER(MSVCP_ctype_char_vector_dtor, 8)
1315 ctype_char* __thiscall MSVCP_ctype_char_vector_dtor(ctype_char *this, unsigned int flags)
1317 TRACE("(%p %x)\n", this, flags);
1319 /* we have an array, with the number of elements stored before the first object */
1320 int i, *ptr = (int *)this-1;
1322 for(i=*ptr-1; i>=0; i--)
1323 ctype_char_dtor(this+i);
1324 MSVCRT_operator_delete(ptr);
1326 ctype_char_dtor(this);
1328 MSVCRT_operator_delete(this);
1334 /* ?do_narrow@?$ctype@D@std@@MBEDDD@Z */
1335 /* ?do_narrow@?$ctype@D@std@@MEBADDD@Z */
1336 DEFINE_THISCALL_WRAPPER(ctype_char_do_narrow_ch, 12)
1337 #define call_ctype_char_do_narrow_ch(this, ch, unused) CALL_VTBL_FUNC(this, 36, \
1338 char, (const ctype_char*, char, char), (this, ch, unused))
1339 char __thiscall ctype_char_do_narrow_ch(const ctype_char *this, char ch, char unused)
1341 TRACE("(%p %c %c)\n", this, ch, unused);
1345 /* ?do_narrow@?$ctype@D@std@@MBEPBDPBD0DPAD@Z */
1346 /* ?do_narrow@?$ctype@D@std@@MEBAPEBDPEBD0DPEAD@Z */
1347 DEFINE_THISCALL_WRAPPER(ctype_char_do_narrow, 20)
1348 #define call_ctype_char_do_narrow(this, first, last, unused, dest) CALL_VTBL_FUNC(this, 32, \
1349 const char*, (const ctype_char*, const char*, const char*, char, char*), \
1350 (this, first, last, unused, dest))
1351 const char* __thiscall ctype_char_do_narrow(const ctype_char *this,
1352 const char *first, const char *last, char unused, char *dest)
1354 TRACE("(%p %p %p %p)\n", this, first, last, dest);
1355 memcpy(dest, first, last-first);
1359 /* ?_Do_narrow_s@?$ctype@D@std@@MBEPBDPBD0DPADI@Z */
1360 /* ?_Do_narrow_s@?$ctype@D@std@@MEBAPEBDPEBD0DPEAD_K@Z */
1361 DEFINE_THISCALL_WRAPPER(ctype_char__Do_narrow_s, 24)
1362 #define call_ctype_char__Do_narrow_s(this, first, last, unused, dest, size) CALL_VTBL_FUNC(this, 40, \
1363 const char*, (const ctype_char*, const char*, const char*, char, char*, MSVCP_size_t), \
1364 (this, first, last, unused, dest, size))
1365 const char* __thiscall ctype_char__Do_narrow_s(const ctype_char *this, const char *first,
1366 const char *last, char unused, char *dest, MSVCP_size_t size)
1368 TRACE("(%p %p %p %p %lu)\n", this, first, last, dest, size);
1369 memcpy_s(dest, size, first, last-first);
1373 /* ?narrow@?$ctype@D@std@@QBEDDD@Z */
1374 /* ?narrow@?$ctype@D@std@@QEBADDD@Z */
1375 DEFINE_THISCALL_WRAPPER(ctype_char_narrow_ch, 12)
1376 char __thiscall ctype_char_narrow_ch(const ctype_char *this, char ch, char dflt)
1378 TRACE("(%p %c %c)\n", this, ch, dflt);
1379 return call_ctype_char_do_narrow_ch(this, ch, dflt);
1382 /* ?narrow@?$ctype@D@std@@QBEPBDPBD0DPAD@Z */
1383 /* ?narrow@?$ctype@D@std@@QEBAPEBDPEBD0DPEAD@Z */
1384 DEFINE_THISCALL_WRAPPER(ctype_char_narrow, 20)
1385 const char* __thiscall ctype_char_narrow(const ctype_char *this,
1386 const char *first, const char *last, char dflt, char *dest)
1388 TRACE("(%p %p %p %c %p)\n", this, first, last, dflt, dest);
1389 return call_ctype_char_do_narrow(this, first, last, dflt, dest);
1392 /* ?_Narrow_s@?$ctype@D@std@@QBEPBDPBD0DPADI@Z */
1393 /* ?_Narrow_s@?$ctype@D@std@@QEBAPEBDPEBD0DPEAD_K@Z */
1394 DEFINE_THISCALL_WRAPPER(ctype_char__Narrow_s, 24)
1395 const char* __thiscall ctype_char__Narrow_s(const ctype_char *this, const char *first,
1396 const char *last, char dflt, char *dest, MSVCP_size_t size)
1398 TRACE("(%p %p %p %p %lu)\n", this, first, last, dest, size);
1399 return call_ctype_char__Do_narrow_s(this, first, last, dflt, dest, size);
1402 /* ?do_widen@?$ctype@D@std@@MBEDD@Z */
1403 /* ?do_widen@?$ctype@D@std@@MEBADD@Z */
1404 DEFINE_THISCALL_WRAPPER(ctype_char_do_widen_ch, 8)
1405 #define call_ctype_char_do_widen_ch(this, ch) CALL_VTBL_FUNC(this, 24, \
1406 char, (const ctype_char*, char), (this, ch))
1407 char __thiscall ctype_char_do_widen_ch(const ctype_char *this, char ch)
1409 TRACE("(%p %c)\n", this, ch);
1413 /* ?do_widen@?$ctype@D@std@@MBEPBDPBD0PAD@Z */
1414 /* ?do_widen@?$ctype@D@std@@MEBAPEBDPEBD0PEAD@Z */
1415 DEFINE_THISCALL_WRAPPER(ctype_char_do_widen, 16)
1416 #define call_ctype_char_do_widen(this, first, last, dest) CALL_VTBL_FUNC(this, 20, \
1417 const char*, (const ctype_char*, const char*, const char*, char*), \
1418 (this, first, last, dest))
1419 const char* __thiscall ctype_char_do_widen(const ctype_char *this,
1420 const char *first, const char *last, char *dest)
1422 TRACE("(%p %p %p %p)\n", this, first, last, dest);
1423 memcpy(dest, first, last-first);
1427 /* ?_Do_widen_s@?$ctype@D@std@@MBEPBDPBD0PADI@Z */
1428 /* ?_Do_widen_s@?$ctype@D@std@@MEBAPEBDPEBD0PEAD_K@Z */
1429 DEFINE_THISCALL_WRAPPER(ctype_char__Do_widen_s, 20)
1430 #define call_ctype_char__Do_widen_s(this, first, last, dest, size) CALL_VTBL_FUNC(this, 28, \
1431 const char*, (const ctype_char*, const char*, const char*, char*, MSVCP_size_t), \
1432 (this, first, last, dest, size))
1433 const char* __thiscall ctype_char__Do_widen_s(const ctype_char *this,
1434 const char *first, const char *last, char *dest, MSVCP_size_t size)
1436 TRACE("(%p %p %p %p %lu)\n", this, first, last, dest, size);
1437 memcpy_s(dest, size, first, last-first);
1441 /* ?widen@?$ctype@D@std@@QBEDD@Z */
1442 /* ?widen@?$ctype@D@std@@QEBADD@Z */
1443 DEFINE_THISCALL_WRAPPER(ctype_char_widen_ch, 8)
1444 char __thiscall ctype_char_widen_ch(const ctype_char *this, char ch)
1446 TRACE("(%p %c)\n", this, ch);
1447 return call_ctype_char_do_widen_ch(this, ch);
1450 /* ?widen@?$ctype@D@std@@QBEPBDPBD0PAD@Z */
1451 /* ?widen@?$ctype@D@std@@QEBAPEBDPEBD0PEAD@Z */
1452 DEFINE_THISCALL_WRAPPER(ctype_char_widen, 16)
1453 const char* __thiscall ctype_char_widen(const ctype_char *this,
1454 const char *first, const char *last, char *dest)
1456 TRACE("(%p %p %p %p)\n", this, first, last, dest);
1457 return call_ctype_char_do_widen(this, first, last, dest);
1460 /* ?_Widen_s@?$ctype@D@std@@QBEPBDPBD0PADI@Z */
1461 /* ?_Widen_s@?$ctype@D@std@@QEBAPEBDPEBD0PEAD_K@Z */
1462 DEFINE_THISCALL_WRAPPER(ctype_char__Widen_s, 20)
1463 const char* __thiscall ctype_char__Widen_s(const ctype_char *this,
1464 const char *first, const char *last, char *dest, MSVCP_size_t size)
1466 TRACE("(%p %p %p %p %lu)\n", this, first, last, dest, size);
1467 return call_ctype_char__Do_widen_s(this, first, last, dest, size);
1470 /* ?_Getcat@?$ctype@D@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
1471 /* ?_Getcat@?$ctype@D@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
1472 MSVCP_size_t __cdecl ctype_char__Getcat(const locale_facet **facet, const locale *loc)
1474 TRACE("(%p %p)\n", facet, loc);
1476 if(facet && !*facet) {
1479 *facet = MSVCRT_operator_new(sizeof(ctype_char));
1481 ERR("Out of memory\n");
1482 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
1486 _Locinfo_ctor_cstr(&locinfo, MSVCP_basic_string_char_c_str(&loc->ptr->name));
1487 ctype_char_ctor_locinfo((ctype_char*)*facet, &locinfo, 0);
1488 _Locinfo_dtor(&locinfo);
1495 int __cdecl _Tolower(int ch, const _Ctypevec *ctype)
1499 TRACE("%d %p\n", ch, ctype);
1504 cp = ___lc_codepage_func();
1506 /* Don't convert to unicode in case of C locale */
1508 if(ch>='A' && ch<='Z')
1517 str[0] = (ch>>8) & 255;
1525 if(!MultiByteToWideChar(cp, MB_ERR_INVALID_CHARS, str, size, &wide, 1))
1528 lower = tolowerW(wide);
1532 WideCharToMultiByte(cp, 0, &lower, 1, str, 2, NULL, NULL);
1534 return str[0] + (str[1]<<8);
1538 /* ?do_tolower@?$ctype@D@std@@MBEDD@Z */
1539 /* ?do_tolower@?$ctype@D@std@@MEBADD@Z */
1540 #define call_ctype_char_do_tolower_ch(this, ch) CALL_VTBL_FUNC(this, 8, \
1541 char, (const ctype_char*, char), (this, ch))
1542 DEFINE_THISCALL_WRAPPER(ctype_char_do_tolower_ch, 8)
1543 char __thiscall ctype_char_do_tolower_ch(const ctype_char *this, char ch)
1545 TRACE("(%p %c)\n", this, ch);
1546 return _Tolower(ch, &this->ctype);
1549 /* ?do_tolower@?$ctype@D@std@@MBEPBDPADPBD@Z */
1550 /* ?do_tolower@?$ctype@D@std@@MEBAPEBDPEADPEBD@Z */
1551 #define call_ctype_char_do_tolower(this, first, last) CALL_VTBL_FUNC(this, 4, \
1552 const char*, (const ctype_char*, char*, const char*), (this, first, last))
1553 DEFINE_THISCALL_WRAPPER(ctype_char_do_tolower, 12)
1554 const char* __thiscall ctype_char_do_tolower(const ctype_char *this, char *first, const char *last)
1556 TRACE("(%p %p %p)\n", this, first, last);
1557 for(; first<last; first++)
1558 *first = _Tolower(*first, &this->ctype);
1562 /* ?tolower@?$ctype@D@std@@QBEDD@Z */
1563 /* ?tolower@?$ctype@D@std@@QEBADD@Z */
1564 DEFINE_THISCALL_WRAPPER(ctype_char_tolower_ch, 8)
1565 char __thiscall ctype_char_tolower_ch(const ctype_char *this, char ch)
1567 TRACE("(%p %c)\n", this, ch);
1568 return call_ctype_char_do_tolower_ch(this, ch);
1571 /* ?tolower@?$ctype@D@std@@QBEPBDPADPBD@Z */
1572 /* ?tolower@?$ctype@D@std@@QEBAPEBDPEADPEBD@Z */
1573 DEFINE_THISCALL_WRAPPER(ctype_char_tolower, 12)
1574 const char* __thiscall ctype_char_tolower(const ctype_char *this, char *first, const char *last)
1576 TRACE("(%p %p %p)\n", this, first, last);
1577 return call_ctype_char_do_tolower(this, first, last);
1581 int __cdecl _Toupper(int ch, const _Ctypevec *ctype)
1585 TRACE("%d %p\n", ch, ctype);
1590 cp = ___lc_codepage_func();
1592 /* Don't convert to unicode in case of C locale */
1594 if(ch>='a' && ch<='z')
1603 str[0] = (ch>>8) & 255;
1611 if(!MultiByteToWideChar(cp, MB_ERR_INVALID_CHARS, str, size, &wide, 1))
1614 upper = toupperW(wide);
1618 WideCharToMultiByte(cp, 0, &upper, 1, str, 2, NULL, NULL);
1620 return str[0] + (str[1]<<8);
1624 /* ?do_toupper@?$ctype@D@std@@MBEDD@Z */
1625 /* ?do_toupper@?$ctype@D@std@@MEBADD@Z */
1626 #define call_ctype_char_do_toupper_ch(this, ch) CALL_VTBL_FUNC(this, 16, \
1627 char, (const ctype_char*, char), (this, ch))
1628 DEFINE_THISCALL_WRAPPER(ctype_char_do_toupper_ch, 8)
1629 char __thiscall ctype_char_do_toupper_ch(const ctype_char *this, char ch)
1631 TRACE("(%p %c)\n", this, ch);
1632 return _Toupper(ch, &this->ctype);
1635 /* ?do_toupper@?$ctype@D@std@@MBEPBDPADPBD@Z */
1636 /* ?do_toupper@?$ctype@D@std@@MEBAPEBDPEADPEBD@Z */
1637 #define call_ctype_char_do_toupper(this, first, last) CALL_VTBL_FUNC(this, 12, \
1638 const char*, (const ctype_char*, char*, const char*), (this, first, last))
1639 DEFINE_THISCALL_WRAPPER(ctype_char_do_toupper, 12)
1640 const char* __thiscall ctype_char_do_toupper(const ctype_char *this,
1641 char *first, const char *last)
1643 TRACE("(%p %p %p)\n", this, first, last);
1644 for(; first<last; first++)
1645 *first = _Toupper(*first, &this->ctype);
1649 /* ?toupper@?$ctype@D@std@@QBEDD@Z */
1650 /* ?toupper@?$ctype@D@std@@QEBADD@Z */
1651 DEFINE_THISCALL_WRAPPER(ctype_char_toupper_ch, 8)
1652 char __thiscall ctype_char_toupper_ch(const ctype_char *this, char ch)
1654 TRACE("(%p %c)\n", this, ch);
1655 return call_ctype_char_do_toupper_ch(this, ch);
1658 /* ?toupper@?$ctype@D@std@@QBEPBDPADPBD@Z */
1659 /* ?toupper@?$ctype@D@std@@QEBAPEBDPEADPEBD@Z */
1660 DEFINE_THISCALL_WRAPPER(ctype_char_toupper, 12)
1661 const char* __thiscall ctype_char_toupper(const ctype_char *this, char *first, const char *last)
1663 TRACE("(%p %p %p)\n", this, first, last);
1664 return call_ctype_char_do_toupper(this, first, last);
1667 /* ?is@?$ctype@D@std@@QBE_NFD@Z */
1668 /* ?is@?$ctype@D@std@@QEBA_NFD@Z */
1669 DEFINE_THISCALL_WRAPPER(ctype_char_is_ch, 12)
1670 MSVCP_bool __thiscall ctype_char_is_ch(const ctype_char *this, short mask, char ch)
1672 TRACE("(%p %x %c)\n", this, mask, ch);
1673 return (this->ctype.table[(unsigned char)ch] & mask) != 0;
1676 /* ?is@?$ctype@D@std@@QBEPBDPBD0PAF@Z */
1677 /* ?is@?$ctype@D@std@@QEBAPEBDPEBD0PEAF@Z */
1678 DEFINE_THISCALL_WRAPPER(ctype_char_is, 16)
1679 const char* __thiscall ctype_char_is(const ctype_char *this, const char *first, const char *last, short *dest)
1681 TRACE("(%p %p %p %p)\n", this, first, last, dest);
1682 for(; first<last; first++)
1683 *dest++ = this->ctype.table[(unsigned char)*first];
1687 /* ?scan_is@?$ctype@D@std@@QBEPBDFPBD0@Z */
1688 /* ?scan_is@?$ctype@D@std@@QEBAPEBDFPEBD0@Z */
1689 DEFINE_THISCALL_WRAPPER(ctype_char_scan_is, 16)
1690 const char* __thiscall ctype_char_scan_is(const ctype_char *this, short mask, const char *first, const char *last)
1692 TRACE("(%p %x %p %p)\n", this, mask, first, last);
1693 for(; first<last; first++)
1694 if(!ctype_char_is_ch(this, mask, *first))
1699 /* ?scan_not@?$ctype@D@std@@QBEPBDFPBD0@Z */
1700 /* ?scan_not@?$ctype@D@std@@QEBAPEBDFPEBD0@Z */
1701 DEFINE_THISCALL_WRAPPER(ctype_char_scan_not, 16)
1702 const char* __thiscall ctype_char_scan_not(const ctype_char *this, short mask, const char *first, const char *last)
1704 TRACE("(%p %x %p %p)\n", this, mask, first, last);
1705 for(; first<last; first++)
1706 if(ctype_char_is_ch(this, mask, *first))
1711 /* ?table@?$ctype@D@std@@IBEPBFXZ */
1712 /* ?table@?$ctype@D@std@@IEBAPEBFXZ */
1713 DEFINE_THISCALL_WRAPPER(ctype_char_table, 4)
1714 const short* __thiscall ctype_char_table(const ctype_char *this)
1716 TRACE("(%p)\n", this);
1717 return this->ctype.table;
1720 /* ?id@?$ctype@_W@std@@2V0locale@2@A */
1721 locale_id ctype_wchar_id = {0};
1722 /* ?id@?$ctype@G@std@@2V0locale@2@A */
1723 locale_id ctype_short_id = {0};
1725 /* ??_7?$ctype@_W@std@@6B@ */
1726 extern const vtable_ptr MSVCP_ctype_wchar_vtable;
1727 /* ??_7?$ctype@G@std@@6B@ */
1728 extern const vtable_ptr MSVCP_ctype_short_vtable;
1730 /* ?_Id_func@?$ctype@_W@std@@SAAAVid@locale@2@XZ */
1731 /* ?_Id_func@?$ctype@_W@std@@SAAEAVid@locale@2@XZ */
1732 locale_id* __cdecl ctype_wchar__Id_func(void)
1735 return &ctype_wchar_id;
1738 /* ?_Id_func@?$ctype@G@std@@SAAAVid@locale@2@XZ */
1739 /* ?_Id_func@?$ctype@G@std@@SAAEAVid@locale@2@XZ */
1740 locale_id* __cdecl ctype_short__Id_func(void)
1743 return &ctype_short_id;
1746 /* ?_Init@?$ctype@_W@std@@IAEXABV_Locinfo@2@@Z */
1747 /* ?_Init@?$ctype@_W@std@@IEAAXAEBV_Locinfo@2@@Z */
1748 /* ?_Init@?$ctype@G@std@@IAEXABV_Locinfo@2@@Z */
1749 /* ?_Init@?$ctype@G@std@@IEAAXAEBV_Locinfo@2@@Z */
1750 DEFINE_THISCALL_WRAPPER(ctype_wchar__Init, 8)
1751 void __thiscall ctype_wchar__Init(ctype_wchar *this, _Locinfo *locinfo)
1753 TRACE("(%p %p)\n", this, locinfo);
1754 _Locinfo__Getctype(locinfo, &this->ctype);
1755 _Locinfo__Getcvt(locinfo, &this->cvt);
1758 /* ??0?$ctype@_W@std@@QAE@ABV_Locinfo@1@I@Z */
1759 /* ??0?$ctype@_W@std@@QEAA@AEBV_Locinfo@1@_K@Z */
1760 DEFINE_THISCALL_WRAPPER(ctype_wchar_ctor_locinfo, 12)
1761 ctype_wchar* __thiscall ctype_wchar_ctor_locinfo(ctype_wchar *this,
1762 _Locinfo *locinfo, MSVCP_size_t refs)
1764 TRACE("(%p %p %lu)\n", this, locinfo, refs);
1765 ctype_base_ctor_refs(&this->base, refs);
1766 this->base.facet.vtable = &MSVCP_ctype_wchar_vtable;
1767 ctype_wchar__Init(this, locinfo);
1771 /* ??0?$ctype@G@std@@QAE@ABV_Locinfo@1@I@Z */
1772 /* ??0?$ctype@G@std@@QEAA@AEBV_Locinfo@1@_K@Z */
1773 DEFINE_THISCALL_WRAPPER(ctype_short_ctor_locinfo, 12)
1774 ctype_wchar* __thiscall ctype_short_ctor_locinfo(ctype_wchar *this,
1775 _Locinfo *locinfo, MSVCP_size_t refs)
1777 ctype_wchar *ret = ctype_wchar_ctor_locinfo(this, locinfo, refs);
1778 this->base.facet.vtable = &MSVCP_ctype_short_vtable;
1782 /* ??0?$ctype@_W@std@@QAE@I@Z */
1783 /* ??0?$ctype@_W@std@@QEAA@_K@Z */
1784 DEFINE_THISCALL_WRAPPER(ctype_wchar_ctor_refs, 8)
1785 ctype_wchar* __thiscall ctype_wchar_ctor_refs(ctype_wchar *this, MSVCP_size_t refs)
1789 TRACE("(%p %lu)\n", this, refs);
1791 ctype_base_ctor_refs(&this->base, refs);
1792 this->base.facet.vtable = &MSVCP_ctype_wchar_vtable;
1794 _Locinfo_ctor(&locinfo);
1795 ctype_wchar__Init(this, &locinfo);
1796 _Locinfo_dtor(&locinfo);
1800 /* ??0?$ctype@G@std@@QAE@I@Z */
1801 /* ??0?$ctype@G@std@@QEAA@_K@Z */
1802 DEFINE_THISCALL_WRAPPER(ctype_short_ctor_refs, 8)
1803 ctype_wchar* __thiscall ctype_short_ctor_refs(ctype_wchar *this, MSVCP_size_t refs)
1805 ctype_wchar *ret = ctype_wchar_ctor_refs(this, refs);
1806 this->base.facet.vtable = &MSVCP_ctype_short_vtable;
1810 /* ??0?$ctype@G@std@@IAE@PBDI@Z */
1811 /* ??0?$ctype@G@std@@IEAA@PEBD_K@Z */
1812 DEFINE_THISCALL_WRAPPER(ctype_short_ctor_name, 12)
1813 ctype_wchar* __thiscall ctype_short_ctor_name(ctype_wchar *this,
1814 const char *name, MSVCP_size_t refs)
1818 TRACE("(%p %s %lu)\n", this, debugstr_a(name), refs);
1820 ctype_base_ctor_refs(&this->base, refs);
1821 this->base.facet.vtable = &MSVCP_ctype_short_vtable;
1823 _Locinfo_ctor_cstr(&locinfo, name);
1824 ctype_wchar__Init(this, &locinfo);
1825 _Locinfo_dtor(&locinfo);
1829 /* ??_F?$ctype@_W@std@@QAEXXZ */
1830 /* ??_F?$ctype@_W@std@@QEAAXXZ */
1831 DEFINE_THISCALL_WRAPPER(ctype_wchar_ctor, 4)
1832 ctype_wchar* __thiscall ctype_wchar_ctor(ctype_wchar *this)
1834 TRACE("(%p)\n", this);
1835 return ctype_short_ctor_refs(this, 0);
1838 /* ??_F?$ctype@G@std@@QAEXXZ */
1839 /* ??_F?$ctype@G@std@@QEAAXXZ */
1840 DEFINE_THISCALL_WRAPPER(ctype_short_ctor, 4)
1841 ctype_wchar* __thiscall ctype_short_ctor(ctype_wchar *this)
1843 ctype_wchar *ret = ctype_wchar_ctor(this);
1844 this->base.facet.vtable = &MSVCP_ctype_short_vtable;
1848 /* ??1?$ctype@_W@std@@MAE@XZ */
1849 /* ??1?$ctype@_W@std@@MEAA@XZ */
1850 /* ??1?$ctype@G@std@@MAE@XZ */
1851 /* ??1?$ctype@G@std@@MEAA@XZ */
1852 DEFINE_THISCALL_WRAPPER(ctype_wchar_dtor, 4)
1853 void __thiscall ctype_wchar_dtor(ctype_wchar *this)
1855 TRACE("(%p)\n", this);
1856 if(this->ctype.delfl)
1857 free((void*)this->ctype.table);
1860 DEFINE_THISCALL_WRAPPER(MSVCP_ctype_wchar_vector_dtor, 8)
1861 ctype_wchar* __thiscall MSVCP_ctype_wchar_vector_dtor(ctype_wchar *this, unsigned int flags)
1863 TRACE("(%p %x)\n", this, flags);
1865 /* we have an array, with the number of elements stored before the first object */
1866 int i, *ptr = (int *)this-1;
1868 for(i=*ptr-1; i>=0; i--)
1869 ctype_wchar_dtor(this+i);
1870 MSVCRT_operator_delete(ptr);
1872 ctype_wchar_dtor(this);
1874 MSVCRT_operator_delete(this);
1880 DEFINE_THISCALL_WRAPPER(MSVCP_ctype_short_vector_dtor, 8)
1881 ctype_wchar* __thiscall MSVCP_ctype_short_vector_dtor(ctype_wchar *this, unsigned int flags)
1883 return MSVCP_ctype_wchar_vector_dtor(this, flags);
1887 int __cdecl _Wcrtomb(char *s, wchar_t wch, int *state, const _Cvtvec *cvt)
1892 TRACE("%p %d %p %p\n", s, wch, state, cvt);
1897 cp = ___lc_codepage_func();
1909 size = WideCharToMultiByte(cp, 0, &wch, 1, s, MB_LEN_MAX, NULL, &def);
1918 /* ?_Donarrow@?$ctype@_W@std@@IBED_WD@Z */
1919 /* ?_Donarrow@?$ctype@_W@std@@IEBAD_WD@Z */
1920 /* ?_Donarrow@?$ctype@G@std@@IBEDGD@Z */
1921 /* ?_Donarrow@?$ctype@G@std@@IEBADGD@Z */
1922 DEFINE_THISCALL_WRAPPER(ctype_wchar__Donarrow, 12)
1923 char __thiscall ctype_wchar__Donarrow(const ctype_wchar *this, wchar_t ch, char dflt)
1925 char buf[MB_LEN_MAX];
1927 TRACE("(%p %d %d)\n", this, ch, dflt);
1929 return _Wcrtomb(buf, ch, NULL, &this->cvt)==1 ? buf[0] : dflt;
1932 /* ?do_narrow@?$ctype@_W@std@@MBED_WD@Z */
1933 /* ?do_narrow@?$ctype@_W@std@@MEBAD_WD@Z */
1934 /* ?do_narrow@?$ctype@G@std@@MBEDGD@Z */
1935 /* ?do_narrow@?$ctype@G@std@@MEBADGD@Z */
1936 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_narrow_ch, 12)
1937 #define call_ctype_wchar_do_narrow_ch(this, ch, dflt) CALL_VTBL_FUNC(this, 52, \
1938 char, (const ctype_wchar*, wchar_t, char), (this, ch, dflt))
1939 char __thiscall ctype_wchar_do_narrow_ch(const ctype_wchar *this, wchar_t ch, char dflt)
1941 return ctype_wchar__Donarrow(this, ch, dflt);
1944 /* ?do_narrow@?$ctype@_W@std@@MBEPB_WPB_W0DPAD@Z */
1945 /* ?do_narrow@?$ctype@_W@std@@MEBAPEB_WPEB_W0DPEAD@Z */
1946 /* ?do_narrow@?$ctype@G@std@@MBEPBGPBG0DPAD@Z */
1947 /* ?do_narrow@?$ctype@G@std@@MEBAPEBGPEBG0DPEAD@Z */
1948 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_narrow, 20)
1949 #define call_ctype_wchar_do_narrow(this, first, last, dflt, dest) CALL_VTBL_FUNC(this, 48, \
1950 const wchar_t*, (const ctype_wchar*, const wchar_t*, const wchar_t*, char, char*), \
1951 (this, first, last, dflt, dest))
1952 const wchar_t* __thiscall ctype_wchar_do_narrow(const ctype_wchar *this,
1953 const wchar_t *first, const wchar_t *last, char dflt, char *dest)
1955 TRACE("(%p %p %p %d %p)\n", this, first, last, dflt, dest);
1956 for(; first<last; first++)
1957 *dest++ = ctype_wchar__Donarrow(this, *first, dflt);
1961 /* ?_Do_narrow_s@?$ctype@_W@std@@MBEPB_WPB_W0DPADI@Z */
1962 /* ?_Do_narrow_s@?$ctype@_W@std@@MEBAPEB_WPEB_W0DPEAD_K@Z */
1963 /* ?_Do_narrow_s@?$ctype@G@std@@MBEPBGPBG0DPADI@Z */
1964 /* ?_Do_narrow_s@?$ctype@G@std@@MEBAPEBGPEBG0DPEAD_K@Z */
1965 DEFINE_THISCALL_WRAPPER(ctype_wchar__Do_narrow_s, 24)
1966 #define call_ctype_wchar__Do_narrow_s(this, first, last, dflt, dest, size) CALL_VTBL_FUNC(this, 56, \
1967 const wchar_t*, (const ctype_wchar*, const wchar_t*, const wchar_t*, char, char*, MSVCP_size_t), \
1968 (this, first, last, dflt, dest, size))
1969 const wchar_t* __thiscall ctype_wchar__Do_narrow_s(const ctype_wchar *this,
1970 const wchar_t *first, const wchar_t *last, char dflt, char *dest, MSVCP_size_t size)
1972 TRACE("(%p %p %p %d %p %lu)\n", this, first, last, dflt, dest, size);
1973 /* This function converts all multi-byte characters to dflt,
1974 * thanks to it result size is known before converting */
1975 if(last-first > size)
1977 return ctype_wchar_do_narrow(this, first, last, dflt, dest);
1980 /* ?narrow@?$ctype@_W@std@@QBED_WD@Z */
1981 /* ?narrow@?$ctype@_W@std@@QEBAD_WD@Z */
1982 /* ?narrow@?$ctype@G@std@@QBEDGD@Z */
1983 /* ?narrow@?$ctype@G@std@@QEBADGD@Z */
1984 DEFINE_THISCALL_WRAPPER(ctype_wchar_narrow_ch, 12)
1985 char __thiscall ctype_wchar_narrow_ch(const ctype_wchar *this, wchar_t ch, char dflt)
1987 TRACE("(%p %d %d)\n", this, ch, dflt);
1988 return call_ctype_wchar_do_narrow_ch(this, ch, dflt);
1991 /* ?narrow@?$ctype@_W@std@@QBEPB_WPB_W0DPAD@Z */
1992 /* ?narrow@?$ctype@_W@std@@QEBAPEB_WPEB_W0DPEAD@Z */
1993 /* ?narrow@?$ctype@G@std@@QBEPBGPBG0DPAD@Z */
1994 /* ?narrow@?$ctype@G@std@@QEBAPEBGPEBG0DPEAD@Z */
1995 DEFINE_THISCALL_WRAPPER(ctype_wchar_narrow, 20)
1996 const wchar_t* __thiscall ctype_wchar_narrow(const ctype_wchar *this,
1997 const wchar_t *first, const wchar_t *last, char dflt, char *dest)
1999 TRACE("(%p %p %p %d %p)\n", this, first, last, dflt, dest);
2000 return call_ctype_wchar_do_narrow(this, first, last, dflt, dest);
2003 /* ?_Narrow_s@?$ctype@_W@std@@QBEPB_WPB_W0DPADI@Z */
2004 /* ?_Narrow_s@?$ctype@_W@std@@QEBAPEB_WPEB_W0DPEAD_K@Z */
2005 /* ?_Narrow_s@?$ctype@G@std@@QBEPBGPBG0DPADI@Z */
2006 /* ?_Narrow_s@?$ctype@G@std@@QEBAPEBGPEBG0DPEAD_K@Z */
2007 DEFINE_THISCALL_WRAPPER(ctype_wchar__Narrow_s, 24)
2008 const wchar_t* __thiscall ctype_wchar__Narrow_s(const ctype_wchar *this, const wchar_t *first,
2009 const wchar_t *last, char dflt, char *dest, MSVCP_size_t size)
2011 TRACE("(%p %p %p %d %p %lu)\n", this, first, last, dflt, dest, size);
2012 return call_ctype_wchar__Do_narrow_s(this, first, last, dflt, dest, size);
2016 int __cdecl _Mbrtowc(wchar_t *out, const char *in, MSVCP_size_t len, int *state, const _Cvtvec *cvt)
2022 TRACE("(%p %p %lu %p %p)\n", out, in, len, state, cvt);
2030 cp = ___lc_codepage_func();
2034 *out = (unsigned char)*in;
2041 ((char*)state)[1] = *in;
2043 if(!MultiByteToWideChar(cp, MB_ERR_INVALID_CHARS, (char*)state, 2, out, out ? 1 : 0)) {
2053 GetCPInfo(cp, &cp_info);
2055 for(i=0; i<MAX_LEADBYTES; i+=2) {
2056 if(!cp_info.LeadByte[i+1])
2058 if((unsigned char)*in>=cp_info.LeadByte[i] && (unsigned char)*in<=cp_info.LeadByte[i+1]) {
2066 *state = (unsigned char)*in;
2070 if(!MultiByteToWideChar(cp, MB_ERR_INVALID_CHARS, in, 2, out, out ? 1 : 0)) {
2077 if(!MultiByteToWideChar(cp, MB_ERR_INVALID_CHARS, in, 1, out, out ? 1 : 0)) {
2084 /* ?_Dowiden@?$ctype@_W@std@@IBE_WD@Z */
2085 /* ?_Dowiden@?$ctype@_W@std@@IEBA_WD@Z */
2086 /* ?_Dowiden@?$ctype@G@std@@IBEGD@Z */
2087 /* ?_Dowiden@?$ctype@G@std@@IEBAGD@Z */
2088 DEFINE_THISCALL_WRAPPER(ctype_wchar__Dowiden, 8)
2089 wchar_t __thiscall ctype_wchar__Dowiden(const ctype_wchar *this, char ch)
2093 TRACE("(%p %d)\n", this, ch);
2094 return _Mbrtowc(&ret, &ch, 1, &state, &this->cvt)<0 ? WEOF : ret;
2097 /* ?do_widen@?$ctype@_W@std@@MBE_WD@Z */
2098 /* ?do_widen@?$ctype@_W@std@@MEBA_WD@Z */
2099 /* ?do_widen@?$ctype@G@std@@MBEGD@Z */
2100 /* ?do_widen@?$ctype@G@std@@MEBAGD@Z */
2101 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_widen_ch, 8)
2102 #define call_ctype_wchar_do_widen_ch(this, ch) CALL_VTBL_FUNC(this, 40, \
2103 wchar_t, (const ctype_wchar*, char), (this, ch))
2104 wchar_t __thiscall ctype_wchar_do_widen_ch(const ctype_wchar *this, char ch)
2106 return ctype_wchar__Dowiden(this, ch);
2109 /* ?do_widen@?$ctype@_W@std@@MBEPBDPBD0PA_W@Z */
2110 /* ?do_widen@?$ctype@_W@std@@MEBAPEBDPEBD0PEA_W@Z */
2111 /* ?do_widen@?$ctype@G@std@@MBEPBDPBD0PAG@Z */
2112 /* ?do_widen@?$ctype@G@std@@MEBAPEBDPEBD0PEAG@Z */
2113 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_widen, 16)
2114 #define call_ctype_wchar_do_widen(this, first, last, dest) CALL_VTBL_FUNC(this, 36, \
2115 const char*, (const ctype_wchar*, const char*, const char*, wchar_t*), \
2116 (this, first, last, dest))
2117 const char* __thiscall ctype_wchar_do_widen(const ctype_wchar *this,
2118 const char *first, const char *last, wchar_t *dest)
2120 TRACE("(%p %p %p %p)\n", this, first, last, dest);
2121 for(; first<last; first++)
2122 *dest++ = ctype_wchar__Dowiden(this, *first);
2126 /* ?_Do_widen_s@?$ctype@_W@std@@MBEPBDPBD0PA_WI@Z */
2127 /* ?_Do_widen_s@?$ctype@_W@std@@MEBAPEBDPEBD0PEA_W_K@Z */
2128 /* ?_Do_widen_s@?$ctype@G@std@@MBEPBDPBD0PAGI@Z */
2129 /* ?_Do_widen_s@?$ctype@G@std@@MEBAPEBDPEBD0PEAG_K@Z */
2130 DEFINE_THISCALL_WRAPPER(ctype_wchar__Do_widen_s, 20)
2131 #define call_ctype_wchar__Do_widen_s(this, first, last, dest, size) CALL_VTBL_FUNC(this, 44, \
2132 const char*, (const ctype_wchar*, const char*, const char*, wchar_t*, MSVCP_size_t), \
2133 (this, first, last, dest, size))
2134 const char* __thiscall ctype_wchar__Do_widen_s(const ctype_wchar *this,
2135 const char *first, const char *last, wchar_t *dest, MSVCP_size_t size)
2137 TRACE("(%p %p %p %p %lu)\n", this, first, last, dest, size);
2138 /* This function converts all multi-byte characters to WEOF,
2139 * thanks to it result size is known before converting */
2140 if(size < last-first)
2142 return ctype_wchar_do_widen(this, first, last, dest);
2145 /* ?widen@?$ctype@_W@std@@QBE_WD@Z */
2146 /* ?widen@?$ctype@_W@std@@QEBA_WD@Z */
2147 /* ?widen@?$ctype@G@std@@QBEGD@Z */
2148 /* ?widen@?$ctype@G@std@@QEBAGD@Z */
2149 DEFINE_THISCALL_WRAPPER(ctype_wchar_widen_ch, 8)
2150 wchar_t __thiscall ctype_wchar_widen_ch(const ctype_wchar *this, char ch)
2152 TRACE("(%p %d)\n", this, ch);
2153 return call_ctype_wchar_do_widen_ch(this, ch);
2156 /* ?widen@?$ctype@_W@std@@QBEPBDPBD0PA_W@Z */
2157 /* ?widen@?$ctype@_W@std@@QEBAPEBDPEBD0PEA_W@Z */
2158 /* ?widen@?$ctype@G@std@@QBEPBDPBD0PAG@Z */
2159 /* ?widen@?$ctype@G@std@@QEBAPEBDPEBD0PEAG@Z */
2160 DEFINE_THISCALL_WRAPPER(ctype_wchar_widen, 16)
2161 const char* __thiscall ctype_wchar_widen(const ctype_wchar *this,
2162 const char *first, const char *last, wchar_t *dest)
2164 TRACE("(%p %p %p %p)\n", this, first, last, dest);
2165 return call_ctype_wchar_do_widen(this, first, last, dest);
2168 /* ?_Widen_s@?$ctype@_W@std@@QBEPBDPBD0PA_WI@Z */
2169 /* ?_Widen_s@?$ctype@_W@std@@QEBAPEBDPEBD0PEA_W_K@Z */
2170 /* ?_Widen_s@?$ctype@G@std@@QBEPBDPBD0PAGI@Z */
2171 /* ?_Widen_s@?$ctype@G@std@@QEBAPEBDPEBD0PEAG_K@Z */
2172 DEFINE_THISCALL_WRAPPER(ctype_wchar__Widen_s, 20)
2173 const char* __thiscall ctype_wchar__Widen_s(const ctype_wchar *this,
2174 const char *first, const char *last, wchar_t *dest, MSVCP_size_t size)
2176 TRACE("(%p %p %p %p %lu)\n", this, first, last, dest, size);
2177 return call_ctype_wchar__Do_widen_s(this, first, last, dest, size);
2180 /* ?_Getcat@?$ctype@_W@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
2181 /* ?_Getcat@?$ctype@_W@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
2182 MSVCP_size_t __cdecl ctype_wchar__Getcat(const locale_facet **facet, const locale *loc)
2184 TRACE("(%p %p)\n", facet, loc);
2186 if(facet && !*facet) {
2189 *facet = MSVCRT_operator_new(sizeof(ctype_wchar));
2191 ERR("Out of memory\n");
2192 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
2196 _Locinfo_ctor_cstr(&locinfo, MSVCP_basic_string_char_c_str(&loc->ptr->name));
2197 ctype_wchar_ctor_locinfo((ctype_wchar*)*facet, &locinfo, 0);
2198 _Locinfo_dtor(&locinfo);
2204 /* ?_Getcat@?$ctype@G@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
2205 /* ?_Getcat@?$ctype@G@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
2206 MSVCP_size_t __cdecl ctype_short__Getcat(const locale_facet **facet, const locale *loc)
2208 if(facet && !*facet) {
2209 ctype_wchar__Getcat(facet, loc);
2210 (*(locale_facet**)facet)->vtable = &MSVCP_ctype_short_vtable;
2217 wchar_t __cdecl _Towlower(wchar_t ch, const _Ctypevec *ctype)
2219 TRACE("(%d %p)\n", ch, ctype);
2220 return tolowerW(ch);
2223 /* ?do_tolower@?$ctype@_W@std@@MBE_W_W@Z */
2224 /* ?do_tolower@?$ctype@_W@std@@MEBA_W_W@Z */
2225 /* ?do_tolower@?$ctype@G@std@@MBEGG@Z */
2226 /* ?do_tolower@?$ctype@G@std@@MEBAGG@Z */
2227 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_tolower_ch, 8)
2228 #define call_ctype_wchar_do_tolower_ch(this, ch) CALL_VTBL_FUNC(this, 24, \
2229 wchar_t, (const ctype_wchar*, wchar_t), (this, ch))
2230 wchar_t __thiscall ctype_wchar_do_tolower_ch(const ctype_wchar *this, wchar_t ch)
2232 return _Towlower(ch, &this->ctype);
2235 /* ?do_tolower@?$ctype@_W@std@@MBEPB_WPA_WPB_W@Z */
2236 /* ?do_tolower@?$ctype@_W@std@@MEBAPEB_WPEA_WPEB_W@Z */
2237 /* ?do_tolower@?$ctype@G@std@@MBEPBGPAGPBG@Z */
2238 /* ?do_tolower@?$ctype@G@std@@MEBAPEBGPEAGPEBG@Z */
2239 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_tolower, 12)
2240 #define call_ctype_wchar_do_tolower(this, first, last) CALL_VTBL_FUNC(this, 20, \
2241 const wchar_t*, (const ctype_wchar*, wchar_t*, const wchar_t*), \
2242 (this, first, last))
2243 const wchar_t* __thiscall ctype_wchar_do_tolower(const ctype_wchar *this,
2244 wchar_t *first, const wchar_t *last)
2246 TRACE("(%p %p %p)\n", this, first, last);
2247 for(; first<last; first++)
2248 *first = _Towlower(*first, &this->ctype);
2252 /* ?tolower@?$ctype@_W@std@@QBE_W_W@Z */
2253 /* ?tolower@?$ctype@_W@std@@QEBA_W_W@Z */
2254 /* ?tolower@?$ctype@G@std@@QBEGG@Z */
2255 /* ?tolower@?$ctype@G@std@@QEBAGG@Z */
2256 DEFINE_THISCALL_WRAPPER(ctype_wchar_tolower_ch, 8)
2257 wchar_t __thiscall ctype_wchar_tolower_ch(const ctype_wchar *this, wchar_t ch)
2259 TRACE("(%p %d)\n", this, ch);
2260 return call_ctype_wchar_do_tolower_ch(this, ch);
2263 /* ?tolower@?$ctype@_W@std@@QBEPB_WPA_WPB_W@Z */
2264 /* ?tolower@?$ctype@_W@std@@QEBAPEB_WPEA_WPEB_W@Z */
2265 /* ?tolower@?$ctype@G@std@@QBEPBGPAGPBG@Z */
2266 /* ?tolower@?$ctype@G@std@@QEBAPEBGPEAGPEBG@Z */
2267 DEFINE_THISCALL_WRAPPER(ctype_wchar_tolower, 12)
2268 const wchar_t* __thiscall ctype_wchar_tolower(const ctype_wchar *this,
2269 wchar_t *first, const wchar_t *last)
2271 TRACE("(%p %p %p)\n", this, first, last);
2272 return call_ctype_wchar_do_tolower(this, first, last);
2276 wchar_t __cdecl _Towupper(wchar_t ch, const _Ctypevec *ctype)
2278 TRACE("(%d %p)\n", ch, ctype);
2279 return toupperW(ch);
2282 /* ?do_toupper@?$ctype@_W@std@@MBE_W_W@Z */
2283 /* ?do_toupper@?$ctype@_W@std@@MEBA_W_W@Z */
2284 /* ?do_toupper@?$ctype@G@std@@MBEGG@Z */
2285 /* ?do_toupper@?$ctype@G@std@@MEBAGG@Z */
2286 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_toupper_ch, 8)
2287 #define call_ctype_wchar_do_toupper_ch(this, ch) CALL_VTBL_FUNC(this, 32, \
2288 wchar_t, (const ctype_wchar*, wchar_t), (this, ch))
2289 wchar_t __thiscall ctype_wchar_do_toupper_ch(const ctype_wchar *this, wchar_t ch)
2291 return _Towupper(ch, &this->ctype);
2294 /* ?do_toupper@?$ctype@_W@std@@MBEPB_WPA_WPB_W@Z */
2295 /* ?do_toupper@?$ctype@_W@std@@MEBAPEB_WPEA_WPEB_W@Z */
2296 /* ?do_toupper@?$ctype@G@std@@MBEPBGPAGPBG@Z */
2297 /* ?do_toupper@?$ctype@G@std@@MEBAPEBGPEAGPEBG@Z */
2298 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_toupper, 12)
2299 #define call_ctype_wchar_do_toupper(this, first, last) CALL_VTBL_FUNC(this, 28, \
2300 const wchar_t*, (const ctype_wchar*, wchar_t*, const wchar_t*), \
2301 (this, first, last))
2302 const wchar_t* __thiscall ctype_wchar_do_toupper(const ctype_wchar *this,
2303 wchar_t *first, const wchar_t *last)
2305 TRACE("(%p %p %p)\n", this, first, last);
2306 for(; first<last; first++)
2307 *first = _Towupper(*first, &this->ctype);
2311 /* ?toupper@?$ctype@_W@std@@QBE_W_W@Z */
2312 /* ?toupper@?$ctype@_W@std@@QEBA_W_W@Z */
2313 /* ?toupper@?$ctype@G@std@@QBEGG@Z */
2314 /* ?toupper@?$ctype@G@std@@QEBAGG@Z */
2315 DEFINE_THISCALL_WRAPPER(ctype_wchar_toupper_ch, 8)
2316 wchar_t __thiscall ctype_wchar_toupper_ch(const ctype_wchar *this, wchar_t ch)
2318 TRACE("(%p %d)\n", this, ch);
2319 return call_ctype_wchar_do_toupper_ch(this, ch);
2322 /* ?toupper@?$ctype@_W@std@@QBEPB_WPA_WPB_W@Z */
2323 /* ?toupper@?$ctype@_W@std@@QEBAPEB_WPEA_WPEB_W@Z */
2324 /* ?toupper@?$ctype@G@std@@QBEPBGPAGPBG@Z */
2325 /* ?toupper@?$ctype@G@std@@QEBAPEBGPEAGPEBG@Z */
2326 DEFINE_THISCALL_WRAPPER(ctype_wchar_toupper, 12)
2327 const wchar_t* __thiscall ctype_wchar_toupper(const ctype_wchar *this,
2328 wchar_t *first, const wchar_t *last)
2330 TRACE("(%p %p %p)\n", this, first, last);
2331 return call_ctype_wchar_do_toupper(this, first, last);
2335 const wchar_t* __cdecl _Getwctypes(const wchar_t *first, const wchar_t *last,
2336 short *mask, const _Ctypevec *ctype)
2338 TRACE("(%p %p %p %p)\n", first, last, mask, ctype);
2339 GetStringTypeW(CT_CTYPE1, first, last-first, (WORD*)mask);
2344 short __cdecl _Getwctype(wchar_t ch, const _Ctypevec *ctype)
2347 _Getwctypes(&ch, &ch+1, &mask, ctype);
2351 /* ?do_is@?$ctype@_W@std@@MBE_NF_W@Z */
2352 /* ?do_is@?$ctype@_W@std@@MEBA_NF_W@Z */
2353 /* ?do_is@?$ctype@G@std@@MBE_NFG@Z */
2354 /* ?do_is@?$ctype@G@std@@MEBA_NFG@Z */
2355 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_is_ch, 12)
2356 #define call_ctype_wchar_do_is_ch(this, mask, ch) CALL_VTBL_FUNC(this, 8, \
2357 MSVCP_bool, (const ctype_wchar*, short, wchar_t), (this, mask, ch))
2358 MSVCP_bool __thiscall ctype_wchar_do_is_ch(const ctype_wchar *this, short mask, wchar_t ch)
2360 TRACE("(%p %x %d)\n", this, mask, ch);
2361 return (_Getwctype(ch, &this->ctype) & mask) != 0;
2364 /* ?do_is@?$ctype@_W@std@@MBEPB_WPB_W0PAF@Z */
2365 /* ?do_is@?$ctype@_W@std@@MEBAPEB_WPEB_W0PEAF@Z */
2366 /* ?do_is@?$ctype@G@std@@MBEPBGPBG0PAF@Z */
2367 /* ?do_is@?$ctype@G@std@@MEBAPEBGPEBG0PEAF@Z */
2368 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_is, 16)
2369 #define call_ctype_wchar_do_is(this, first, last, dest) CALL_VTBL_FUNC(this, 4, \
2370 const wchar_t*, (const ctype_wchar*, const wchar_t*, const wchar_t*, short*), \
2371 (this, first, last, dest))
2372 const wchar_t* __thiscall ctype_wchar_do_is(const ctype_wchar *this,
2373 const wchar_t *first, const wchar_t *last, short *dest)
2375 TRACE("(%p %p %p %p)\n", this, first, last, dest);
2376 return _Getwctypes(first, last, dest, &this->ctype);
2379 /* ?is@?$ctype@_W@std@@QBE_NF_W@Z */
2380 /* ?is@?$ctype@_W@std@@QEBA_NF_W@Z */
2381 /* ?is@?$ctype@G@std@@QBE_NFG@Z */
2382 /* ?is@?$ctype@G@std@@QEBA_NFG@Z */
2383 DEFINE_THISCALL_WRAPPER(ctype_wchar_is_ch, 12)
2384 MSVCP_bool __thiscall ctype_wchar_is_ch(const ctype_wchar *this, short mask, wchar_t ch)
2386 TRACE("(%p %x %d)\n", this, mask, ch);
2387 return call_ctype_wchar_do_is_ch(this, mask, ch);
2390 /* ?is@?$ctype@_W@std@@QBEPB_WPB_W0PAF@Z */
2391 /* ?is@?$ctype@_W@std@@QEBAPEB_WPEB_W0PEAF@Z */
2392 /* ?is@?$ctype@G@std@@QBEPBGPBG0PAF@Z */
2393 /* ?is@?$ctype@G@std@@QEBAPEBGPEBG0PEAF@Z */
2394 DEFINE_THISCALL_WRAPPER(ctype_wchar_is, 16)
2395 const wchar_t* __thiscall ctype_wchar_is(const ctype_wchar *this,
2396 const wchar_t *first, const wchar_t *last, short *dest)
2398 TRACE("(%p %p %p %p)\n", this, first, last, dest);
2399 return call_ctype_wchar_do_is(this, first, last, dest);
2402 /* ?do_scan_is@?$ctype@_W@std@@MBEPB_WFPB_W0@Z */
2403 /* ?do_scan_is@?$ctype@_W@std@@MEBAPEB_WFPEB_W0@Z */
2404 /* ?do_scan_is@?$ctype@G@std@@MBEPBGFPBG0@Z */
2405 /* ?do_scan_is@?$ctype@G@std@@MEBAPEBGFPEBG0@Z */
2406 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_scan_is, 16)
2407 #define call_ctype_wchar_do_scan_is(this, mask, first, last) CALL_VTBL_FUNC(this, 12, \
2408 const wchar_t*, (const ctype_wchar*, short, const wchar_t*, const wchar_t*), \
2409 (this, mask, first, last))
2410 const wchar_t* __thiscall ctype_wchar_do_scan_is(const ctype_wchar *this,
2411 short mask, const wchar_t *first, const wchar_t *last)
2413 TRACE("(%p %d %p %p)\n", this, mask, first, last);
2414 for(; first<last; first++)
2415 if(!ctype_wchar_is_ch(this, mask, *first))
2420 /* ?scan_is@?$ctype@_W@std@@QBEPB_WFPB_W0@Z */
2421 /* ?scan_is@?$ctype@_W@std@@QEBAPEB_WFPEB_W0@Z */
2422 /* ?scan_is@?$ctype@G@std@@QBEPBGFPBG0@Z */
2423 /* ?scan_is@?$ctype@G@std@@QEBAPEBGFPEBG0@Z */
2424 DEFINE_THISCALL_WRAPPER(ctype_wchar_scan_is, 16)
2425 const wchar_t* __thiscall ctype_wchar_scan_is(const ctype_wchar *this,
2426 short mask, const wchar_t *first, const wchar_t *last)
2428 TRACE("(%p %x %p %p)\n", this, mask, first, last);
2429 return call_ctype_wchar_do_scan_is(this, mask, first, last);
2432 /* ?do_scan_not@?$ctype@_W@std@@MBEPB_WFPB_W0@Z */
2433 /* ?do_scan_not@?$ctype@_W@std@@MEBAPEB_WFPEB_W0@Z */
2434 /* ?do_scan_not@?$ctype@G@std@@MBEPBGFPBG0@Z */
2435 /* ?do_scan_not@?$ctype@G@std@@MEBAPEBGFPEBG0@Z */
2436 DEFINE_THISCALL_WRAPPER(ctype_wchar_do_scan_not, 16)
2437 #define call_ctype_wchar_do_scan_not(this, mask, first, last) CALL_VTBL_FUNC(this, 16, \
2438 const wchar_t*, (const ctype_wchar*, short, const wchar_t*, const wchar_t*), \
2439 (this, mask, first, last))
2440 const wchar_t* __thiscall ctype_wchar_do_scan_not(const ctype_wchar *this,
2441 short mask, const wchar_t *first, const wchar_t *last)
2443 TRACE("(%p %x %p %p)\n", this, mask, first, last);
2444 for(; first<last; first++)
2445 if(ctype_wchar_is_ch(this, mask, *first))
2450 /* ?scan_not@?$ctype@_W@std@@QBEPB_WFPB_W0@Z */
2451 /* ?scan_not@?$ctype@_W@std@@QEBAPEB_WFPEB_W0@Z */
2452 /* ?scan_not@?$ctype@G@std@@QBEPBGFPBG0@Z */
2453 /* ?scan_not@?$ctype@G@std@@QEBAPEBGFPEBG0@Z */
2454 DEFINE_THISCALL_WRAPPER(ctype_wchar_scan_not, 16)
2455 const wchar_t* __thiscall ctype_wchar_scan_not(const ctype_wchar *this,
2456 short mask, const wchar_t *first, const wchar_t *last)
2458 TRACE("(%p %x %p %p)\n", this, mask, first, last);
2459 return call_ctype_wchar_do_scan_not(this, mask, first, last);
2462 /* ??_7codecvt_base@std@@6B@ */
2463 extern const vtable_ptr MSVCP_codecvt_base_vtable;
2465 /* ??0codecvt_base@std@@QAE@I@Z */
2466 /* ??0codecvt_base@std@@QEAA@_K@Z */
2467 DEFINE_THISCALL_WRAPPER(codecvt_base_ctor_refs, 8)
2468 codecvt_base* __thiscall codecvt_base_ctor_refs(codecvt_base *this, MSVCP_size_t refs)
2470 TRACE("(%p %lu)\n", this, refs);
2471 locale_facet_ctor_refs(&this->facet, refs);
2472 this->facet.vtable = &MSVCP_codecvt_base_vtable;
2476 /* ??_Fcodecvt_base@std@@QAEXXZ */
2477 /* ??_Fcodecvt_base@std@@QEAAXXZ */
2478 DEFINE_THISCALL_WRAPPER(codecvt_base_ctor, 4)
2479 codecvt_base* __thiscall codecvt_base_ctor(codecvt_base *this)
2481 return codecvt_base_ctor_refs(this, 0);
2484 /* ??1codecvt_base@std@@UAE@XZ */
2485 /* ??1codecvt_base@std@@UEAA@XZ */
2486 DEFINE_THISCALL_WRAPPER(codecvt_base_dtor, 4)
2487 void __thiscall codecvt_base_dtor(codecvt_base *this)
2489 TRACE("(%p)\n", this);
2490 locale_facet_dtor(&this->facet);
2493 DEFINE_THISCALL_WRAPPER(MSVCP_codecvt_base_vector_dtor, 8)
2494 codecvt_base* __thiscall MSVCP_codecvt_base_vector_dtor(codecvt_base *this, unsigned int flags)
2496 TRACE("(%p %x)\n", this, flags);
2498 /* we have an array, with the number of elements stored before the first object */
2499 int i, *ptr = (int *)this-1;
2501 for(i=*ptr-1; i>=0; i--)
2502 codecvt_base_dtor(this+i);
2503 MSVCRT_operator_delete(ptr);
2505 codecvt_base_dtor(this);
2507 MSVCRT_operator_delete(this);
2513 /* ?do_always_noconv@codecvt_base@std@@MBE_NXZ */
2514 /* ?do_always_noconv@codecvt_base@std@@MEBA_NXZ */
2515 #define call_codecvt_base_do_always_noconv(this) CALL_VTBL_FUNC(this, 4, \
2516 MSVCP_bool, (const codecvt_base*), (this))
2517 DEFINE_THISCALL_WRAPPER(codecvt_base_do_always_noconv, 4)
2518 MSVCP_bool __thiscall codecvt_base_do_always_noconv(const codecvt_base *this)
2520 TRACE("(%p)\n", this);
2524 /* ?always_noconv@codecvt_base@std@@QBE_NXZ */
2525 /* ?always_noconv@codecvt_base@std@@QEBA_NXZ */
2526 DEFINE_THISCALL_WRAPPER(codecvt_base_always_noconv, 4)
2527 MSVCP_bool __thiscall codecvt_base_always_noconv(const codecvt_base *this)
2529 TRACE("(%p)\n", this);
2530 return call_codecvt_base_do_always_noconv(this);
2533 /* ?do_max_length@codecvt_base@std@@MBEHXZ */
2534 /* ?do_max_length@codecvt_base@std@@MEBAHXZ */
2535 #define call_codecvt_base_do_max_length(this) CALL_VTBL_FUNC(this, 8, \
2536 int, (const codecvt_base*), (this))
2537 DEFINE_THISCALL_WRAPPER(codecvt_base_do_max_length, 4)
2538 int __thiscall codecvt_base_do_max_length(const codecvt_base *this)
2540 TRACE("(%p)\n", this);
2544 /* ?max_length@codecvt_base@std@@QBEHXZ */
2545 /* ?max_length@codecvt_base@std@@QEBAHXZ */
2546 DEFINE_THISCALL_WRAPPER(codecvt_base_max_length, 4)
2547 int __thiscall codecvt_base_max_length(const codecvt_base *this)
2549 TRACE("(%p)\n", this);
2550 return call_codecvt_base_do_max_length(this);
2553 /* ?do_encoding@codecvt_base@std@@MBEHXZ */
2554 /* ?do_encoding@codecvt_base@std@@MEBAHXZ */
2555 #define call_codecvt_base_do_encoding(this) CALL_VTBL_FUNC(this, 12, \
2556 int, (const codecvt_base*), (this))
2557 DEFINE_THISCALL_WRAPPER(codecvt_base_do_encoding, 4)
2558 int __thiscall codecvt_base_do_encoding(const codecvt_base *this)
2560 TRACE("(%p)\n", this);
2564 /* ?encoding@codecvt_base@std@@QBEHXZ */
2565 /* ?encoding@codecvt_base@std@@QEBAHXZ */
2566 DEFINE_THISCALL_WRAPPER(codecvt_base_encoding, 4)
2567 int __thiscall codecvt_base_encoding(const codecvt_base *this)
2569 TRACE("(%p)\n", this);
2570 return call_codecvt_base_do_encoding(this);
2573 /* ?id@?$codecvt@DDH@std@@2V0locale@2@A */
2574 locale_id codecvt_char_id = {0};
2576 /* ??_7?$codecvt@DDH@std@@6B@ */
2577 extern const vtable_ptr MSVCP_codecvt_char_vtable;
2579 /* ?_Init@?$codecvt@DDH@std@@IAEXABV_Locinfo@2@@Z */
2580 /* ?_Init@?$codecvt@DDH@std@@IEAAXAEBV_Locinfo@2@@Z */
2581 DEFINE_THISCALL_WRAPPER(codecvt_char__Init, 8)
2582 void __thiscall codecvt_char__Init(codecvt_char *this, const _Locinfo *locinfo)
2584 TRACE("(%p %p)\n", this, locinfo);
2587 /* ??0?$codecvt@DDH@std@@QAE@ABV_Locinfo@1@I@Z */
2588 /* ??0?$codecvt@DDH@std@@QEAA@AEBV_Locinfo@1@_K@Z */
2589 DEFINE_THISCALL_WRAPPER(codecvt_char_ctor_locinfo, 12)
2590 codecvt_char* __thiscall codecvt_char_ctor_locinfo(codecvt_char *this, const _Locinfo *locinfo, MSVCP_size_t refs)
2592 TRACE("(%p %p %lu)\n", this, locinfo, refs);
2593 codecvt_base_ctor_refs(&this->base, refs);
2594 this->base.facet.vtable = &MSVCP_codecvt_char_vtable;
2598 /* ??0?$codecvt@DDH@std@@QAE@I@Z */
2599 /* ??0?$codecvt@DDH@std@@QEAA@_K@Z */
2600 DEFINE_THISCALL_WRAPPER(codecvt_char_ctor_refs, 8)
2601 codecvt_char* __thiscall codecvt_char_ctor_refs(codecvt_char *this, MSVCP_size_t refs)
2603 return codecvt_char_ctor_locinfo(this, NULL, refs);
2606 /* ??_F?$codecvt@DDH@std@@QAEXXZ */
2607 /* ??_F?$codecvt@DDH@std@@QEAAXXZ */
2608 DEFINE_THISCALL_WRAPPER(codecvt_char_ctor, 4)
2609 codecvt_char* __thiscall codecvt_char_ctor(codecvt_char *this)
2611 return codecvt_char_ctor_locinfo(this, NULL, 0);
2614 /* ??1?$codecvt@DDH@std@@MAE@XZ */
2615 /* ??1?$codecvt@DDH@std@@MEAA@XZ */
2616 DEFINE_THISCALL_WRAPPER(codecvt_char_dtor, 4)
2617 void __thiscall codecvt_char_dtor(codecvt_char *this)
2619 TRACE("(%p)\n", this);
2620 codecvt_base_dtor(&this->base);
2623 DEFINE_THISCALL_WRAPPER(MSVCP_codecvt_char_vector_dtor, 8)
2624 codecvt_char* __thiscall MSVCP_codecvt_char_vector_dtor(codecvt_char *this, unsigned int flags)
2626 TRACE("(%p %x)\n", this, flags);
2628 /* we have an array, with the number of elements stored before the first object */
2629 int i, *ptr = (int *)this-1;
2631 for(i=*ptr-1; i>=0; i--)
2632 codecvt_char_dtor(this+i);
2633 MSVCRT_operator_delete(ptr);
2635 codecvt_char_dtor(this);
2637 MSVCRT_operator_delete(this);
2643 /* ?_Getcat@?$codecvt@DDH@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
2644 /* ?_Getcat@?$codecvt@DDH@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
2645 MSVCP_size_t __cdecl codecvt_char__Getcat(const locale_facet **facet, const locale *loc)
2647 TRACE("(%p %p)\n", facet, loc);
2649 if(facet && !*facet) {
2650 *facet = MSVCRT_operator_new(sizeof(codecvt_char));
2652 ERR("Out of memory\n");
2653 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
2656 codecvt_char_ctor((codecvt_char*)*facet);
2662 codecvt_char* codecvt_char_use_facet(const locale *loc)
2664 static codecvt_char *obj = NULL;
2667 const locale_facet *fac;
2669 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
2670 fac = locale__Getfacet(loc, codecvt_char_id.id);
2672 _Lockit_dtor(&lock);
2673 return (codecvt_char*)fac;
2679 codecvt_char__Getcat(&fac, loc);
2680 obj = (codecvt_char*)fac;
2681 locale_facet__Incref(&obj->base.facet);
2682 locale_facet_register(&obj->base.facet);
2683 _Lockit_dtor(&lock);
2688 /* ?do_in@?$codecvt@DDH@std@@MBEHAAHPBD1AAPBDPAD3AAPAD@Z */
2689 /* ?do_in@?$codecvt@DDH@std@@MEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z */
2690 #define call_codecvt_char_do_in(this, state, from, from_end, from_next, to, to_end, to_next) \
2691 CALL_VTBL_FUNC(this, 16, int, \
2692 (const codecvt_char*, int*, const char*, const char*, const char**, char*, char*, char**), \
2693 (this, state, from, from_end, from_next, to, to_end, to_next))
2694 DEFINE_THISCALL_WRAPPER(codecvt_char_do_in, 32)
2695 int __thiscall codecvt_char_do_in(const codecvt_char *this, int *state,
2696 const char *from, const char *from_end, const char **from_next,
2697 char *to, char *to_end, char **to_next)
2699 TRACE("(%p %p %p %p %p %p %p %p)\n", this, state, from, from_end,
2700 from_next, to, to_end, to_next);
2703 return CODECVT_noconv;
2706 /* ?in@?$codecvt@DDH@std@@QBEHAAHPBD1AAPBDPAD3AAPAD@Z */
2707 /* ?in@?$codecvt@DDH@std@@QEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z */
2708 DEFINE_THISCALL_WRAPPER(codecvt_char_in, 32)
2709 int __thiscall codecvt_char_in(const codecvt_char *this, int *state,
2710 const char *from, const char *from_end, const char **from_next,
2711 char *to, char *to_end, char **to_next)
2713 TRACE("(%p %p %p %p %p %p %p %p)\n", this, state, from, from_end,
2714 from_next, to, to_end, to_next);
2715 return call_codecvt_char_do_in(this, state, from, from_end, from_next,
2716 to, to_end, to_next);
2719 /* ?do_out@?$codecvt@DDH@std@@MBEHAAHPBD1AAPBDPAD3AAPAD@Z */
2720 /* ?do_out@?$codecvt@DDH@std@@MEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z */
2721 #define call_codecvt_char_do_out(this, state, from, from_end, from_next, to, to_end, to_next) \
2722 CALL_VTBL_FUNC(this, 20, int, \
2723 (const codecvt_char*, int*, const char*, const char*, const char**, char*, char*, char**), \
2724 (this, state, from, from_end, from_next, to, to_end, to_next))
2725 DEFINE_THISCALL_WRAPPER(codecvt_char_do_out, 32)
2726 int __thiscall codecvt_char_do_out(const codecvt_char *this, int *state,
2727 const char *from, const char *from_end, const char **from_next,
2728 char *to, char *to_end, char **to_next)
2730 TRACE("(%p %p %p %p %p %p %p %p)\n", this, state, from,
2731 from_end, from_next, to, to_end, to_next);
2734 return CODECVT_noconv;
2737 /* ?out@?$codecvt@DDH@std@@QBEHAAHPBD1AAPBDPAD3AAPAD@Z */
2738 /* ?out@?$codecvt@DDH@std@@QEBAHAEAHPEBD1AEAPEBDPEAD3AEAPEAD@Z */
2739 DEFINE_THISCALL_WRAPPER(codecvt_char_out, 32)
2740 int __thiscall codecvt_char_out(const codecvt_char *this, int *state,
2741 const char *from, const char *from_end, const char **from_next,
2742 char *to, char *to_end, char **to_next)
2744 TRACE("(%p %p %p %p %p %p %p %p)\n", this, state, from, from_end,
2745 from_next, to, to_end, to_next);
2746 return call_codecvt_char_do_out(this, state, from, from_end, from_next,
2747 to, to_end, to_next);
2750 /* ?do_unshift@?$codecvt@DDH@std@@MBEHAAHPAD1AAPAD@Z */
2751 /* ?do_unshift@?$codecvt@DDH@std@@MEBAHAEAHPEAD1AEAPEAD@Z */
2752 #define call_codecvt_char_do_unshift(this, state, to, to_end, to_next) CALL_VTBL_FUNC(this, 24, \
2753 int, (const codecvt_char*, int*, char*, char*, char**), (this, state, to, to_end, to_next))
2754 DEFINE_THISCALL_WRAPPER(codecvt_char_do_unshift, 20)
2755 int __thiscall codecvt_char_do_unshift(const codecvt_char *this,
2756 int *state, char *to, char *to_end, char **to_next)
2758 TRACE("(%p %p %p %p %p)\n", this, state, to, to_end, to_next);
2760 return CODECVT_noconv;
2763 /* ?unshift@?$codecvt@DDH@std@@QBEHAAHPAD1AAPAD@Z */
2764 /* ?unshift@?$codecvt@DDH@std@@QEBAHAEAHPEAD1AEAPEAD@Z */
2765 DEFINE_THISCALL_WRAPPER(codecvt_char_unshift, 20)
2766 int __thiscall codecvt_char_unshift(const codecvt_char *this,
2767 int *state, char *to, char *to_end, char **to_next)
2769 TRACE("(%p %p %p %p %p)\n", this, state, to, to_end, to_next);
2770 return call_codecvt_char_do_unshift(this, state, to, to_end, to_next);
2773 /* ?do_length@?$codecvt@DDH@std@@MBEHABHPBD1I@Z */
2774 /* ?do_length@?$codecvt@DDH@std@@MEBAHAEBHPEBD1_K@Z */
2775 #define call_codecvt_char_do_length(this, state, from, from_end, max) CALL_VTBL_FUNC(this, 28, \
2776 int, (const codecvt_char*, const int*, const char*, const char*, MSVCP_size_t), \
2777 (this, state, from, from_end, max))
2778 DEFINE_THISCALL_WRAPPER(codecvt_char_do_length, 20)
2779 int __thiscall codecvt_char_do_length(const codecvt_char *this, const int *state,
2780 const char *from, const char *from_end, MSVCP_size_t max)
2782 TRACE("(%p %p %p %p %lu)\n", this, state, from, from_end, max);
2783 return (from_end-from > max ? max : from_end-from);
2786 /* ?length@?$codecvt@DDH@std@@QBEHABHPBD1I@Z */
2787 /* ?length@?$codecvt@DDH@std@@QEBAHAEBHPEBD1_K@Z */
2788 DEFINE_THISCALL_WRAPPER(codecvt_char_length, 20)
2789 int __thiscall codecvt_char_length(const codecvt_char *this, const int *state,
2790 const char *from, const char *from_end, MSVCP_size_t max)
2792 TRACE("(%p %p %p %p %lu)\n", this, state, from, from_end, max);
2793 return call_codecvt_char_do_length(this, state, from, from_end, max);
2796 /* ?id@?$numpunct@D@std@@2V0locale@2@A */
2797 locale_id numpunct_char_id = {0};
2799 /* ??_7?$numpunct@D@std@@6B@ */
2800 extern const vtable_ptr MSVCP_numpunct_char_vtable;
2802 /* ?_Init@?$numpunct@D@std@@IAEXABV_Locinfo@2@_N@Z */
2803 /* ?_Init@?$numpunct@D@std@@IEAAXAEBV_Locinfo@2@_N@Z */
2804 DEFINE_THISCALL_WRAPPER(numpunct_char__Init, 12)
2805 void __thiscall numpunct_char__Init(numpunct_char *this, _Locinfo *locinfo, MSVCP_bool isdef)
2809 TRACE("(%p %p %d)\n", this, locinfo, isdef);
2811 len = strlen(_Locinfo__Getfalse(locinfo))+1;
2812 this->false_name = MSVCRT_operator_new(len);
2813 if(this->false_name)
2814 memcpy((char*)this->false_name, _Locinfo__Getfalse(locinfo), len);
2816 len = strlen(_Locinfo__Gettrue(locinfo))+1;
2817 this->true_name = MSVCRT_operator_new(len);
2819 memcpy((char*)this->true_name, _Locinfo__Gettrue(locinfo), len);
2822 this->grouping = MSVCRT_operator_new(1);
2824 *(char*)this->grouping = 0;
2829 const struct lconv *lc = _Locinfo__Getlconv(locinfo);
2831 len = strlen(lc->grouping)+1;
2832 this->grouping = MSVCRT_operator_new(len);
2834 memcpy((char*)this->grouping, lc->grouping, len);
2836 this->dp = lc->decimal_point[0];
2837 this->sep = lc->thousands_sep[0];
2840 if(!this->false_name || !this->true_name || !this->grouping) {
2841 MSVCRT_operator_delete((char*)this->grouping);
2842 MSVCRT_operator_delete((char*)this->false_name);
2843 MSVCRT_operator_delete((char*)this->true_name);
2845 ERR("Out of memory\n");
2846 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
2850 /* ?_Tidy@?$numpunct@D@std@@AAEXXZ */
2851 /* ?_Tidy@?$numpunct@D@std@@AEAAXXZ */
2852 DEFINE_THISCALL_WRAPPER(numpunct_char__Tidy, 4)
2853 void __thiscall numpunct_char__Tidy(numpunct_char *this)
2855 TRACE("(%p)\n", this);
2857 MSVCRT_operator_delete((char*)this->grouping);
2858 MSVCRT_operator_delete((char*)this->false_name);
2859 MSVCRT_operator_delete((char*)this->true_name);
2862 /* ??0?$numpunct@D@std@@QAE@ABV_Locinfo@1@I_N@Z */
2863 /* ??0?$numpunct@D@std@@QEAA@AEBV_Locinfo@1@_K_N@Z */
2864 DEFINE_THISCALL_WRAPPER(numpunct_char_ctor_locinfo, 16)
2865 numpunct_char* __thiscall numpunct_char_ctor_locinfo(numpunct_char *this,
2866 _Locinfo *locinfo, MSVCP_size_t refs, MSVCP_bool usedef)
2868 TRACE("(%p %p %lu %d)\n", this, locinfo, refs, usedef);
2869 locale_facet_ctor_refs(&this->facet, refs);
2870 this->facet.vtable = &MSVCP_numpunct_char_vtable;
2871 numpunct_char__Init(this, locinfo, usedef);
2875 /* ??0?$numpunct@D@std@@IAE@PBDI_N@Z */
2876 /* ??0?$numpunct@D@std@@IEAA@PEBD_K_N@Z */
2877 DEFINE_THISCALL_WRAPPER(numpunct_char_ctor_name, 16)
2878 numpunct_char* __thiscall numpunct_char_ctor_name(numpunct_char *this,
2879 const char *name, MSVCP_size_t refs, MSVCP_bool usedef)
2883 TRACE("(%p %s %lu %d)\n", this, debugstr_a(name), refs, usedef);
2884 locale_facet_ctor_refs(&this->facet, refs);
2885 this->facet.vtable = &MSVCP_numpunct_char_vtable;
2887 _Locinfo_ctor_cstr(&locinfo, name);
2888 numpunct_char__Init(this, &locinfo, usedef);
2889 _Locinfo_dtor(&locinfo);
2893 /* ??0?$numpunct@D@std@@QAE@I@Z */
2894 /* ??0?$numpunct@D@std@@QEAA@_K@Z */
2895 DEFINE_THISCALL_WRAPPER(numpunct_char_ctor_refs, 8)
2896 numpunct_char* __thiscall numpunct_char_ctor_refs(numpunct_char *this, MSVCP_size_t refs)
2898 TRACE("(%p %lu)\n", this, refs);
2899 return numpunct_char_ctor_name(this, "C", refs, FALSE);
2902 /* ??_F?$numpunct@D@std@@QAEXXZ */
2903 /* ??_F?$numpunct@D@std@@QEAAXXZ */
2904 DEFINE_THISCALL_WRAPPER(numpunct_char_ctor, 4)
2905 numpunct_char* __thiscall numpunct_char_ctor(numpunct_char *this)
2907 return numpunct_char_ctor_refs(this, 0);
2910 /* ??1?$numpunct@D@std@@MAE@XZ */
2911 /* ??1?$numpunct@D@std@@MEAA@XZ */
2912 DEFINE_THISCALL_WRAPPER(numpunct_char_dtor, 4)
2913 void __thiscall numpunct_char_dtor(numpunct_char *this)
2915 TRACE("(%p)\n", this);
2916 numpunct_char__Tidy(this);
2919 DEFINE_THISCALL_WRAPPER(MSVCP_numpunct_char_vector_dtor, 8)
2920 numpunct_char* __thiscall MSVCP_numpunct_char_vector_dtor(numpunct_char *this, unsigned int flags)
2922 TRACE("(%p %x)\n", this, flags);
2924 /* we have an array, with the number of elements stored before the first object */
2925 int i, *ptr = (int *)this-1;
2927 for(i=*ptr-1; i>=0; i--)
2928 numpunct_char_dtor(this+i);
2929 MSVCRT_operator_delete(ptr);
2931 numpunct_char_dtor(this);
2933 MSVCRT_operator_delete(this);
2939 /* ?_Getcat@?$numpunct@D@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
2940 /* ?_Getcat@?$numpunct@D@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
2941 MSVCP_size_t __cdecl numpunct_char__Getcat(const locale_facet **facet, const locale *loc)
2943 TRACE("(%p %p)\n", facet, loc);
2945 if(facet && !*facet) {
2946 *facet = MSVCRT_operator_new(sizeof(numpunct_char));
2948 ERR("Out of memory\n");
2949 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
2952 numpunct_char_ctor_name((numpunct_char*)*facet,
2953 MSVCP_basic_string_char_c_str(&loc->ptr->name), 0, TRUE);
2959 /* ?do_decimal_point@?$numpunct@D@std@@MBEDXZ */
2960 /* ?do_decimal_point@?$numpunct@D@std@@MEBADXZ */
2961 DEFINE_THISCALL_WRAPPER(numpunct_char_do_decimal_point, 4)
2962 #define call_numpunct_char_do_decimal_point(this) CALL_VTBL_FUNC(this, 4, \
2963 char, (const numpunct_char *this), (this))
2964 char __thiscall numpunct_char_do_decimal_point(const numpunct_char *this)
2966 TRACE("(%p)\n", this);
2970 /* ?decimal_point@?$numpunct@D@std@@QBEDXZ */
2971 /* ?decimal_point@?$numpunct@D@std@@QEBADXZ */
2972 DEFINE_THISCALL_WRAPPER(numpunct_char_decimal_point, 4)
2973 char __thiscall numpunct_char_decimal_point(const numpunct_char *this)
2975 TRACE("(%p)\n", this);
2976 return call_numpunct_char_do_decimal_point(this);
2979 /* ?do_thousands_sep@?$numpunct@D@std@@MBEDXZ */
2980 /* ?do_thousands_sep@?$numpunct@D@std@@MEBADXZ */
2981 DEFINE_THISCALL_WRAPPER(numpunct_char_do_thousands_sep, 4)
2982 #define call_numpunct_char_do_thousands_sep(this) CALL_VTBL_FUNC(this, 8, \
2983 char, (const numpunct_char*), (this))
2984 char __thiscall numpunct_char_do_thousands_sep(const numpunct_char *this)
2986 TRACE("(%p)\n", this);
2990 /* ?thousands_sep@?$numpunct@D@std@@QBEDXZ */
2991 /* ?thousands_sep@?$numpunct@D@std@@QEBADXZ */
2992 DEFINE_THISCALL_WRAPPER(numpunct_char_thousands_sep, 4)
2993 char __thiscall numpunct_char_thousands_sep(const numpunct_char *this)
2995 TRACE("(%p)\n", this);
2996 return call_numpunct_char_do_thousands_sep(this);
2999 /* ?do_grouping@?$numpunct@D@std@@MBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3000 /* ?do_grouping@?$numpunct@D@std@@MEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3001 DEFINE_THISCALL_WRAPPER(numpunct_char_do_grouping, 8)
3002 #define call_numpunct_char_do_grouping(this, ret) CALL_VTBL_FUNC(this, 12, \
3003 basic_string_char*, (const numpunct_char*, basic_string_char*), (this, ret))
3004 basic_string_char* __thiscall numpunct_char_do_grouping(
3005 const numpunct_char *this, basic_string_char *ret)
3007 TRACE("(%p)\n", this);
3008 return MSVCP_basic_string_char_ctor_cstr(ret, this->grouping);
3011 /* ?grouping@?$numpunct@D@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3012 /* ?grouping@?$numpunct@D@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3013 DEFINE_THISCALL_WRAPPER(numpunct_char_grouping, 8)
3014 basic_string_char* __thiscall numpunct_char_grouping(const numpunct_char *this, basic_string_char *ret)
3016 TRACE("(%p)\n", this);
3017 return call_numpunct_char_do_grouping(this, ret);
3020 /* ?do_falsename@?$numpunct@D@std@@MBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3021 /* ?do_falsename@?$numpunct@D@std@@MEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3022 DEFINE_THISCALL_WRAPPER(numpunct_char_do_falsename, 8)
3023 #define call_numpunct_char_do_falsename(this, ret) CALL_VTBL_FUNC(this, 16, \
3024 basic_string_char*, (const numpunct_char*, basic_string_char*), (this, ret))
3025 basic_string_char* __thiscall numpunct_char_do_falsename(
3026 const numpunct_char *this, basic_string_char *ret)
3028 TRACE("(%p)\n", this);
3029 return MSVCP_basic_string_char_ctor_cstr(ret, this->false_name);
3032 /* ?falsename@?$numpunct@D@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3033 /* ?falsename@?$numpunct@D@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3034 DEFINE_THISCALL_WRAPPER(numpunct_char_falsename, 8)
3035 basic_string_char* __thiscall numpunct_char_falsename(const numpunct_char *this, basic_string_char *ret)
3037 TRACE("(%p)\n", this);
3038 return call_numpunct_char_do_falsename(this, ret);
3041 /* ?do_truename@?$numpunct@D@std@@MBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3042 /* ?do_truename@?$numpunct@D@std@@MEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3043 DEFINE_THISCALL_WRAPPER(numpunct_char_do_truename, 8)
3044 #define call_numpunct_char_do_truename(this, ret) CALL_VTBL_FUNC(this, 20, \
3045 basic_string_char*, (const numpunct_char*, basic_string_char*), (this, ret))
3046 basic_string_char* __thiscall numpunct_char_do_truename(
3047 const numpunct_char *this, basic_string_char *ret)
3049 TRACE("(%p)\n", this);
3050 return MSVCP_basic_string_char_ctor_cstr(ret, this->true_name);
3053 /* ?truename@?$numpunct@D@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3054 /* ?truename@?$numpunct@D@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3055 DEFINE_THISCALL_WRAPPER(numpunct_char_truename, 8)
3056 basic_string_char* __thiscall numpunct_char_truename(const numpunct_char *this, basic_string_char *ret)
3058 TRACE("(%p)\n", this);
3059 return call_numpunct_char_do_truename(this, ret);
3062 /* ?id@?$numpunct@_W@std@@2V0locale@2@A */
3063 locale_id numpunct_wchar_id = {0};
3064 /* ?id@?$numpunct@G@std@@2V0locale@2@A */
3065 locale_id numpunct_short_id = {0};
3067 /* ??_7?$numpunct@_W@std@@6B@ */
3068 extern const vtable_ptr MSVCP_numpunct_wchar_vtable;
3069 /* ??_7?$numpunct@G@std@@6B@ */
3070 extern const vtable_ptr MSVCP_numpunct_short_vtable;
3072 /* ?_Init@?$numpunct@_W@std@@IAEXABV_Locinfo@2@_N@Z */
3073 /* ?_Init@?$numpunct@_W@std@@IEAAXAEBV_Locinfo@2@_N@Z */
3074 /* ?_Init@?$numpunct@G@std@@IAEXABV_Locinfo@2@_N@Z */
3075 /* ?_Init@?$numpunct@G@std@@IEAAXAEBV_Locinfo@2@_N@Z */
3076 DEFINE_THISCALL_WRAPPER(numpunct_wchar__Init, 12)
3077 void __thiscall numpunct_wchar__Init(numpunct_wchar *this, _Locinfo *locinfo, MSVCP_bool isdef)
3079 const char *to_convert;
3083 TRACE("(%p %p %d)\n", this, locinfo, isdef);
3085 _Locinfo__Getcvt(locinfo, &cvt);
3087 to_convert = _Locinfo__Getfalse(locinfo);
3088 len = MultiByteToWideChar(cvt.page, 0, to_convert, -1, NULL, 0);
3089 this->false_name = MSVCRT_operator_new(len*sizeof(WCHAR));
3090 if(this->false_name)
3091 MultiByteToWideChar(cvt.page, 0, to_convert, -1,
3092 (wchar_t*)this->false_name, len);
3094 to_convert = _Locinfo__Gettrue(locinfo);
3095 len = MultiByteToWideChar(cvt.page, 0, to_convert, -1, NULL, 0);
3096 this->true_name = MSVCRT_operator_new(len*sizeof(WCHAR));
3098 MultiByteToWideChar(cvt.page, 0, to_convert, -1,
3099 (wchar_t*)this->true_name, len);
3102 this->grouping = MSVCRT_operator_new(1);
3104 *(char*)this->grouping = 0;
3109 const struct lconv *lc = _Locinfo__Getlconv(locinfo);
3111 len = strlen(lc->grouping)+1;
3112 this->grouping = MSVCRT_operator_new(len);
3114 memcpy((char*)this->grouping, lc->grouping, len);
3116 this->dp = lc->decimal_point[0];
3117 this->sep = lc->thousands_sep[0];
3120 if(!this->false_name || !this->true_name || !this->grouping) {
3121 MSVCRT_operator_delete((char*)this->grouping);
3122 MSVCRT_operator_delete((wchar_t*)this->false_name);
3123 MSVCRT_operator_delete((wchar_t*)this->true_name);
3125 ERR("Out of memory\n");
3126 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
3130 /* ?_Tidy@?$numpunct@_W@std@@AAEXXZ */
3131 /* ?_Tidy@?$numpunct@_W@std@@AEAAXXZ */
3132 /* ?_Tidy@?$numpunct@G@std@@AAEXXZ */
3133 /* ?_Tidy@?$numpunct@G@std@@AEAAXXZ */
3134 DEFINE_THISCALL_WRAPPER(numpunct_wchar__Tidy, 4)
3135 void __thiscall numpunct_wchar__Tidy(numpunct_wchar *this)
3137 TRACE("(%p)\n", this);
3139 MSVCRT_operator_delete((char*)this->grouping);
3140 MSVCRT_operator_delete((wchar_t*)this->false_name);
3141 MSVCRT_operator_delete((wchar_t*)this->true_name);
3144 /* ??0?$numpunct@_W@std@@QAE@ABV_Locinfo@1@I_N@Z */
3145 /* ??0?$numpunct@_W@std@@QEAA@AEBV_Locinfo@1@_K_N@Z */
3146 DEFINE_THISCALL_WRAPPER(numpunct_wchar_ctor_locinfo, 16)
3147 numpunct_wchar* __thiscall numpunct_wchar_ctor_locinfo(numpunct_wchar *this,
3148 _Locinfo *locinfo, MSVCP_size_t refs, MSVCP_bool usedef)
3150 TRACE("(%p %p %lu %d)\n", this, locinfo, refs, usedef);
3151 locale_facet_ctor_refs(&this->facet, refs);
3152 this->facet.vtable = &MSVCP_numpunct_wchar_vtable;
3153 numpunct_wchar__Init(this, locinfo, usedef);
3157 /* ??0?$numpunct@G@std@@QAE@ABV_Locinfo@1@I_N@Z */
3158 /* ??0?$numpunct@G@std@@QEAA@AEBV_Locinfo@1@_K_N@Z */
3159 DEFINE_THISCALL_WRAPPER(numpunct_short_ctor_locinfo, 16)
3160 numpunct_wchar* __thiscall numpunct_short_ctor_locinfo(numpunct_wchar *this,
3161 _Locinfo *locinfo, MSVCP_size_t refs, MSVCP_bool usedef)
3163 numpunct_wchar_ctor_locinfo(this, locinfo, refs, usedef);
3164 this->facet.vtable = &MSVCP_numpunct_short_vtable;
3168 /* ??0?$numpunct@_W@std@@IAE@PBDI_N@Z */
3169 /* ??0?$numpunct@_W@std@@IEAA@PEBD_K_N@Z */
3170 DEFINE_THISCALL_WRAPPER(numpunct_wchar_ctor_name, 16)
3171 numpunct_wchar* __thiscall numpunct_wchar_ctor_name(numpunct_wchar *this,
3172 const char *name, MSVCP_size_t refs, MSVCP_bool usedef)
3176 TRACE("(%p %s %lu %d)\n", this, debugstr_a(name), refs, usedef);
3177 locale_facet_ctor_refs(&this->facet, refs);
3178 this->facet.vtable = &MSVCP_numpunct_wchar_vtable;
3180 _Locinfo_ctor_cstr(&locinfo, name);
3181 numpunct_wchar__Init(this, &locinfo, usedef);
3182 _Locinfo_dtor(&locinfo);
3186 /* ??0?$numpunct@G@std@@IAE@PBDI_N@Z */
3187 /* ??0?$numpunct@G@std@@IEAA@PEBD_K_N@Z */
3188 DEFINE_THISCALL_WRAPPER(numpunct_short_ctor_name, 16)
3189 numpunct_wchar* __thiscall numpunct_short_ctor_name(numpunct_wchar *this,
3190 const char *name, MSVCP_size_t refs, MSVCP_bool usedef)
3192 numpunct_wchar_ctor_name(this, name, refs, usedef);
3193 this->facet.vtable = &MSVCP_numpunct_short_vtable;
3197 /* ??0?$numpunct@_W@std@@QAE@I@Z */
3198 /* ??0?$numpunct@_W@std@@QEAA@_K@Z */
3199 DEFINE_THISCALL_WRAPPER(numpunct_wchar_ctor_refs, 8)
3200 numpunct_wchar* __thiscall numpunct_wchar_ctor_refs(numpunct_wchar *this, MSVCP_size_t refs)
3202 TRACE("(%p %lu)\n", this, refs);
3203 return numpunct_wchar_ctor_name(this, "C", refs, FALSE);
3206 /* ??0?$numpunct@G@std@@QAE@I@Z */
3207 /* ??0?$numpunct@G@std@@QEAA@_K@Z */
3208 DEFINE_THISCALL_WRAPPER(numpunct_short_ctor_refs, 8)
3209 numpunct_wchar* __thiscall numpunct_short_ctor_refs(numpunct_wchar *this, MSVCP_size_t refs)
3211 numpunct_wchar_ctor_refs(this, refs);
3212 this->facet.vtable = &MSVCP_numpunct_short_vtable;
3216 /* ??_F?$numpunct@_W@std@@QAEXXZ */
3217 /* ??_F?$numpunct@_W@std@@QEAAXXZ */
3218 DEFINE_THISCALL_WRAPPER(numpunct_wchar_ctor, 4)
3219 numpunct_wchar* __thiscall numpunct_wchar_ctor(numpunct_wchar *this)
3221 return numpunct_wchar_ctor_refs(this, 0);
3224 /* ??_F?$numpunct@G@std@@QAEXXZ */
3225 /* ??_F?$numpunct@G@std@@QEAAXXZ */
3226 DEFINE_THISCALL_WRAPPER(numpunct_short_ctor, 4)
3227 numpunct_wchar* __thiscall numpunct_short_ctor(numpunct_wchar *this)
3229 return numpunct_short_ctor_refs(this, 0);
3232 /* ??1?$numpunct@_W@std@@MAE@XZ */
3233 /* ??1?$numpunct@_W@std@@MEAA@XZ */
3234 /* ??1?$numpunct@G@std@@MAE@XZ */
3235 /* ??1?$numpunct@G@std@@MEAA@XZ */
3236 DEFINE_THISCALL_WRAPPER(numpunct_wchar_dtor, 4)
3237 void __thiscall numpunct_wchar_dtor(numpunct_wchar *this)
3239 TRACE("(%p)\n", this);
3240 numpunct_wchar__Tidy(this);
3243 DEFINE_THISCALL_WRAPPER(MSVCP_numpunct_wchar_vector_dtor, 8)
3244 numpunct_wchar* __thiscall MSVCP_numpunct_wchar_vector_dtor(numpunct_wchar *this, unsigned int flags)
3246 TRACE("(%p %x)\n", this, flags);
3248 /* we have an array, with the number of elements stored before the first object */
3249 int i, *ptr = (int *)this-1;
3251 for(i=*ptr-1; i>=0; i--)
3252 numpunct_wchar_dtor(this+i);
3253 MSVCRT_operator_delete(ptr);
3255 numpunct_wchar_dtor(this);
3257 MSVCRT_operator_delete(this);
3263 DEFINE_THISCALL_WRAPPER(MSVCP_numpunct_short_vector_dtor, 8)
3264 numpunct_wchar* __thiscall MSVCP_numpunct_short_vector_dtor(numpunct_wchar *this, unsigned int flags)
3266 return MSVCP_numpunct_wchar_vector_dtor(this, flags);
3269 /* ?_Getcat@?$numpunct@_W@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
3270 /* ?_Getcat@?$numpunct@_W@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
3271 MSVCP_size_t __cdecl numpunct_wchar__Getcat(const locale_facet **facet, const locale *loc)
3273 TRACE("(%p %p)\n", facet, loc);
3275 if(facet && !*facet) {
3276 *facet = MSVCRT_operator_new(sizeof(numpunct_wchar));
3278 ERR("Out of memory\n");
3279 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
3282 numpunct_wchar_ctor_name((numpunct_wchar*)*facet,
3283 MSVCP_basic_string_char_c_str(&loc->ptr->name), 0, TRUE);
3289 /* ?_Getcat@?$numpunct@G@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
3290 /* ?_Getcat@?$numpunct@G@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
3291 MSVCP_size_t __cdecl numpunct_short__Getcat(const locale_facet **facet, const locale *loc)
3293 TRACE("(%p %p)\n", facet, loc);
3295 if(facet && !*facet) {
3296 *facet = MSVCRT_operator_new(sizeof(numpunct_wchar));
3298 ERR("Out of memory\n");
3299 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
3302 numpunct_short_ctor_name((numpunct_wchar*)*facet,
3303 MSVCP_basic_string_char_c_str(&loc->ptr->name), 0, TRUE);
3309 /* ?do_decimal_point@?$numpunct@_W@std@@MBE_WXZ */
3310 /* ?do_decimal_point@?$numpunct@_W@std@@MEBA_WXZ */
3311 /* ?do_decimal_point@?$numpunct@G@std@@MBEGXZ */
3312 /* ?do_decimal_point@?$numpunct@G@std@@MEBAGXZ */
3313 DEFINE_THISCALL_WRAPPER(numpunct_wchar_do_decimal_point, 4)
3314 #define call_numpunct_wchar_do_decimal_point(this) CALL_VTBL_FUNC(this, 4, \
3315 wchar_t, (const numpunct_wchar *this), (this))
3316 wchar_t __thiscall numpunct_wchar_do_decimal_point(const numpunct_wchar *this)
3318 TRACE("(%p)\n", this);
3322 /* ?decimal_point@?$numpunct@_W@std@@QBE_WXZ */
3323 /* ?decimal_point@?$numpunct@_W@std@@QEBA_WXZ */
3324 /* ?decimal_point@?$numpunct@G@std@@QBEGXZ */
3325 /* ?decimal_point@?$numpunct@G@std@@QEBAGXZ */
3326 DEFINE_THISCALL_WRAPPER(numpunct_wchar_decimal_point, 4)
3327 wchar_t __thiscall numpunct_wchar_decimal_point(const numpunct_wchar *this)
3329 TRACE("(%p)\n", this);
3330 return call_numpunct_wchar_do_decimal_point(this);
3333 /* ?do_thousands_sep@?$numpunct@_W@std@@MBE_WXZ */
3334 /* ?do_thousands_sep@?$numpunct@_W@std@@MEBA_WXZ */
3335 /* ?do_thousands_sep@?$numpunct@G@std@@MBEGXZ */
3336 /* ?do_thousands_sep@?$numpunct@G@std@@MEBAGXZ */
3337 DEFINE_THISCALL_WRAPPER(numpunct_wchar_do_thousands_sep, 4)
3338 #define call_numpunct_wchar_do_thousands_sep(this) CALL_VTBL_FUNC(this, 8, \
3339 wchar_t, (const numpunct_wchar *this), (this))
3340 wchar_t __thiscall numpunct_wchar_do_thousands_sep(const numpunct_wchar *this)
3342 TRACE("(%p)\n", this);
3346 /* ?thousands_sep@?$numpunct@_W@std@@QBE_WXZ */
3347 /* ?thousands_sep@?$numpunct@_W@std@@QEBA_WXZ */
3348 /* ?thousands_sep@?$numpunct@G@std@@QBEGXZ */
3349 /* ?thousands_sep@?$numpunct@G@std@@QEBAGXZ */
3350 DEFINE_THISCALL_WRAPPER(numpunct_wchar_thousands_sep, 4)
3351 wchar_t __thiscall numpunct_wchar_thousands_sep(const numpunct_wchar *this)
3353 TRACE("(%p)\n", this);
3354 return call_numpunct_wchar_do_thousands_sep(this);
3357 /* ?do_grouping@?$numpunct@_W@std@@MBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3358 /* ?do_grouping@?$numpunct@_W@std@@MEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3359 /* ?do_grouping@?$numpunct@G@std@@MBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3360 /* ?do_grouping@?$numpunct@G@std@@MEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3361 DEFINE_THISCALL_WRAPPER(numpunct_wchar_do_grouping, 8)
3362 #define call_numpunct_wchar_do_grouping(this, ret) CALL_VTBL_FUNC(this, 12, \
3363 basic_string_char*, (const numpunct_wchar*, basic_string_char*), (this, ret))
3364 basic_string_char* __thiscall numpunct_wchar_do_grouping(const numpunct_wchar *this, basic_string_char *ret)
3366 TRACE("(%p)\n", this);
3367 return MSVCP_basic_string_char_ctor_cstr(ret, this->grouping);
3370 /* ?grouping@?$numpunct@_W@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3371 /* ?grouping@?$numpunct@_W@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3372 /* ?grouping@?$numpunct@G@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3373 /* ?grouping@?$numpunct@G@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
3374 DEFINE_THISCALL_WRAPPER(numpunct_wchar_grouping, 8)
3375 basic_string_char* __thiscall numpunct_wchar_grouping(const numpunct_wchar *this, basic_string_char *ret)
3377 TRACE("(%p)\n", this);
3378 return call_numpunct_wchar_do_grouping(this, ret);
3381 /* ?do_falsename@?$numpunct@_W@std@@MBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3382 /* ?do_falsename@?$numpunct@_W@std@@MEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3383 /* ?do_falsename@?$numpunct@G@std@@MBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3384 /* ?do_falsename@?$numpunct@G@std@@MEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3385 DEFINE_THISCALL_WRAPPER(numpunct_wchar_do_falsename, 8)
3386 #define call_numpunct_wchar_do_falsename(this, ret) CALL_VTBL_FUNC(this, 16, \
3387 basic_string_wchar*, (const numpunct_wchar*, basic_string_wchar*), (this, ret))
3388 basic_string_wchar* __thiscall numpunct_wchar_do_falsename(const numpunct_wchar *this, basic_string_wchar *ret)
3390 TRACE("(%p)\n", this);
3391 return MSVCP_basic_string_wchar_ctor_cstr(ret, this->false_name);
3394 /* ?falsename@?$numpunct@_W@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3395 /* ?falsename@?$numpunct@_W@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3396 /* ?falsename@?$numpunct@G@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3397 /* ?falsename@?$numpunct@G@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3398 DEFINE_THISCALL_WRAPPER(numpunct_wchar_falsename, 8)
3399 basic_string_wchar* __thiscall numpunct_wchar_falsename(const numpunct_wchar *this, basic_string_wchar *ret)
3401 TRACE("(%p)\n", this);
3402 return call_numpunct_wchar_do_falsename(this, ret);
3405 /* ?do_truename@?$numpunct@_W@std@@MBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3406 /* ?do_truename@?$numpunct@_W@std@@MEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3407 /* ?do_truename@?$numpunct@G@std@@MBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3408 /* ?do_truename@?$numpunct@G@std@@MEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3409 DEFINE_THISCALL_WRAPPER(numpunct_wchar_do_truename, 8)
3410 #define call_numpunct_wchar_do_truename(this, ret) CALL_VTBL_FUNC(this, 20, \
3411 basic_string_wchar*, (const numpunct_wchar*, basic_string_wchar*), (this, ret))
3412 basic_string_wchar* __thiscall numpunct_wchar_do_truename(const numpunct_wchar *this, basic_string_wchar *ret)
3414 TRACE("(%p)\n", this);
3415 return MSVCP_basic_string_wchar_ctor_cstr(ret, this->true_name);
3418 /* ?truename@?$numpunct@_W@std@@QBE?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3419 /* ?truename@?$numpunct@_W@std@@QEBA?AV?$basic_string@_WU?$char_traits@_W@std@@V?$allocator@_W@2@@2@XZ */
3420 /* ?truename@?$numpunct@G@std@@QBE?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3421 /* ?truename@?$numpunct@G@std@@QEBA?AV?$basic_string@GU?$char_traits@G@std@@V?$allocator@G@2@@2@XZ */
3422 DEFINE_THISCALL_WRAPPER(numpunct_wchar_truename, 8)
3423 basic_string_wchar* __thiscall numpunct_wchar_truename(const numpunct_wchar *this, basic_string_wchar *ret)
3425 TRACE("(%p)\n", this);
3426 return call_numpunct_wchar_do_truename(this, ret);
3429 /* ?id@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@2V0locale@2@A */
3430 locale_id num_get_wchar_id = {0};
3431 /* ?id@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@2V0locale@2@A */
3432 locale_id num_get_short_id = {0};
3434 /* ??_7?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@6B@ */
3435 extern const vtable_ptr MSVCP_num_get_wchar_vtable;
3436 /* ??_7?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@6B@ */
3437 extern const vtable_ptr MSVCP_num_get_short_vtable;
3439 /* ?_Init@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z */
3440 /* ?_Init@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z */
3441 /* ?_Init@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z */
3442 /* ?_Init@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z */
3443 DEFINE_THISCALL_WRAPPER(num_get_wchar_ctor__Init, 8)
3444 void __thiscall num_get_wchar_ctor__Init(num_get *this, const _Locinfo *locinfo)
3446 FIXME("(%p %p) stub\n", this, locinfo);
3449 /* ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z */
3450 /* ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z */
3451 DEFINE_THISCALL_WRAPPER(num_get_wchar_ctor_locinfo, 12)
3452 num_get* __thiscall num_get_wchar_ctor_locinfo(num_get *this,
3453 _Locinfo *locinfo, MSVCP_size_t refs)
3455 FIXME("(%p %p %lu) stub\n", this, locinfo, refs);
3459 /* ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z */
3460 /* ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z */
3461 DEFINE_THISCALL_WRAPPER(num_get_short_ctor_locinfo, 12)
3462 num_get* __thiscall num_get_short_ctor_locinfo(num_get *this,
3463 _Locinfo *locinfo, MSVCP_size_t refs)
3465 FIXME("(%p %p %lu) stub\n", this, locinfo, refs);
3469 /* ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAE@I@Z */
3470 /* ??0?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAA@_K@Z */
3471 DEFINE_THISCALL_WRAPPER(num_get_wchar_ctor_refs, 8)
3472 num_get* __thiscall num_get_wchar_ctor_refs(num_get *this, MSVCP_size_t refs)
3474 FIXME("(%p %lu) stub\n", this, refs);
3478 /* ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QAE@I@Z */
3479 /* ??0?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEAA@_K@Z */
3480 DEFINE_THISCALL_WRAPPER(num_get_short_ctor_refs, 8)
3481 num_get* __thiscall num_get_short_ctor_refs(num_get *this, MSVCP_size_t refs)
3483 FIXME("(%p %lu) stub\n", this, refs);
3487 /* ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAEXXZ */
3488 /* ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAAXXZ */
3489 DEFINE_THISCALL_WRAPPER(num_get_wchar_ctor, 4)
3490 num_get* __thiscall num_get_wchar_ctor(num_get *this)
3492 FIXME("(%p) stub\n", this);
3496 /* ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QAEXXZ */
3497 /* ??_F?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEAAXXZ */
3498 DEFINE_THISCALL_WRAPPER(num_get_short_ctor, 4)
3499 num_get* __thiscall num_get_short_ctor(num_get *this)
3501 FIXME("(%p) stub\n", this);
3505 /* ??1?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MAE@XZ */
3506 /* ??1?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEAA@XZ */
3507 /* ??1?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MAE@XZ */
3508 /* ??1?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEAA@XZ */
3509 DEFINE_THISCALL_WRAPPER(num_get_wchar_dtor, 4)
3510 void __thiscall num_get_wchar_dtor(num_get *this)
3512 FIXME("(%p) stub\n", this);
3515 DEFINE_THISCALL_WRAPPER(MSVCP_num_get_wchar_vector_dtor, 8)
3516 num_get* __thiscall MSVCP_num_get_wchar_vector_dtor(num_get *this, unsigned int flags)
3518 TRACE("(%p %x)\n", this, flags);
3520 /* we have an array, with the number of elements stored before the first object */
3521 int i, *ptr = (int *)this-1;
3523 for(i=*ptr-1; i>=0; i--)
3524 num_get_wchar_dtor(this+i);
3525 MSVCRT_operator_delete(ptr);
3527 num_get_wchar_dtor(this);
3529 MSVCRT_operator_delete(this);
3535 DEFINE_THISCALL_WRAPPER(MSVCP_num_get_short_vector_dtor, 8)
3536 num_get* __thiscall MSVCP_num_get_short_vector_dtor(num_get *this, unsigned int flags)
3538 return MSVCP_num_get_wchar_vector_dtor(this, flags);
3541 /* ?_Getcat@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
3542 /* ?_Getcat@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
3543 MSVCP_size_t __cdecl num_get_wchar__Getcat(const locale_facet **facet, const locale *loc)
3545 FIXME("(%p %p) stub\n", facet, loc);
3549 /* ?_Getcat@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
3550 /* ?_Getcat@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
3551 MSVCP_size_t __cdecl num_get_short__Getcat(const locale_facet **facet, const locale *loc)
3553 FIXME("(%p %p) stub\n", facet, loc);
3557 /* ?_Getffld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1ABVlocale@2@@Z */
3558 /* ?_Getffld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AEBVlocale@2@@Z */
3559 /* ?_Getffld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1ABVlocale@2@@Z */
3560 /* ?_Getffld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AEBVlocale@2@@Z */
3561 int __cdecl num_get_wchar__Getffld(num_get *this, char *dest, istreambuf_iterator_wchar *first,
3562 istreambuf_iterator_wchar *last, const locale *loc)
3564 FIXME("(%p %p %p %p) stub\n", dest, first, last, loc);
3568 /* ?_Getffldx@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AAVios_base@2@PAH@Z */
3569 /* ?_Getffldx@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1AEAVios_base@2@PEAH@Z */
3570 /* ?_Getffldx@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AAVios_base@2@PAH@Z */
3571 /* ?_Getffldx@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1AEAVios_base@2@PEAH@Z */
3572 int __cdecl num_get_wchar__Getffldx(num_get *this, char *dest, istreambuf_iterator_wchar *first,
3573 istreambuf_iterator_wchar *last, struct _ios_base *ios, int *phexexp)
3575 FIXME("(%p %p %p %p %p) stub\n", dest, first, last, ios, phexexp);
3579 /* ?_Getifld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1HABVlocale@2@@Z */
3580 /* ?_Getifld@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@1HAEBVlocale@2@@Z */
3581 /* ?_Getifld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1HABVlocale@2@@Z */
3582 /* ?_Getifld@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@1HAEBVlocale@2@@Z */
3583 int __cdecl num_get_wchar__Getifld(num_get *this, char *dest, istreambuf_iterator_wchar *first,
3584 istreambuf_iterator_wchar *last, int fmtflags, const locale *loc)
3586 FIXME("(%p %p %p %04x %p) stub\n", dest, first, last, fmtflags, loc);
3590 /* ?_Hexdig@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@ABEH_W000@Z */
3591 /* ?_Hexdig@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@AEBAH_W000@Z */
3592 /* ?_Hexdig@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@ABEHGGGG@Z */
3593 /* ?_Hexdig@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@AEBAHGGGG@Z */
3594 DEFINE_THISCALL_WRAPPER(MSVCP_num_get_wchar__Hexdig, 20)
3595 int __thiscall MSVCP_num_get_wchar__Hexdig(num_get *this, wchar_t dig, wchar_t e0, wchar_t al, wchar_t au)
3597 FIXME("(%p %c %c %c %c) stub\n", this, dig, e0, al, au);
3601 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z */
3602 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z */
3603 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z */
3604 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z */
3605 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_void,36)
3606 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_void(const num_get *this, istreambuf_iterator_wchar *ret,
3607 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, void **pval)
3609 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3613 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z */
3614 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z */
3615 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z */
3616 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z */
3617 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_void,36)
3618 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_void(const num_get *this, istreambuf_iterator_wchar *ret,
3619 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, void **pval)
3621 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3625 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAO@Z */
3626 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z */
3627 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAN@Z */
3628 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z */
3629 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAO@Z */
3630 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z */
3631 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAN@Z */
3632 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z */
3633 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_double,36)
3634 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_double(const num_get *this, istreambuf_iterator_wchar *ret,
3635 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, double *pval)
3637 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3641 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAO@Z */
3642 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z */
3643 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAN@Z */
3644 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z */
3645 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAO@Z */
3646 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z */
3647 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAN@Z */
3648 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z */
3649 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_double,36)
3650 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_double(const num_get *this, istreambuf_iterator_wchar *ret,
3651 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, double *pval)
3653 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3657 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAM@Z */
3658 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z */
3659 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAM@Z */
3660 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z */
3661 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_float,36)
3662 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_float(const num_get *this, istreambuf_iterator_wchar *ret,
3663 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, float *pval)
3665 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3669 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAM@Z */
3670 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z */
3671 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAM@Z */
3672 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z */
3673 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_float,36)
3674 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_float(const num_get *this, istreambuf_iterator_wchar *ret,
3675 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, float *pval)
3677 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3681 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z */
3682 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z */
3683 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z */
3684 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z */
3685 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_uint64,36)
3686 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_uint64(const num_get *this, istreambuf_iterator_wchar *ret,
3687 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, ULONGLONG *pval)
3689 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3693 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z */
3694 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z */
3695 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z */
3696 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z */
3697 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_uint64,36)
3698 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_uint64(const num_get *this, istreambuf_iterator_wchar *ret,
3699 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, ULONGLONG *pval)
3701 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3705 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z */
3706 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z */
3707 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z */
3708 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z */
3709 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_int64,36)
3710 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_int64(const num_get *this, istreambuf_iterator_wchar *ret,
3711 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, LONGLONG *pval)
3713 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3717 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z */
3718 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z */
3719 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z */
3720 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z */
3721 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_int64,36)
3722 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_int64(const num_get *this, istreambuf_iterator_wchar *ret,
3723 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, LONGLONG *pval)
3725 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3729 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAK@Z */
3730 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z */
3731 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAK@Z */
3732 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z */
3733 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_ulong,36)
3734 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_ulong(const num_get *this, istreambuf_iterator_wchar *ret,
3735 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, ULONG *pval)
3737 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3741 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAK@Z */
3742 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z */
3743 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAK@Z */
3744 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z */
3745 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_ulong,36)
3746 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_ulong(const num_get *this, istreambuf_iterator_wchar *ret,
3747 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, ULONG *pval)
3749 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3753 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z */
3754 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z */
3755 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z */
3756 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z */
3757 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_long,36)
3758 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_long(const num_get *this, istreambuf_iterator_wchar *ret,
3759 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, LONG *pval)
3761 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3765 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z */
3766 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z */
3767 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z */
3768 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z */
3769 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_long,36)
3770 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_long(const num_get *this, istreambuf_iterator_wchar *ret,
3771 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, LONG *pval)
3773 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3777 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAI@Z */
3778 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z */
3779 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAI@Z */
3780 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z */
3781 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_uint,36)
3782 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_uint(const num_get *this, istreambuf_iterator_wchar *ret,
3783 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, unsigned int *pval)
3785 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3789 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAI@Z */
3790 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z */
3791 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAI@Z */
3792 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z */
3793 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_uint,36)
3794 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_uint(const num_get *this, istreambuf_iterator_wchar *ret,
3795 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, unsigned int *pval)
3797 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3801 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAG@Z */
3802 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z */
3803 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAG@Z */
3804 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z */
3805 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_ushort,36)
3806 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_ushort(const num_get *this, istreambuf_iterator_wchar *ret,
3807 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, unsigned short *pval)
3809 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3813 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAAG@Z */
3814 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z */
3815 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAAG@ */
3816 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z */
3817 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_ushort,36)
3818 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_ushort(const num_get *this, istreambuf_iterator_wchar *ret,
3819 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, unsigned short *pval)
3821 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3825 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z */
3826 /* ?do_get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z */
3827 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z */
3828 /* ?do_get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z */
3829 DEFINE_THISCALL_WRAPPER(num_get_wchar_do_get_bool,36)
3830 istreambuf_iterator_wchar *__thiscall num_get_wchar_do_get_bool(const num_get *this, istreambuf_iterator_wchar *ret,
3831 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, MSVCP_bool *pval)
3833 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3837 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z */
3838 /* ?get@?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z */
3839 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z */
3840 /* ?get@?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@GU?$char_traits@G@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z */
3841 DEFINE_THISCALL_WRAPPER(num_get_wchar_get_bool,36)
3842 istreambuf_iterator_wchar *__thiscall num_get_wchar_get_bool(const num_get *this, istreambuf_iterator_wchar *ret,
3843 istreambuf_iterator_wchar first, istreambuf_iterator_wchar last, struct _ios_base *base, int *state, MSVCP_bool *pval)
3845 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3849 /* ?id@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@2V0locale@2@A */
3850 locale_id num_get_char_id = {0};
3852 /* ??_7?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@6B@ */
3853 extern const vtable_ptr MSVCP_num_get_char_vtable;
3855 /* ?_Init@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IAEXABV_Locinfo@2@@Z */
3856 /* ?_Init@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@IEAAXAEBV_Locinfo@2@@Z */
3857 DEFINE_THISCALL_WRAPPER(num_get_char_ctor__Init, 8)
3858 void __thiscall num_get_char_ctor__Init(num_get *this, const _Locinfo *locinfo)
3860 FIXME("(%p %p) stub\n", this, locinfo);
3863 /* ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@ABV_Locinfo@1@I@Z */
3864 /* ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@AEBV_Locinfo@1@_K@Z */
3865 DEFINE_THISCALL_WRAPPER(num_get_char_ctor_locinfo, 12)
3866 num_get* __thiscall num_get_char_ctor_locinfo(num_get *this,
3867 _Locinfo *locinfo, MSVCP_size_t refs)
3869 FIXME("(%p %p %lu) stub\n", this, locinfo, refs);
3873 /* ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAE@I@Z */
3874 /* ??0?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAA@_K@Z */
3875 DEFINE_THISCALL_WRAPPER(num_get_char_ctor_refs, 8)
3876 num_get* __thiscall num_get_char_ctor_refs(num_get *this, MSVCP_size_t refs)
3878 FIXME("(%p %lu) stub\n", this, refs);
3882 /* ??_F?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QAEXXZ */
3883 /* ??_F?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEAAXXZ */
3884 DEFINE_THISCALL_WRAPPER(num_get_char_ctor, 4)
3885 num_get* __thiscall num_get_char_ctor(num_get *this)
3887 FIXME("(%p) stub\n", this);
3891 /* ??1?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MAE@XZ */
3892 /* ??1?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEAA@XZ */
3893 DEFINE_THISCALL_WRAPPER(num_get_char_dtor, 4)
3894 void __thiscall num_get_char_dtor(num_get *this)
3896 FIXME("(%p) stub\n", this);
3899 DEFINE_THISCALL_WRAPPER(MSVCP_num_get_char_vector_dtor, 8)
3900 num_get* __thiscall MSVCP_num_get_char_vector_dtor(num_get *this, unsigned int flags)
3902 TRACE("(%p %x)\n", this, flags);
3904 /* we have an array, with the number of elements stored before the first object */
3905 int i, *ptr = (int *)this-1;
3907 for(i=*ptr-1; i>=0; i--)
3908 num_get_char_dtor(this+i);
3909 MSVCRT_operator_delete(ptr);
3911 num_get_char_dtor(this);
3913 MSVCRT_operator_delete(this);
3919 /* ?_Getcat@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SAIPAPBVfacet@locale@2@PBV42@@Z */
3920 /* ?_Getcat@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@SA_KPEAPEBVfacet@locale@2@PEBV42@@Z */
3921 MSVCP_size_t __cdecl num_get_char__Getcat(const locale_facet **facet, const locale *loc)
3923 FIXME("(%p %p) stub\n", facet, loc);
3927 /* ?_Getffld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1ABVlocale@2@@Z */
3928 /* ?_Getffld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AEBVlocale@2@@Z */
3929 int __cdecl num_get_char__Getffld(num_get *this, char *dest, istreambuf_iterator_char *first,
3930 istreambuf_iterator_char *last, const locale *loc)
3932 FIXME("(%p %p %p %p) stub\n", dest, first, last, loc);
3936 /* ?_Getffldx@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AAVios_base@2@PAH@Z */
3937 /* ?_Getffldx@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1AEAVios_base@2@PEAH@Z */
3938 int __cdecl num_get_char__Getffldx(num_get *this, char *dest, istreambuf_iterator_char *first,
3939 istreambuf_iterator_char *last, struct _ios_base *ios, int *phexexp)
3941 FIXME("(%p %p %p %p %p) stub\n", dest, first, last, ios, phexexp);
3945 /* ?_Getifld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABAHPADAAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1HABVlocale@2@@Z */
3946 /* ?_Getifld@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHPEADAEAV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@1HAEBVlocale@2@@Z */
3947 int __cdecl num_get_char__Getifld(num_get *this, char *dest, istreambuf_iterator_char *first,
3948 istreambuf_iterator_char *last, int fmtflags, const locale *loc)
3950 FIXME("(%p %p %p %04x %p) stub\n", dest, first, last, fmtflags, loc);
3954 /* ?_Hexdig@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@ABEHD000@Z */
3955 /* ?_Hexdig@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@AEBAHD000@Z */
3956 DEFINE_THISCALL_WRAPPER(MSVCP_num_get_char__Hexdig, 20)
3957 int __thiscall MSVCP_num_get_char__Hexdig(num_get *this, char dig, char e0, char al, char au)
3959 FIXME("(%p %c %c %c %c) stub\n", this, dig, e0, al, au);
3963 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z */
3964 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z */
3965 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_void,36)
3966 istreambuf_iterator_char *__thiscall num_get_char_do_get_void(const num_get *this, istreambuf_iterator_char *ret,
3967 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, void **pval)
3969 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3973 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAPAX@Z */
3974 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAPEAX@Z */
3975 DEFINE_THISCALL_WRAPPER(num_get_char_get_void,36)
3976 istreambuf_iterator_char *__thiscall num_get_char_get_void(const num_get *this, istreambuf_iterator_char *ret,
3977 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, void **pval)
3979 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3983 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAO@Z */
3984 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z */
3985 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAN@Z */
3986 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z */
3987 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_double,36)
3988 istreambuf_iterator_char *__thiscall num_get_char_do_get_double(const num_get *this, istreambuf_iterator_char *ret,
3989 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, double *pval)
3991 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
3995 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAO@Z */
3996 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAO@Z */
3997 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAN@Z */
3998 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAN@Z */
3999 DEFINE_THISCALL_WRAPPER(num_get_char_get_double,36)
4000 istreambuf_iterator_char *__thiscall num_get_char_get_double(const num_get *this, istreambuf_iterator_char *ret,
4001 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, double *pval)
4003 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4007 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAM@Z */
4008 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z */
4009 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_float,36)
4010 istreambuf_iterator_char *__thiscall num_get_char_do_get_float(const num_get *this, istreambuf_iterator_char *ret,
4011 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, float *pval)
4013 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4017 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAM@Z */
4018 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAM@Z */
4019 DEFINE_THISCALL_WRAPPER(num_get_char_get_float,36)
4020 istreambuf_iterator_char *__thiscall num_get_char_get_float(const num_get *this, istreambuf_iterator_char *ret,
4021 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, float *pval)
4023 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4027 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z */
4028 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z */
4029 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_uint64,36)
4030 istreambuf_iterator_char *__thiscall num_get_char_do_get_uint64(const num_get *this, istreambuf_iterator_char *ret,
4031 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, ULONGLONG *pval)
4033 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4037 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_K@Z */
4038 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_K@Z */
4039 DEFINE_THISCALL_WRAPPER(num_get_char_get_uint64,36)
4040 istreambuf_iterator_char *__thiscall num_get_char_get_uint64(const num_get *this, istreambuf_iterator_char *ret,
4041 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, ULONGLONG *pval)
4043 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4047 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z */
4048 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z */
4049 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_int64,36)
4050 istreambuf_iterator_char *__thiscall num_get_char_do_get_int64(const num_get *this, istreambuf_iterator_char *ret,
4051 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, LONGLONG *pval)
4053 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4057 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_J@Z */
4058 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_J@Z */
4059 DEFINE_THISCALL_WRAPPER(num_get_char_get_int64,36)
4060 istreambuf_iterator_char *__thiscall num_get_char_get_int64(const num_get *this, istreambuf_iterator_char *ret,
4061 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, LONGLONG *pval)
4063 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4067 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAK@Z */
4068 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z */
4069 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_ulong,36)
4070 istreambuf_iterator_char *__thiscall num_get_char_do_get_ulong(const num_get *this, istreambuf_iterator_char *ret,
4071 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, ULONG *pval)
4073 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4077 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAK@Z */
4078 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAK@Z */
4079 DEFINE_THISCALL_WRAPPER(num_get_char_get_ulong,36)
4080 istreambuf_iterator_char *__thiscall num_get_char_get_ulong(const num_get *this, istreambuf_iterator_char *ret,
4081 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, ULONG *pval)
4083 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4087 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z */
4088 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z */
4089 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_long,36)
4090 istreambuf_iterator_char *__thiscall num_get_char_do_get_long(const num_get *this, istreambuf_iterator_char *ret,
4091 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, LONG *pval)
4093 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4097 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAJ@Z */
4098 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAJ@Z */
4099 DEFINE_THISCALL_WRAPPER(num_get_char_get_long,36)
4100 istreambuf_iterator_char *__thiscall num_get_char_get_long(const num_get *this, istreambuf_iterator_char *ret,
4101 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, LONG *pval)
4103 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4107 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAI@Z */
4108 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z */
4109 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_uint,36)
4110 istreambuf_iterator_char *__thiscall num_get_char_do_get_uint(const num_get *this, istreambuf_iterator_char *ret,
4111 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, unsigned int *pval)
4113 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4117 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAI@Z */
4118 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAI@Z */
4119 DEFINE_THISCALL_WRAPPER(num_get_char_get_uint,36)
4120 istreambuf_iterator_char *__thiscall num_get_char_get_uint(const num_get *this, istreambuf_iterator_char *ret,
4121 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, unsigned int *pval)
4123 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4127 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAG@Z */
4128 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z */
4129 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_ushort,36)
4130 istreambuf_iterator_char *__thiscall num_get_char_do_get_ushort(const num_get *this, istreambuf_iterator_char *ret,
4131 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, unsigned short *pval)
4133 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4137 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAAG@Z */
4138 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEAG@Z */
4139 DEFINE_THISCALL_WRAPPER(num_get_char_get_ushort,36)
4140 istreambuf_iterator_char *__thiscall num_get_char_get_ushort(const num_get *this, istreambuf_iterator_char *ret,
4141 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, unsigned short *pval)
4143 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4147 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z */
4148 /* ?do_get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@MEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z */
4149 DEFINE_THISCALL_WRAPPER(num_get_char_do_get_bool,36)
4150 istreambuf_iterator_char *__thiscall num_get_char_do_get_bool(const num_get *this, istreambuf_iterator_char *ret,
4151 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, MSVCP_bool *pval)
4153 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4157 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QBE?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AAVios_base@2@AAHAA_N@Z */
4158 /* ?get@?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@QEBA?AV?$istreambuf_iterator@DU?$char_traits@D@std@@@2@V32@0AEAVios_base@2@AEAHAEA_N@Z */
4159 DEFINE_THISCALL_WRAPPER(num_get_char_get_bool,36)
4160 istreambuf_iterator_char *__thiscall num_get_char_get_bool(const num_get *this, istreambuf_iterator_char *ret,
4161 istreambuf_iterator_char first, istreambuf_iterator_char last, struct _ios_base *base, int *state, MSVCP_bool *pval)
4163 FIXME("(%p %p %p %p %p) stub\n", this, ret, base, state, pval);
4167 /* ??0_Locimp@locale@std@@AAE@_N@Z */
4168 /* ??0_Locimp@locale@std@@AEAA@_N@Z */
4169 DEFINE_THISCALL_WRAPPER(locale__Locimp_ctor_transparent, 8)
4170 locale__Locimp* __thiscall locale__Locimp_ctor_transparent(locale__Locimp *this, MSVCP_bool transparent)
4172 TRACE("(%p %d)\n", this, transparent);
4174 memset(this, 0, sizeof(locale__Locimp));
4175 locale_facet_ctor_refs(&this->facet, 1);
4176 this->transparent = transparent;
4177 MSVCP_basic_string_char_ctor_cstr(&this->name, "*");
4181 /* ??_F_Locimp@locale@std@@QAEXXZ */
4182 /* ??_F_Locimp@locale@std@@QEAAXXZ */
4183 DEFINE_THISCALL_WRAPPER(locale__Locimp_ctor, 4)
4184 locale__Locimp* __thiscall locale__Locimp_ctor(locale__Locimp *this)
4186 return locale__Locimp_ctor_transparent(this, FALSE);
4189 /* ??0_Locimp@locale@std@@AAE@ABV012@@Z */
4190 /* ??0_Locimp@locale@std@@AEAA@AEBV012@@Z */
4191 DEFINE_THISCALL_WRAPPER(locale__Locimp_copy_ctor, 8)
4192 locale__Locimp* __thiscall locale__Locimp_copy_ctor(locale__Locimp *this, const locale__Locimp *copy)
4197 TRACE("(%p %p)\n", this, copy);
4199 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
4200 memcpy(this, copy, sizeof(locale__Locimp));
4201 locale_facet_ctor_refs(&this->facet, 1);
4202 if(copy->facetvec) {
4203 this->facetvec = MSVCRT_operator_new(copy->facet_cnt*sizeof(locale_facet*));
4204 if(!this->facetvec) {
4205 _Lockit_dtor(&lock);
4206 ERR("Out of memory\n");
4207 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
4210 for(i=0; i<this->facet_cnt; i++)
4211 if(this->facetvec[i])
4212 locale_facet__Incref(this->facetvec[i]);
4214 MSVCP_basic_string_char_copy_ctor(&this->name, ©->name);
4215 _Lockit_dtor(&lock);
4219 /* ?_Locimp_ctor@_Locimp@locale@std@@CAXPAV123@ABV123@@Z */
4220 /* ?_Locimp_ctor@_Locimp@locale@std@@CAXPEAV123@AEBV123@@Z */
4221 locale__Locimp* __cdecl locale__Locimp__Locimp_ctor(locale__Locimp *this, const locale__Locimp *copy)
4223 return locale__Locimp_copy_ctor(this, copy);
4226 /* ??1_Locimp@locale@std@@MAE@XZ */
4227 /* ??1_Locimp@locale@std@@MEAA@XZ */
4228 DEFINE_THISCALL_WRAPPER(locale__Locimp_dtor, 4)
4229 void __thiscall locale__Locimp_dtor(locale__Locimp *this)
4231 TRACE("(%p)\n", this);
4233 if(locale_facet__Decref(&this->facet)) {
4235 for(i=0; i<this->facet_cnt; i++)
4236 if(this->facetvec[i] && locale_facet__Decref(this->facetvec[i]))
4237 call_locale_facet_vector_dtor(this->facetvec[i], 0);
4239 MSVCRT_operator_delete(this->facetvec);
4240 MSVCP_basic_string_char_dtor(&this->name);
4244 /* ?_Locimp_dtor@_Locimp@locale@std@@CAXPAV123@@Z */
4245 /* ?_Locimp_dtor@_Locimp@locale@std@@CAXPEAV123@@Z */
4246 void __cdecl locale__Locimp__Locimp_dtor(locale__Locimp *this)
4248 locale__Locimp_dtor(this);
4251 DEFINE_THISCALL_WRAPPER(MSVCP_locale__Locimp_vector_dtor, 8)
4252 locale__Locimp* __thiscall MSVCP_locale__Locimp_vector_dtor(locale__Locimp *this, unsigned int flags)
4254 TRACE("(%p %x)\n", this, flags);
4256 /* we have an array, with the number of elements stored before the first object */
4257 int i, *ptr = (int *)this-1;
4259 for(i=*ptr-1; i>=0; i--)
4260 locale__Locimp_dtor(this+i);
4261 MSVCRT_operator_delete(ptr);
4263 locale__Locimp_dtor(this);
4265 MSVCRT_operator_delete(this);
4271 /* ?_Locimp_Addfac@_Locimp@locale@std@@CAXPAV123@PAVfacet@23@I@Z */
4272 /* ?_Locimp_Addfac@_Locimp@locale@std@@CAXPEAV123@PEAVfacet@23@_K@Z */
4273 void __cdecl locale__Locimp__Locimp_Addfac(locale__Locimp *locimp, locale_facet *facet, MSVCP_size_t id)
4277 TRACE("(%p %p %lu)\n", locimp, facet, id);
4279 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
4280 if(id >= locimp->facet_cnt) {
4281 MSVCP_size_t new_size = id+1;
4282 locale_facet **new_facetvec;
4284 if(new_size < locale_id__Id_cnt+1)
4285 new_size = locale_id__Id_cnt+1;
4287 new_facetvec = MSVCRT_operator_new(sizeof(locale_facet*)*new_size);
4289 _Lockit_dtor(&lock);
4290 ERR("Out of memory\n");
4291 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
4295 memset(new_facetvec, 0, sizeof(locale_facet*)*new_size);
4296 memcpy(new_facetvec, locimp->facetvec, sizeof(locale_facet*)*locimp->facet_cnt);
4297 MSVCRT_operator_delete(locimp->facetvec);
4298 locimp->facetvec = new_facetvec;
4299 locimp->facet_cnt = new_size;
4302 if(locimp->facetvec[id] && locale_facet__Decref(locimp->facetvec[id]))
4303 call_locale_facet_vector_dtor(locimp->facetvec[id], 0);
4305 locimp->facetvec[id] = facet;
4307 locale_facet__Incref(facet);
4308 _Lockit_dtor(&lock);
4311 /* ?_Addfac@_Locimp@locale@std@@AAEXPAVfacet@23@I@Z */
4312 /* ?_Addfac@_Locimp@locale@std@@AEAAXPEAVfacet@23@_K@Z */
4313 DEFINE_THISCALL_WRAPPER(locale__Locimp__Addfac, 12)
4314 void __thiscall locale__Locimp__Addfac(locale__Locimp *this, locale_facet *facet, MSVCP_size_t id)
4316 locale__Locimp__Locimp_Addfac(this, facet, id);
4319 /* ?_Clocptr_func@_Locimp@locale@std@@CAAAPAV123@XZ */
4320 /* ?_Clocptr_func@_Locimp@locale@std@@CAAEAPEAV123@XZ */
4321 locale__Locimp** __cdecl locale__Locimp__Clocptr_func(void)
4327 /* ?_Makeloc@_Locimp@locale@std@@CAPAV123@ABV_Locinfo@3@HPAV123@PBV23@@Z */
4328 /* ?_Makeloc@_Locimp@locale@std@@CAPEAV123@AEBV_Locinfo@3@HPEAV123@PEBV23@@Z */
4329 locale__Locimp* __cdecl locale__Locimp__Makeloc(const _Locinfo *locinfo, category cat, locale__Locimp *locimp, const locale *loc)
4331 FIXME("(%p %d %p %p) stub\n", locinfo, cat, locimp, loc);
4335 /* ?_Makeushloc@_Locimp@locale@std@@CAXABV_Locinfo@3@HPAV123@PBV23@@Z */
4336 /* ?_Makeushloc@_Locimp@locale@std@@CAXAEBV_Locinfo@3@HPEAV123@PEBV23@@Z */
4337 void __cdecl locale__Locimp__Makeushloc(const _Locinfo *locinfo, category cat, locale__Locimp *locimp, const locale *loc)
4339 FIXME("(%p %d %p %p) stub\n", locinfo, cat, locimp, loc);
4342 /* ?_Makewloc@_Locimp@locale@std@@CAXABV_Locinfo@3@HPAV123@PBV23@@Z */
4343 /* ?_Makewloc@_Locimp@locale@std@@CAXAEBV_Locinfo@3@HPEAV123@PEBV23@@Z */
4344 void __cdecl locale__Locimp__Makewloc(const _Locinfo *locinfo, category cat, locale__Locimp *locimp, const locale *loc)
4346 FIXME("(%p %d %p %p) stub\n", locinfo, cat, locimp, loc);
4349 /* ?_Makexloc@_Locimp@locale@std@@CAXABV_Locinfo@3@HPAV123@PBV23@@Z */
4350 /* ?_Makexloc@_Locimp@locale@std@@CAXAEBV_Locinfo@3@HPEAV123@PEBV23@@Z */
4351 void __cdecl locale__Locimp__Makexloc(const _Locinfo *locinfo, category cat, locale__Locimp *locimp, const locale *loc)
4353 FIXME("(%p %d %p %p) stub\n", locinfo, cat, locimp, loc);
4356 /* ??_7_Locimp@locale@std@@6B@ */
4357 const vtable_ptr MSVCP_locale__Locimp_vtable[] = {
4358 (vtable_ptr)THISCALL_NAME(MSVCP_locale__Locimp_vector_dtor)
4361 /* ??0locale@std@@AAE@PAV_Locimp@01@@Z */
4362 /* ??0locale@std@@AEAA@PEAV_Locimp@01@@Z */
4363 DEFINE_THISCALL_WRAPPER(locale_ctor_locimp, 8)
4364 locale* __thiscall locale_ctor_locimp(locale *this, locale__Locimp *locimp)
4366 TRACE("(%p %p)\n", this, locimp);
4367 /* Don't change locimp reference counter */
4372 /* ?_Init@locale@std@@CAPAV_Locimp@12@XZ */
4373 /* ?_Init@locale@std@@CAPEAV_Locimp@12@XZ */
4374 locale__Locimp* __cdecl locale__Init(void)
4380 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
4382 _Lockit_dtor(&lock);
4383 return global_locale;
4386 global_locale = MSVCRT_operator_new(sizeof(locale__Locimp));
4387 if(!global_locale) {
4388 _Lockit_dtor(&lock);
4389 ERR("Out of memory\n");
4390 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
4394 locale__Locimp_ctor(global_locale);
4395 global_locale->catmask = (1<<(LC_MAX+1))-1;
4396 MSVCP_basic_string_char_dtor(&global_locale->name);
4397 MSVCP_basic_string_char_ctor_cstr(&global_locale->name, "C");
4399 locale__Locimp__Clocptr = global_locale;
4400 global_locale->facet.refs++;
4401 locale_ctor_locimp(&classic_locale, locale__Locimp__Clocptr);
4402 _Lockit_dtor(&lock);
4404 return global_locale;
4407 /* ??0locale@std@@QAE@ABV01@0H@Z */
4408 /* ??0locale@std@@QEAA@AEBV01@0H@Z */
4409 DEFINE_THISCALL_WRAPPER(locale_ctor_locale_locale, 16)
4410 locale* __thiscall locale_ctor_locale_locale(locale *this, const locale *loc, const locale *other, category cat)
4412 FIXME("(%p %p %p %d) stub\n", this, loc, other, cat);
4416 /* ??0locale@std@@QAE@ABV01@@Z */
4417 /* ??0locale@std@@QEAA@AEBV01@@Z */
4418 DEFINE_THISCALL_WRAPPER(locale_copy_ctor, 8)
4419 locale* __thiscall locale_copy_ctor(locale *this, const locale *copy)
4421 TRACE("(%p %p)\n", this, copy);
4422 this->ptr = copy->ptr;
4423 locale_facet__Incref(&this->ptr->facet);
4427 /* ??0locale@std@@QAE@ABV01@PBDH@Z */
4428 /* ??0locale@std@@QEAA@AEBV01@PEBDH@Z */
4429 DEFINE_THISCALL_WRAPPER(locale_ctor_locale_cstr, 16)
4430 locale* __thiscall locale_ctor_locale_cstr(locale *this, const locale *loc, const char *locname, category cat)
4432 FIXME("(%p %p %s %d) stub\n", this, loc, locname, cat);
4436 /* ??0locale@std@@QAE@PBDH@Z */
4437 /* ??0locale@std@@QEAA@PEBDH@Z */
4438 DEFINE_THISCALL_WRAPPER(locale_ctor_cstr, 12)
4439 locale* __thiscall locale_ctor_cstr(locale *this, const char *locname, category cat)
4441 FIXME("(%p %s %d) stub\n", this, locname, cat);
4445 /* ??0locale@std@@QAE@W4_Uninitialized@1@@Z */
4446 /* ??0locale@std@@QEAA@W4_Uninitialized@1@@Z */
4447 DEFINE_THISCALL_WRAPPER(locale_ctor_uninitialized, 8)
4448 locale* __thiscall locale_ctor_uninitialized(locale *this, int uninitialized)
4450 TRACE("(%p)\n", this);
4455 /* ??0locale@std@@QAE@XZ */
4456 /* ??0locale@std@@QEAA@XZ */
4457 DEFINE_THISCALL_WRAPPER(locale_ctor, 4)
4458 locale* __thiscall locale_ctor(locale *this)
4460 TRACE("(%p)\n", this);
4461 this->ptr = locale__Init();
4462 locale_facet__Incref(&this->ptr->facet);
4466 /* ??1locale@std@@QAE@XZ */
4467 /* ??1locale@std@@QEAA@XZ */
4468 DEFINE_THISCALL_WRAPPER(locale_dtor, 4)
4469 void __thiscall locale_dtor(locale *this)
4471 TRACE("(%p)\n", this);
4473 locale__Locimp_dtor(this->ptr);
4476 DEFINE_THISCALL_WRAPPER(MSVCP_locale_vector_dtor, 8)
4477 locale* __thiscall MSVCP_locale_vector_dtor(locale *this, unsigned int flags)
4479 TRACE("(%p %x)\n", this, flags);
4481 /* we have an array, with the number of elements stored before the first object */
4482 int i, *ptr = (int *)this-1;
4484 for(i=*ptr-1; i>=0; i--)
4485 locale_dtor(this+i);
4486 MSVCRT_operator_delete(ptr);
4490 MSVCRT_operator_delete(this);
4496 /* ??4locale@std@@QAEAAV01@ABV01@@Z */
4497 /* ??4locale@std@@QEAAAEAV01@AEBV01@@Z */
4498 DEFINE_THISCALL_WRAPPER(locale_operator_assign, 8)
4499 locale* __thiscall locale_operator_assign(locale *this, const locale *loc)
4501 FIXME("(%p %p) stub\n", this, loc);
4505 /* ??8locale@std@@QBE_NABV01@@Z */
4506 /* ??8locale@std@@QEBA_NAEBV01@@Z */
4507 DEFINE_THISCALL_WRAPPER(locale_operator_equal, 8)
4508 MSVCP_bool __thiscall locale_operator_equal(const locale *this, const locale *loc)
4510 FIXME("(%p %p) stub\n", this, loc);
4514 /* ??9locale@std@@QBE_NABV01@@Z */
4515 /* ??9locale@std@@QEBA_NAEBV01@@Z */
4516 DEFINE_THISCALL_WRAPPER(locale_operator_not_equal, 8)
4517 MSVCP_bool __thiscall locale_operator_not_equal(const locale *this, locale const *loc)
4519 FIXME("(%p %p) stub\n", this, loc);
4523 /* ?_Addfac@locale@std@@QAEAAV12@PAVfacet@12@II@Z */
4524 /* ?_Addfac@locale@std@@QEAAAEAV12@PEAVfacet@12@_K1@Z */
4525 DEFINE_THISCALL_WRAPPER(locale__Addfac, 16)
4526 locale* __thiscall locale__Addfac(locale *this, locale_facet *facet, MSVCP_size_t id, MSVCP_size_t catmask)
4528 TRACE("(%p %p %lu %lu)\n", this, facet, id, catmask);
4530 if(this->ptr->facet.refs > 1) {
4531 locale__Locimp *new_ptr = MSVCRT_operator_new(sizeof(locale__Locimp));
4533 ERR("Out of memory\n");
4534 throw_exception(EXCEPTION_BAD_ALLOC, NULL);
4537 locale__Locimp_copy_ctor(new_ptr, this->ptr);
4538 locale_facet__Decref(&this->ptr->facet);
4539 this->ptr = new_ptr;
4542 locale__Locimp__Addfac(this->ptr, facet, id);
4545 MSVCP_basic_string_char_dtor(&this->ptr->name);
4546 MSVCP_basic_string_char_ctor_cstr(&this->ptr->name, "*");
4551 /* ?_Getfacet@locale@std@@QBEPBVfacet@12@I@Z */
4552 /* ?_Getfacet@locale@std@@QEBAPEBVfacet@12@_K@Z */
4553 DEFINE_THISCALL_WRAPPER(locale__Getfacet, 8)
4554 const locale_facet* __thiscall locale__Getfacet(const locale *this, MSVCP_size_t id)
4558 TRACE("(%p %lu)\n", this, id);
4560 fac = id < this->ptr->facet_cnt ? this->ptr->facetvec[id] : NULL;
4561 if(fac || !this->ptr->transparent)
4564 return id < global_locale->facet_cnt ? global_locale->facetvec[id] : NULL;
4567 /* ?_Getgloballocale@locale@std@@CAPAV_Locimp@12@XZ */
4568 /* ?_Getgloballocale@locale@std@@CAPEAV_Locimp@12@XZ */
4569 locale__Locimp* __cdecl locale__Getgloballocale(void)
4572 return global_locale;
4575 /* ?_Setgloballocale@locale@std@@CAXPAX@Z */
4576 /* ?_Setgloballocale@locale@std@@CAXPEAX@Z */
4577 void __cdecl locale__Setgloballocale(void *locimp)
4579 TRACE("(%p)\n", locimp);
4580 global_locale = locimp;
4583 /* ?classic@locale@std@@SAABV12@XZ */
4584 /* ?classic@locale@std@@SAAEBV12@XZ */
4585 const locale* __cdecl locale_classic(void)
4589 return &classic_locale;
4592 /* ?name@locale@std@@QBE?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
4593 /* ?name@locale@std@@QEBA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@2@XZ */
4594 DEFINE_THISCALL_WRAPPER(locale_name, 8)
4595 basic_string_char* __thiscall locale_name(const locale *this, basic_string_char *ret)
4597 TRACE( "(%p)\n", this);
4598 MSVCP_basic_string_char_copy_ctor(ret, &this->ptr->name);
4602 /* ?global@locale@std@@SA?AV12@ABV12@@Z */
4603 /* ?global@locale@std@@SA?AV12@AEBV12@@Z */
4604 locale* __cdecl locale_global(locale *ret, const locale *loc)
4609 TRACE("(%p %p)\n", loc, ret);
4611 _Lockit_ctor_locktype(&lock, _LOCK_LOCALE);
4614 if(loc->ptr != global_locale) {
4615 locale_facet__Decref(&global_locale->facet);
4616 global_locale = loc->ptr;
4617 locale_facet__Incref(&global_locale->facet);
4619 for(i=LC_ALL+1; i<=LC_MAX; i++) {
4620 if((global_locale->catmask & (1<<(i-1))) == 0)
4622 setlocale(i, MSVCP_basic_string_char_c_str(&global_locale->name));
4625 _Lockit_dtor(&lock);
4629 DEFINE_RTTI_DATA0(locale_facet, 0, ".?AVfacet@locale@std@@");
4630 DEFINE_RTTI_DATA1(collate_char, 0, &locale_facet_rtti_base_descriptor, ".?AV?$collate@D@std@@");
4631 DEFINE_RTTI_DATA1(collate_wchar, 0, &locale_facet_rtti_base_descriptor, ".?AV?$collate@_W@std@@");
4632 DEFINE_RTTI_DATA1(collate_short, 0, &locale_facet_rtti_base_descriptor, ".?AV?$collate@G@std@@");
4633 DEFINE_RTTI_DATA1(ctype_base, 0, &locale_facet_rtti_base_descriptor, ".?AUctype_base@std@@");
4634 DEFINE_RTTI_DATA2(ctype_char, 0, &ctype_base_rtti_base_descriptor, &locale_facet_rtti_base_descriptor, ".?AV?$ctype@D@std@@");
4635 DEFINE_RTTI_DATA2(ctype_wchar, 0, &ctype_base_rtti_base_descriptor, &locale_facet_rtti_base_descriptor, ".?AV?$ctype@_W@std@@");
4636 DEFINE_RTTI_DATA2(ctype_short, 0, &ctype_base_rtti_base_descriptor, &locale_facet_rtti_base_descriptor, ".?AV?$ctype@G@std@@");
4637 DEFINE_RTTI_DATA1(codecvt_base, 0, &locale_facet_rtti_base_descriptor, ".?AVcodecvt_base@std@@");
4638 DEFINE_RTTI_DATA2(codecvt_char, 0, &codecvt_base_rtti_base_descriptor, &locale_facet_rtti_base_descriptor, ".?AV?$codecvt@DDH@std@@");
4639 DEFINE_RTTI_DATA1(numpunct_char, 0, &locale_facet_rtti_base_descriptor, ".?AV?$numpunct@D@std@@");
4640 DEFINE_RTTI_DATA1(numpunct_wchar, 0, &locale_facet_rtti_base_descriptor, ".?AV?$numpunct@_W@std@@");
4641 DEFINE_RTTI_DATA1(numpunct_short, 0, &locale_facet_rtti_base_descriptor, ".?AV?$numpunct@G@std@@");
4642 DEFINE_RTTI_DATA1(num_get_char, 0, &locale_facet_rtti_base_descriptor, ".?AV?$num_get@DV?$istreambuf_iterator@DU?$char_traits@D@std@@@std@@@std@@");
4643 DEFINE_RTTI_DATA1(num_get_wchar, 0, &locale_facet_rtti_base_descriptor, ".?AV?$num_get@_WV?$istreambuf_iterator@_WU?$char_traits@_W@std@@@std@@@std@@");
4644 DEFINE_RTTI_DATA1(num_get_short, 0, &locale_facet_rtti_base_descriptor, ".?AV?$num_get@GV?$istreambuf_iterator@GU?$char_traits@G@std@@@std@@@std@@");
4647 void __asm_dummy_vtables(void) {
4649 __ASM_VTABLE(locale_facet, "");
4650 __ASM_VTABLE(collate_char,
4651 VTABLE_ADD_FUNC(collate_char_do_compare)
4652 VTABLE_ADD_FUNC(collate_char_do_transform)
4653 VTABLE_ADD_FUNC(collate_char_do_hash));
4654 __ASM_VTABLE(collate_wchar,
4655 VTABLE_ADD_FUNC(collate_wchar_do_compare)
4656 VTABLE_ADD_FUNC(collate_wchar_do_transform)
4657 VTABLE_ADD_FUNC(collate_wchar_do_hash));
4658 __ASM_VTABLE(collate_short,
4659 VTABLE_ADD_FUNC(collate_wchar_do_compare)
4660 VTABLE_ADD_FUNC(collate_wchar_do_transform)
4661 VTABLE_ADD_FUNC(collate_wchar_do_hash));
4662 __ASM_VTABLE(ctype_base, "");
4663 __ASM_VTABLE(ctype_char,
4664 VTABLE_ADD_FUNC(ctype_char_do_tolower)
4665 VTABLE_ADD_FUNC(ctype_char_do_tolower_ch)
4666 VTABLE_ADD_FUNC(ctype_char_do_toupper)
4667 VTABLE_ADD_FUNC(ctype_char_do_toupper_ch)
4668 VTABLE_ADD_FUNC(ctype_char_do_widen)
4669 VTABLE_ADD_FUNC(ctype_char_do_widen_ch)
4670 VTABLE_ADD_FUNC(ctype_char__Do_widen_s)
4671 VTABLE_ADD_FUNC(ctype_char_do_narrow)
4672 VTABLE_ADD_FUNC(ctype_char_do_narrow_ch)
4673 VTABLE_ADD_FUNC(ctype_char__Do_narrow_s));
4674 __ASM_VTABLE(ctype_wchar,
4675 VTABLE_ADD_FUNC(ctype_wchar_do_is)
4676 VTABLE_ADD_FUNC(ctype_wchar_do_is_ch)
4677 VTABLE_ADD_FUNC(ctype_wchar_do_scan_is)
4678 VTABLE_ADD_FUNC(ctype_wchar_do_scan_not)
4679 VTABLE_ADD_FUNC(ctype_wchar_do_tolower)
4680 VTABLE_ADD_FUNC(ctype_wchar_do_tolower_ch)
4681 VTABLE_ADD_FUNC(ctype_wchar_do_toupper)
4682 VTABLE_ADD_FUNC(ctype_wchar_do_toupper_ch)
4683 VTABLE_ADD_FUNC(ctype_wchar_do_widen)
4684 VTABLE_ADD_FUNC(ctype_wchar_do_widen_ch)
4685 VTABLE_ADD_FUNC(ctype_wchar__Do_widen_s)
4686 VTABLE_ADD_FUNC(ctype_wchar_do_narrow)
4687 VTABLE_ADD_FUNC(ctype_wchar_do_narrow_ch)
4688 VTABLE_ADD_FUNC(ctype_wchar__Do_narrow_s));
4689 __ASM_VTABLE(ctype_short,
4690 VTABLE_ADD_FUNC(ctype_wchar_do_is)
4691 VTABLE_ADD_FUNC(ctype_wchar_do_is_ch)
4692 VTABLE_ADD_FUNC(ctype_wchar_do_scan_is)
4693 VTABLE_ADD_FUNC(ctype_wchar_do_scan_not)
4694 VTABLE_ADD_FUNC(ctype_wchar_do_tolower)
4695 VTABLE_ADD_FUNC(ctype_wchar_do_tolower_ch)
4696 VTABLE_ADD_FUNC(ctype_wchar_do_toupper)
4697 VTABLE_ADD_FUNC(ctype_wchar_do_toupper_ch)
4698 VTABLE_ADD_FUNC(ctype_wchar_do_widen)
4699 VTABLE_ADD_FUNC(ctype_wchar_do_widen_ch)
4700 VTABLE_ADD_FUNC(ctype_wchar__Do_widen_s)
4701 VTABLE_ADD_FUNC(ctype_wchar_do_narrow)
4702 VTABLE_ADD_FUNC(ctype_wchar_do_narrow_ch)
4703 VTABLE_ADD_FUNC(ctype_wchar__Do_narrow_s));
4704 __ASM_VTABLE(codecvt_base,
4705 VTABLE_ADD_FUNC(codecvt_base_do_always_noconv)
4706 VTABLE_ADD_FUNC(codecvt_base_do_max_length)
4707 VTABLE_ADD_FUNC(codecvt_base_do_encoding));
4708 __ASM_VTABLE(codecvt_char,
4709 VTABLE_ADD_FUNC(codecvt_base_do_always_noconv)
4710 VTABLE_ADD_FUNC(codecvt_base_do_max_length)
4711 VTABLE_ADD_FUNC(codecvt_base_do_encoding)
4712 VTABLE_ADD_FUNC(codecvt_char_do_in)
4713 VTABLE_ADD_FUNC(codecvt_char_do_out)
4714 VTABLE_ADD_FUNC(codecvt_char_do_unshift)
4715 VTABLE_ADD_FUNC(codecvt_char_do_length));
4716 __ASM_VTABLE(numpunct_char,
4717 VTABLE_ADD_FUNC(numpunct_char_do_decimal_point)
4718 VTABLE_ADD_FUNC(numpunct_char_do_thousands_sep)
4719 VTABLE_ADD_FUNC(numpunct_char_do_grouping)
4720 VTABLE_ADD_FUNC(numpunct_char_do_falsename)
4721 VTABLE_ADD_FUNC(numpunct_char_do_truename));
4722 __ASM_VTABLE(numpunct_wchar,
4723 VTABLE_ADD_FUNC(numpunct_wchar_do_decimal_point)
4724 VTABLE_ADD_FUNC(numpunct_wchar_do_thousands_sep)
4725 VTABLE_ADD_FUNC(numpunct_wchar_do_grouping)
4726 VTABLE_ADD_FUNC(numpunct_wchar_do_falsename)
4727 VTABLE_ADD_FUNC(numpunct_wchar_do_truename));
4728 __ASM_VTABLE(numpunct_short,
4729 VTABLE_ADD_FUNC(numpunct_wchar_do_decimal_point)
4730 VTABLE_ADD_FUNC(numpunct_wchar_do_thousands_sep)
4731 VTABLE_ADD_FUNC(numpunct_wchar_do_grouping)
4732 VTABLE_ADD_FUNC(numpunct_wchar_do_falsename)
4733 VTABLE_ADD_FUNC(numpunct_wchar_do_truename));
4734 __ASM_VTABLE(num_get_char,
4735 VTABLE_ADD_FUNC(num_get_char_do_get_void)
4736 VTABLE_ADD_FUNC(num_get_char_do_get_double)
4737 VTABLE_ADD_FUNC(num_get_char_do_get_double)
4738 VTABLE_ADD_FUNC(num_get_char_do_get_float)
4739 VTABLE_ADD_FUNC(num_get_char_do_get_uint64)
4740 VTABLE_ADD_FUNC(num_get_char_do_get_int64)
4741 VTABLE_ADD_FUNC(num_get_char_do_get_ulong)
4742 VTABLE_ADD_FUNC(num_get_char_do_get_long)
4743 VTABLE_ADD_FUNC(num_get_char_do_get_uint)
4744 VTABLE_ADD_FUNC(num_get_char_do_get_ushort)
4745 VTABLE_ADD_FUNC(num_get_char_do_get_bool));
4746 __ASM_VTABLE(num_get_short,
4747 VTABLE_ADD_FUNC(num_get_wchar_do_get_void)
4748 VTABLE_ADD_FUNC(num_get_wchar_do_get_double)
4749 VTABLE_ADD_FUNC(num_get_wchar_do_get_double)
4750 VTABLE_ADD_FUNC(num_get_wchar_do_get_float)
4751 VTABLE_ADD_FUNC(num_get_wchar_do_get_uint64)
4752 VTABLE_ADD_FUNC(num_get_wchar_do_get_int64)
4753 VTABLE_ADD_FUNC(num_get_wchar_do_get_ulong)
4754 VTABLE_ADD_FUNC(num_get_wchar_do_get_long)
4755 VTABLE_ADD_FUNC(num_get_wchar_do_get_uint)
4756 VTABLE_ADD_FUNC(num_get_wchar_do_get_ushort)
4757 VTABLE_ADD_FUNC(num_get_wchar_do_get_bool));
4758 __ASM_VTABLE(num_get_wchar,
4759 VTABLE_ADD_FUNC(num_get_wchar_do_get_void)
4760 VTABLE_ADD_FUNC(num_get_wchar_do_get_double)
4761 VTABLE_ADD_FUNC(num_get_wchar_do_get_double)
4762 VTABLE_ADD_FUNC(num_get_wchar_do_get_float)
4763 VTABLE_ADD_FUNC(num_get_wchar_do_get_uint64)
4764 VTABLE_ADD_FUNC(num_get_wchar_do_get_int64)
4765 VTABLE_ADD_FUNC(num_get_wchar_do_get_ulong)
4766 VTABLE_ADD_FUNC(num_get_wchar_do_get_long)
4767 VTABLE_ADD_FUNC(num_get_wchar_do_get_uint)
4768 VTABLE_ADD_FUNC(num_get_wchar_do_get_ushort)
4769 VTABLE_ADD_FUNC(num_get_wchar_do_get_bool));
4774 void free_locale(void)
4776 facets_elem *iter, *safe;
4779 locale__Locimp_dtor(global_locale);
4780 locale_dtor(&classic_locale);
4783 LIST_FOR_EACH_ENTRY_SAFE(iter, safe, &lazy_facets, facets_elem, entry) {
4784 list_remove(&iter->entry);
4785 if(locale_facet__Decref(iter->fac))
4786 call_locale_facet_vector_dtor(iter->fac, 1);
4787 MSVCRT_operator_delete(iter);