// wlocale -- class locale wide member functions #include #include #include _STD_BEGIN #pragma warning(disable: 4786) typedef char_traits _Wtraits; typedef istreambuf_iterator _Winiter; typedef ostreambuf_iterator _Woutiter; // facets associated with C categories #define ADDFAC(Facet, cat, ptrimp, ptrloc) \ if ((_CATMASK(Facet::_Getcat()) & cat) == 0) \ ; \ else if (ptrloc == 0) \ ptrimp->_Addfac(_NEW_CRT Facet(lobj), Facet::id); \ else \ ptrimp->_Addfac((locale::facet *)&_USE(*ptrloc, Facet), Facet::id); // moved from locale to ease subsetting typedef ctype _Tw1; typedef num_get _Tw2; typedef num_put _Tw3; typedef numpunct _Tw4; typedef collate _Tw5; typedef messages _Tw6; typedef money_get _Tw7; typedef money_put _Tw9; typedef moneypunct _Tw11; typedef moneypunct _Tw12; typedef time_get _Tw13; typedef time_put _Tw14; //.... typedef codecvt _Twc1; _TEMPLATE_STAT locale::id time_put::id; void __cdecl locale::_Locimp::_Makewloc(const _Locinfo& lobj, locale::category cat, _Locimp *ptrimp, const locale *ptrloc) { // setup wide part of a new locale ADDFAC(_Tw1, cat, ptrimp, ptrloc); ADDFAC(_Tw2, cat, ptrimp, ptrloc); ADDFAC(_Tw3, cat, ptrimp, ptrloc); ADDFAC(_Tw4, cat, ptrimp, ptrloc); ADDFAC(_Tw5, cat, ptrimp, ptrloc); ADDFAC(_Tw6, cat, ptrimp, ptrloc); ADDFAC(_Tw7, cat, ptrimp, ptrloc); ADDFAC(_Tw9, cat, ptrimp, ptrloc); ADDFAC(_Tw11, cat, ptrimp, ptrloc); ADDFAC(_Tw12, cat, ptrimp, ptrloc); ADDFAC(_Tw13, cat, ptrimp, ptrloc); ADDFAC(_Tw14, cat, ptrimp, ptrloc); //... ADDFAC(_Twc1, cat, ptrimp, ptrloc); } #ifdef _NATIVE_WCHAR_T_DEFINED typedef char_traits _UShtraits; typedef istreambuf_iterator _UShiniter; typedef ostreambuf_iterator _UShoutiter; // moved from locale to ease subsetting typedef ctype _Tush1; typedef num_get _Tush2; typedef num_put _Tush3; typedef numpunct _Tush4; typedef collate _Tush5; typedef messages _Tush6; typedef money_get _Tush7; typedef money_put _Tush9; typedef moneypunct _Tush11; typedef moneypunct _Tush12; typedef time_get _Tush13; typedef time_put _Tush14; //.... typedef codecvt _Tushc1; _TEMPLATE_STAT locale::id time_put::id; void __cdecl locale::_Locimp::_Makeushloc(const _Locinfo& lobj, locale::category cat, _Locimp *ptrimp, const locale *ptrloc) { // setup wide part of a new locale ADDFAC(_Tush1, cat, ptrimp, ptrloc); ADDFAC(_Tush2, cat, ptrimp, ptrloc); ADDFAC(_Tush3, cat, ptrimp, ptrloc); ADDFAC(_Tush4, cat, ptrimp, ptrloc); ADDFAC(_Tush5, cat, ptrimp, ptrloc); ADDFAC(_Tush6, cat, ptrimp, ptrloc); ADDFAC(_Tush7, cat, ptrimp, ptrloc); ADDFAC(_Tush9, cat, ptrimp, ptrloc); ADDFAC(_Tush11, cat, ptrimp, ptrloc); ADDFAC(_Tush12, cat, ptrimp, ptrloc); ADDFAC(_Tush13, cat, ptrimp, ptrloc); ADDFAC(_Tush14, cat, ptrimp, ptrloc); //... ADDFAC(_Tushc1, cat, ptrimp, ptrloc); } #endif _STD_END /* * Copyright (c) 1992-2001 by P.J. Plauger. ALL RIGHTS RESERVED. * Consult your license regarding permissions and restrictions. V3.10:0009 */