111 cout<<""; |
111 cout<<""; |
112 |
112 |
113 #if STDCPP_OOM |
113 #if STDCPP_OOM |
114 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
114 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
115 #endif |
115 #endif |
116 char* p = "c"; |
116 // char* p = "c"; |
117 const char* _Loc_ctype_default(p) ; |
117 // const char* _Loc_ctype_default(p) ; |
118 |
118 |
119 locale loc("en_GB.UTF-8") ; |
119 locale loc("en_GB.UTF-8") ; |
120 result = has_facet <ctype<char> > ( loc ); |
120 result = has_facet <ctype<char> > ( loc ); |
121 result_w = has_facet <ctype<wchar_t> > ( loc ); |
121 result_w = has_facet <ctype<wchar_t> > ( loc ); |
122 #if STDCPP_OOM |
122 #if STDCPP_OOM |
531 typedef ostreambuf_iterator<char,char_traits<char> > |
531 typedef ostreambuf_iterator<char,char_traits<char> > |
532 iter_type; |
532 iter_type; |
533 |
533 |
534 locale loc; |
534 locale loc; |
535 string buffer("10002"); |
535 string buffer("10002"); |
536 long double ldval = 10002; |
536 // long double ldval = 10002; |
537 |
537 |
538 iter_type begin(cout); |
538 iter_type begin(cout); |
539 cout<<""; |
539 cout<<""; |
540 #if STDCPP_OOM |
540 #if STDCPP_OOM |
541 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
541 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
816 { |
816 { |
817 |
817 |
818 |
818 |
819 typedef std::istreambuf_iterator<char, |
819 typedef std::istreambuf_iterator<char, |
820 std::char_traits<char> > Iter; |
820 std::char_traits<char> > Iter; |
821 static struct tm timeb; |
821 // static struct tm timeb; |
822 std::ios_base::iostate state; |
822 // std::ios_base::iostate state; |
823 cout<<""; |
823 cout<<""; |
824 #if STDCPP_OOM |
824 #if STDCPP_OOM |
825 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
825 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
826 #endif |
826 #endif |
827 const std::time_get<char, Iter> &tg = |
827 const std::time_get<char, Iter> &tg = |
882 "%k", "%l", "%m", "%M", "%n", "%p", "%r", "%R", |
882 "%k", "%l", "%m", "%M", "%n", "%p", "%r", "%R", |
883 "%S", "%t", "%T", "%u", "%U", "%V", "%w", "%W", "%x", |
883 "%S", "%t", "%T", "%u", "%U", "%V", "%w", "%W", "%x", |
884 "%X", "%y", "%Y", "%z", "%Z", "%%", "%Ec", "%EC", "%Ex", |
884 "%X", "%y", "%Y", "%z", "%Z", "%%", "%Ec", "%EC", "%Ex", |
885 "%EX", "%Ey", "%EY", "%Od", "%Oe", "%OH", "%OI", "%Om", |
885 "%EX", "%Ey", "%EY", "%Od", "%Oe", "%OH", "%OI", "%Om", |
886 "%OM", "%OS", "%Ou", "%OU", "%OV", "%Ow", "%OW", "%Oy" |
886 "%OM", "%OS", "%Ou", "%OU", "%OV", "%Ow", "%OW", "%Oy" |
887 }; |
887 };*/ |
888 cout<<""; |
888 cout<<""; |
889 #if STDCPP_OOM |
889 #if STDCPP_OOM |
890 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
890 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
891 #endif |
891 #endif |
892 const std::time_put<char> &tput = |
892 const std::time_put<char> &tput = |
1480 cout<<""; |
1480 cout<<""; |
1481 |
1481 |
1482 #if STDCPP_OOM |
1482 #if STDCPP_OOM |
1483 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
1483 User::__DbgSetAllocFail(FALSE,RHeap::EDeterministic,1); |
1484 #endif |
1484 #endif |
1485 char* p = "c"; |
1485 // char* p = "c"; |
1486 const char* _Loc_ctype_default(p); |
1486 /* const char* _Loc_ctype_default(p); |
1487 const char* _Loc_numeric_default(p) ; |
1487 const char* _Loc_numeric_default(p) ; |
1488 const char* _Loc_time_default(p) ; |
1488 const char* _Loc_time_default(p) ; |
1489 const char* _Loc_collate_default(p) ; |
1489 const char* _Loc_collate_default(p) ; |
1490 const char* _Loc_monetary_default(p) ; |
1490 const char* _Loc_monetary_default(p) ; |
1491 const char* _Loc_messages_default(p) ; |
1491 const char* _Loc_messages_default(p) ;*/ |
1492 |
1492 |
1493 locale::category c; |
1493 /* locale::category c; |
1494 //_Locale* L = "k"; |
1494 //_Locale* L = "k"; |
1495 const char* name1 = "catalog"; |
1495 const char* name1 = "catalog"; |
1496 const char* name2="test"; |
1496 const char* name2="test";*/ |
1497 |
1497 |
1498 |
1498 |
1499 const locale& L1= 0; |
1499 const locale& L1= 0; |
1500 const locale& L2= 0; |
1500 const locale& L2= 0; |
1501 const char* name = "testing"; |
1501 // const char* name = "testing"; |
1502 // void _Stl_loc_combine_names(L,name1,name2,c); |
1502 // void _Stl_loc_combine_names(L,name1,name2,c); |
1503 //locale::locale(const locale& L1, const locale& L2, category c) |
1503 //locale::locale(const locale& L1, const locale& L2, category c) |
1504 //locale::category c; |
1504 //locale::category c; |
1505 |
1505 |
1506 |
1506 |
1562 |
1562 |
1563 |
1563 |
1564 locale loc1 ( "C" ); |
1564 locale loc1 ( "C" ); |
1565 |
1565 |
1566 char *string = "Hello, my name is John!"; |
1566 char *string = "Hello, my name is John!"; |
1567 wchar_t *wstring = L"Hello, my name is John!"; |
1567 // wchar_t *wstring = L"Hello, my name is John!"; |
1568 |
1568 |
1569 const char* i = use_facet<ctype<char> > ( loc1 ).scan_is ( ctype_base::punct, &string[0], &string[strlen(&string[0])-1] ); |
1569 const char* i = use_facet<ctype<char> > ( loc1 ).scan_is ( ctype_base::punct, &string[0], &string[strlen(&string[0])-1] ); |
1570 // const wchar_t* wi = use_facet<ctype<wchar_t> > ( loc1 ).scan_is ( ctype_base::punct, &wstring[0], &wstring[strlen(&wstring[0])-1] ); |
1570 // const wchar_t* wi = use_facet<ctype<wchar_t> > ( loc1 ).scan_is ( ctype_base::punct, &wstring[0], &wstring[strlen(&wstring[0])-1] ); |
1571 const char* j = use_facet<ctype<char> > ( loc1 ).scan_not( ctype_base::alpha, &string[0], &string[strlen(&string[0])-1] ); |
1571 const char* j = use_facet<ctype<char> > ( loc1 ).scan_not( ctype_base::alpha, &string[0], &string[strlen(&string[0])-1] ); |
1572 if((*i)!= ',') |
1572 if((*i)!= ',') |
1600 |
1600 |
1601 wchar_t wto_upper = L'A'; |
1601 wchar_t wto_upper = L'A'; |
1602 |
1602 |
1603 char str2[16]; |
1603 char str2[16]; |
1604 |
1604 |
1605 char test; |
1605 //char test; |
1606 use_facet<ctype<char> > ( loc1 ).toupper( &string3[0], &string3[strlen(&string3[0])] ); |
1606 use_facet<ctype<char> > ( loc1 ).toupper( &string3[0], &string3[strlen(&string3[0])] ); |
1607 use_facet<ctype<wchar_t> > ( loc1 ).toupper( &wstring3[0], &wstring3[27] ); |
1607 use_facet<ctype<wchar_t> > ( loc1 ).toupper( &wstring3[0], &wstring3[27] ); |
1608 |
1608 |
1609 use_facet<ctype<char> > ( loc1 ).toupper(to_upper); |
1609 use_facet<ctype<char> > ( loc1 ).toupper(to_upper); |
1610 use_facet<ctype<wchar_t> > ( loc1 ).toupper(wto_upper); |
1610 use_facet<ctype<wchar_t> > ( loc1 ).toupper(wto_upper); |